imaplib.IMAP4.search()

IMAP4.search(charset, criterion[, ...]) Search mailbox for matching messages. charset may be None, in which case no CHARSET will be specified in the request to the server. The IMAP protocol requires that at least one criterion be specified; an exception will be raised when the server returns an error. charset must be None if the UTF8=ACCEPT capability was enabled using the enable() command. Example: # M is a connected IMAP4 instance... typ, msgnums = M.search(None, 'FROM', '"LDJ"') # or: ty

pathlib.Path.unlink()

Path.unlink() Remove this file or symbolic link. If the path points to a directory, use Path.rmdir() instead.

configparser.ParsingError

exception configparser.ParsingError Exception raised when errors occur attempting to parse a file. Changed in version 3.2: The filename attribute and __init__() argument were renamed to source for consistency.

http.cookiejar.Cookie.version

Cookie.version Integer or None. Netscape cookies have version 0. RFC 2965 and RFC 2109 cookies have a version cookie-attribute of 1. However, note that http.cookiejar may ‘downgrade’ RFC 2109 cookies to Netscape cookies, in which case version is 0.

configparser.DuplicateSectionError

exception configparser.DuplicateSectionError Exception raised if add_section() is called with the name of a section that is already present or in strict parsers when a section if found more than once in a single input file, string or dictionary. New in version 3.2: Optional source and lineno attributes and arguments to __init__() were added.

zlib.Decompress.unused_data

Decompress.unused_data A bytes object which contains any bytes past the end of the compressed data. That is, this remains b"" until the last byte that contains compression data is available. If the whole bytestring turned out to contain compressed data, this is b"", an empty bytes object.

mimetypes.guess_extension()

mimetypes.guess_extension(type, strict=True) Guess the extension for a file based on its MIME type, given by type. The return value is a string giving a filename extension, including the leading dot ('.'). The extension is not guaranteed to have been associated with any particular data stream, but would be mapped to the MIME type type by guess_type(). If no extension can be guessed for type, None is returned. The optional strict argument has the same meaning as with the guess_type() function

collections.deque

class collections.deque([iterable[, maxlen]]) Returns a new deque object initialized left-to-right (using append()) with data from iterable. If iterable is not specified, the new deque is empty. Deques are a generalization of stacks and queues (the name is pronounced “deck” and is short for “double-ended queue”). Deques support thread-safe, memory efficient appends and pops from either side of the deque with approximately the same O(1) performance in either direction. Though list objects sup

xml.dom.DocumentType.entities

DocumentType.entities This is a NamedNodeMap giving the definitions of external entities. For entity names defined more than once, only the first definition is provided (others are ignored as required by the XML recommendation). This may be None if the information is not provided by the parser, or if no entities are defined.

pathlib.PurePath.relative_to()

PurePath.relative_to(*other) Compute a version of this path relative to the path represented by other. If it’s impossible, ValueError is raised: >>> p = PurePosixPath('/etc/passwd') >>> p.relative_to('/') PurePosixPath('etc/passwd') >>> p.relative_to('/etc') PurePosixPath('passwd') >>> p.relative_to('/usr') Traceback (most recent call last): File "<stdin>", line 1, in <module> File "pathlib.py", line 694, in relative_to .format(str(self