tarfile.TarFile.extract()

TarFile.extract(member, path="", set_attrs=True, *, numeric_owner=False) Extract a member from the archive to the current working directory, using its full name. Its file information is extracted as accurately as possible. member may be a filename or a TarInfo object. You can specify a different directory using path. File attributes (owner, mtime, mode) are set unless set_attrs is false. If numeric_owner is True, the uid and gid numbers from the tarfile are used to set the owner/group for th

bytearray.zfill()

bytearray.zfill(width) Return a copy of the sequence left filled with ASCII b'0' digits to make a sequence of length width. A leading sign prefix (b'+'/ b'-' is handled by inserting the padding after the sign character rather than before. For bytes objects, the original sequence is returned if width is less than or equal to len(seq). For example: >>> b"42".zfill(5) b'00042' >>> b"-42".zfill(5) b'-0042' Note The bytearray version of this method does not operate in place -

smtplib.SMTP.sendmail()

SMTP.sendmail(from_addr, to_addrs, msg, mail_options=[], rcpt_options=[]) Send mail. The required arguments are an RFC 822 from-address string, a list of RFC 822 to-address strings (a bare string will be treated as a list with 1 address), and a message string. The caller may pass a list of ESMTP options (such as 8bitmime) to be used in MAIL FROM commands as mail_options. ESMTP options (such as DSN commands) that should be used with all RCPT commands can be passed as rcpt_options. (If you nee

asyncio.as_completed()

asyncio.as_completed(fs, *, loop=None, timeout=None) Return an iterator whose values, when waited for, are Future instances. Raises asyncio.TimeoutError if the timeout occurs before all Futures are done. Example: for f in as_completed(fs): result = yield from f # The 'yield from' may raise # Use result Note The futures f are not necessarily members of fs.

timeit.Timer

class timeit.Timer(stmt='pass', setup='pass', timer=, globals=None) Class for timing execution speed of small code snippets. The constructor takes a statement to be timed, an additional statement used for setup, and a timer function. Both statements default to 'pass'; the timer function is platform-dependent (see the module doc string). stmt and setup may also contain multiple statements separated by ; or newlines, as long as they don’t contain multi-line string literals. The statement will

curses.panel.Panel.window()

Panel.window() Returns the window object associated with the panel.

xml.etree.ElementTree.ProcessingInstruction()

xml.etree.ElementTree.ProcessingInstruction(target, text=None) PI element factory. This factory function creates a special element that will be serialized as an XML processing instruction. target is a string containing the PI target. text is a string containing the PI contents, if given. Returns an element instance, representing a processing instruction. Note that XMLParser skips over processing instructions in the input instead of creating comment objects for them. An ElementTree will only

unittest.TestCase.tearDown()

tearDown() Method called immediately after the test method has been called and the result recorded. This is called even if the test method raised an exception, so the implementation in subclasses may need to be particularly careful about checking internal state. Any exception, other than AssertionError or SkipTest, raised by this method will be considered an additional error rather than a test failure (thus increasing the total number of reported errors). This method will only be called if t

calendar.prmonth()

calendar.prmonth(theyear, themonth, w=0, l=0) Prints a month’s calendar as returned by month().

mailbox.Mailbox.close()

close() Flush the mailbox, unlock it if necessary, and close any open files. For some Mailbox subclasses, this method does nothing.