email.charset.Charset.body_encoding

body_encoding Same as header_encoding, but describes the encoding for the mail message’s body, which indeed may be different than the header encoding. Charset.SHORTEST is not allowed for body_encoding.

email.charset.Charset.body_encode()

body_encode(string) Body-encode the string string. The type of encoding (base64 or quoted-printable) will be based on the body_encoding attribute.

email.charset.Charset

class email.charset.Charset(input_charset=DEFAULT_CHARSET) Map character sets to their email properties. This class provides information about the requirements imposed on email for a specific character set. It also provides convenience routines for converting between character sets, given the availability of the applicable codecs. Given a character set, it will do its best to provide information on how to use that character set in an email message in an RFC-compliant way. Certain character s

email.charset.add_codec()

email.charset.add_codec(charset, codecname) Add a codec that map characters in the given character set to and from Unicode. charset is the canonical name of a character set. codecname is the name of a Python codec, as appropriate for the second argument to the str‘s encode() method.

email.charset.add_charset()

email.charset.add_charset(charset, header_enc=None, body_enc=None, output_charset=None) Add character properties to the global registry. charset is the input character set, and must be the canonical name of a character set. Optional header_enc and body_enc is either Charset.QP for quoted-printable, Charset.BASE64 for base64 encoding, Charset.SHORTEST for the shortest of quoted-printable or base64 encoding, or None for no encoding. SHORTEST is only valid for header_enc. The default is None fo

email.charset.add_alias()

email.charset.add_alias(alias, canonical) Add a character set alias. alias is the alias name, e.g. latin-1. canonical is the character set’s canonical name, e.g. iso-8859-1. The global charset alias registry is kept in the module global dictionary ALIASES.

email

Source code: Lib/email/__init__.py The email package is a library for managing email messages, including MIME and other RFC 2822-based message documents. It is specifically not designed to do any sending of email messages to SMTP (RFC 2821), NNTP, or other servers; those are functions of modules such as smtplib and nntplib. The email package attempts to be as RFC-compliant as possible, supporting in addition to RFC 2822, such MIME-related RFCs as RFC 2045, RFC 2046, RFC 2047, and RFC 2231. The

Ellipsis

Ellipsis The same as .... Special value used mostly in conjunction with extended slicing syntax for user-defined container data types.

dummy_threading

Source code: Lib/dummy_threading.py This module provides a duplicate interface to the threading module. It is meant to be imported when the _thread module is not provided on a platform. Suggested usage is: try: import threading except ImportError: import dummy_threading as threading Be careful to not use this module where deadlock might occur from a thread being created that blocks waiting for another thread to be created. This often occurs with blocking I/O.

doctest.UnexpectedException.test

UnexpectedException.test The DocTest object that was being run when the example failed.