pickle.Unpickler

class pickle.Unpickler(file, *, fix_imports=True, encoding="ASCII", errors="strict") This takes a binary file for reading a pickle data stream. The protocol version of the pickle is detected automatically, so no protocol argument is needed. The argument file must have two methods, a read() method that takes an integer argument, and a readline() method that requires no arguments. Both methods should return bytes. Thus file can be an on-disk file object opened for binary reading, an io.BytesIO

bdb.Bdb.get_file_breaks()

get_file_breaks(filename) Return all breakpoints in filename, or an empty list if none are set.

unittest.mock.Mock.configure_mock()

configure_mock(**kwargs) Set attributes on the mock through keyword arguments. Attributes plus return values and side effects can be set on child mocks using standard dot notation and unpacking a dictionary in the method call: >>> mock = Mock() >>> attrs = {'method.return_value': 3, 'other.side_effect': KeyError} >>> mock.configure_mock(**attrs) >>> mock.method() 3 >>> mock.other() Traceback (most recent call last): ... KeyError The same thing

asyncio.StreamWriter

class asyncio.StreamWriter(transport, protocol, reader, loop) Wraps a Transport. This exposes write(), writelines(), can_write_eof(), write_eof(), get_extra_info() and close(). It adds drain() which returns an optional Future on which you can wait for flow control. It also adds a transport attribute which references the Transport directly. This class is not thread safe. transport Transport. can_write_eof() Return True if the transport supports write_eof(), False if not. See WriteTra

memoryview.c_contiguous

c_contiguous A bool indicating whether the memory is C-contiguous. New in version 3.3.

xml.etree.ElementTree.Element.set()

set(key, value) Set the attribute key on the element to value.

chunk.Chunk

class chunk.Chunk(file, align=True, bigendian=True, inclheader=False) Class which represents a chunk. The file argument is expected to be a file-like object. An instance of this class is specifically allowed. The only method that is needed is read(). If the methods seek() and tell() are present and don’t raise an exception, they are also used. If these methods are present and raise an exception, they are expected to not have altered the object. If the optional argument align is true, chunks

subprocess.Popen.send_signal()

Popen.send_signal(signal) Sends the signal signal to the child. Note On Windows, SIGTERM is an alias for terminate(). CTRL_C_EVENT and CTRL_BREAK_EVENT can be sent to processes started with a creationflags parameter which includes CREATE_NEW_PROCESS_GROUP.

operator.lt()

operator.lt(a, b) operator.le(a, b) operator.eq(a, b) operator.ne(a, b) operator.ge(a, b) operator.gt(a, b) operator.__lt__(a, b) operator.__le__(a, b) operator.__eq__(a, b) operator.__ne__(a, b) operator.__ge__(a, b) operator.__gt__(a, b) Perform “rich comparisons” between a and b. Specifically, lt(a, b) is equivalent to a < b, le(a, b) is equivalent to a <= b, eq(a, b) is equivalent to a == b, ne(a, b) is equivalent to a != b, gt(a, b) is equivalent to a > b and ge(a, b) is equival

shlex.shlex

class shlex.shlex(instream=None, infile=None, posix=False) A shlex instance or subclass instance is a lexical analyzer object. The initialization argument, if present, specifies where to read characters from. It must be a file-/stream-like object with read() and readline() methods, or a string. If no argument is given, input will be taken from sys.stdin. The second optional argument is a filename string, which sets the initial value of the infile attribute. If the instream argument is omitte