email.header: MicroPython doesn't have str.isspace().

And the usecase here clear doesn't prompt for it to be added to core language.
pull/118/head
Paul Sokolovsky 2014-05-25 03:25:06 +03:00
rodzic 4819791a9c
commit 717dc0cd1f
3 zmienionych plików z 3 dodań i 3 usunięć

Wyświetl plik

@ -312,7 +312,7 @@ class Header:
def _nonctext(self, s):
"""True if string s is not a ctext character of RFC822.
"""
return s.isspace() or s in ('(', ')', '\\')
return s in (' ', '\t', '(', ')', '\\')
def encode(self, splitchars=';, \t', maxlinelen=None, linesep='\n'):
r"""Encode a message header into an RFC-compliant format.

Wyświetl plik

@ -1,4 +1,4 @@
srctype = cpython
type = package
version = 0.5
version = 0.5.1
depends = re-pcre, binascii, email.encoders, email.errors, email.charset

Wyświetl plik

@ -6,7 +6,7 @@ from setuptools import setup
setup(name='micropython-email.header',
version='0.5',
version='0.5.1',
description='CPython email.header module ported to MicroPython',
long_description='This is a module ported from CPython standard library to be compatible with\nMicroPython interpreter. Usually, this means applying small patches for\nfeatures not supported (yet, or at all) in MicroPython. Sometimes, heavier\nchanges are required. Note that CPython modules are written with availability\nof vast resources in mind, and may not work for MicroPython ports with\nlimited heap. If you are affected by such a case, please help reimplement\nthe module from scratch.',
url='https://github.com/micropython/micropython/issues/405',