contextlib.ExitStack.close()

close() Immediately unwinds the callback stack, invoking callbacks in the reverse order of registration. For any context managers and exit callbacks registered, the arguments passed in will indicate that no exception occurred.

bytearray.join()

bytearray.join(iterable) Return a bytes or bytearray object which is the concatenation of the binary data sequences in the iterable iterable. A TypeError will be raised if there are any values in iterable that are not bytes-like objects, including str objects. The separator between elements is the contents of the bytes or bytearray object providing this method.

subprocess.CompletedProcess

class subprocess.CompletedProcess The return value from run(), representing a process that has finished. args The arguments used to launch the process. This may be a list or a string. returncode Exit status of the child process. Typically, an exit status of 0 indicates that it ran successfully. A negative value -N indicates that the child was terminated by signal N (POSIX only). stdout Captured stdout from the child process. A bytes sequence, or a string if run() was called wi

hmac.HMAC.digest()

HMAC.digest() Return the digest of the bytes passed to the update() method so far. This bytes object will be the same length as the digest_size of the digest given to the constructor. It may contain non-ASCII bytes, including NUL bytes. Warning When comparing the output of digest() to an externally-supplied digest during a verification routine, it is recommended to use the compare_digest() function instead of the == operator to reduce the vulnerability to timing attacks.

typing.List

class typing.List(list, MutableSequence[T]) Generic version of list. Useful for annotating return types. To annotate arguments it is preferred to use abstract collection types such as Mapping, Sequence, or AbstractSet. This type may be used as follows: T = TypeVar('T', int, float) def vec2(x: T, y: T) -> List[T]: return [x, y] def keep_positives(vector: Sequence[T]) -> List[T]: return [item for item in vector if item > 0]

ssl.SSLContext.load_verify_locations()

SSLContext.load_verify_locations(cafile=None, capath=None, cadata=None) Load a set of “certification authority” (CA) certificates used to validate other peers’ certificates when verify_mode is other than CERT_NONE. At least one of cafile or capath must be specified. This method can also load certification revocation lists (CRLs) in PEM or DER format. In order to make use of CRLs, SSLContext.verify_flags must be configured properly. The cafile string, if present, is the path to a file of conc

dbm.error

exception dbm.error A tuple containing the exceptions that can be raised by each of the supported modules, with a unique exception also named dbm.error as the first item — the latter is used when dbm.error is raised.

telnetlib.Telnet.read_very_eager()

Telnet.read_very_eager() Read everything that can be without blocking in I/O (eager). Raise EOFError if connection closed and no cooked data available. Return b'' if no cooked data available otherwise. Do not block unless in the midst of an IAC sequence.

concurrent.futures.Future.set_running_or_notify_cancel()

set_running_or_notify_cancel() This method should only be called by Executor implementations before executing the work associated with the Future and by unit tests. If the method returns False then the Future was cancelled, i.e. Future.cancel() was called and returned True. Any threads waiting on the Future completing (i.e. through as_completed() or wait()) will be woken up. If the method returns True then the Future was not cancelled and has been put in the running state, i.e. calls to Futu

modulefinder.ModuleFinder

class modulefinder.ModuleFinder(path=None, debug=0, excludes=[], replace_paths=[]) This class provides run_script() and report() methods to determine the set of modules imported by a script. path can be a list of directories to search for modules; if not specified, sys.path is used. debug sets the debugging level; higher values make the class print debugging messages about what it’s doing. excludes is a list of module names to exclude from the analysis. replace_paths is a list of (oldpath, n