Table of Contents (expanded)¶
- 01 Introduction
- 02 Built-in Functions
- 03 Non-essential Built-in Functions
- 04 Built-in Constants
- 05 Built-in Types
- 1. Truth Value Testing
- 2. Boolean Operations —
and,or,not - 3. Comparisons
- 4. Numeric Types —
int,float,long,complex - 5. Iterator Types
- 6. Sequence Types —
str,unicode,list,tuple,bytearray,buffer,xrange - 7. Set Types —
set,frozenset - 8. Mapping Types —
dict - 9. File Objects
- 10. memoryview type
- 11. Context Manager Types
- 12. Other Built-in Types
- 13. Special Attributes
- 06 Built-in Exceptions
- 07. String Services
- 1.
string— Common string operations - 2.
re— Regular expression operations - 3.
struct— Interpret strings as packed binary data - 4.
difflib— Helpers for computing deltas - 5.
StringIO— Read and write strings as files - 6.
cStringIO— Faster version ofStringIO - 7.
textwrap— Text wrapping and filling - 8.
codecs— Codec registry and base classes - 9.
unicodedata— Unicode Database - 10.
stringprep— Internet String Preparation - 11. (deprecated)
fpformat— Floating point conversions
- 1.
- 08. Data Types
- 1.
datetime— Basic date and time types - 2.
calendar— General calendar-related functions - 3.
collections— High-performance container datatypes - 4.
heapq— Heap queue algorithm - 5.
bisect— Array bisection algorithm - 6.
array— Efficient arrays of numeric values - 7.
sets— Unordered collections of unique elements - 8.
sched— Event scheduler - 9.
mutex— Mutual exclusion support - 10.
Queue— A synchronized queue class - 11.
weakref— Weak references - 12.
UserDict— Class wrapper for dictionary objects - 13.
UserList— Class wrapper for list objects - 14.
UserString— Class wrapper for string objects - 15.
types— Names for built-in types - 16.
new— Creation of runtime internal objects - 17.
copy— Shallow and deep copy operations - 18.
pprint— Data pretty printer - 19.
repr— Alternaterepr()implementation
- 1.
- 09 Numeric and Mathematical Modules
- 1.
numbers— Numeric abstract base classes - 2.
math— Mathematical functions - 3.
cmath— Mathematical functions for complex numbers - 4.
decimal— Decimal fixed point and floating point arithmetic - 5.
fractions— Rational numbers - 6.
random— Generate pseudo-random numbers - 7.
itertools— Functions creating iterators for efficient looping - 8.
functools— Higher-order functions and operations on callable objects - 9.
operator— Standard operators as functions
- 1.
- 10 File and Directory Access
- 1.
os.path— Common pathname manipulations - 2.
fileinput— Iterate over lines from multiple input streams - 3.
stat— Interpretingstat()results - 4.
statvfs— Constants used withos.statvfs() - 5.
filecmp— File and Directory Comparisons - 6.
tempfile— Generate temporary files and directories - 7.
glob— Unix style pathname pattern expansion - 8.
fnmatch— Unix filename pattern matching - 9.
linecache— Random access to text lines - 10.
shutil— High-level file operations - 11.
dircache— Cached directory listings - 12.
macpath— Mac OS 9 path manipulation functions
- 1.
- 11. Data Persistence
- 1.
pickle— Python object serialization - 2.
cPickle— A fasterpickle - 3.
copy_reg— Registerpicklesupport functions - 4.
shelve— Python object persistence - 5.
marshal— Internal Python object serialization - 6.
anydbm— Generic access to DBM-style databases - 7.
whichdb— Guess which DBM module created a database - 8.
dbm— Simple “database” interface - 9.
gdbm— GNU’s reinterpretation of dbm - 10. (deprecated)
dbhash— DBM-style interface to the BSD database library - 11. (deprecated)
bsddb— Interface to Berkeley DB library - 12.
dumbdbm— Portable DBM implementation - 13.
sqlite3— DB-API 2.0 interface for SQLite databases
- 1.
- 12 Data Compression and Archiving
- 13 File Formats
- 14 Cryptographic Services
- 15 Generic Operating System Services
- 1.
os— Miscellaneous operating system interfaces - 2.
io— Core tools for working with streams - 3.
argparse— Parser for command-line options, arguments and sub-commands - 4.
optparse— Parser for command line options - 5.
getopt— C-style parser for command line options - 6.
logging— Logging facility for Python - 7.
logging.config— Logging configuration - 8.
logging.handlers— Logging handlers - 9.
getpass— Portable password input - 10.
curses— Terminal handling for character-cell displays - 11.
curses.textpad— Text input widget for curses programs - 12.
curses.ascii— Utilities for ASCII characters - 13.
curses.panel— A panel stack extension for curses - 14.
platform— Access to underlying platform’s identifying data - 15.
errno— Standard errno system symbols - 16.
ctypes— A foreign function library for Python
- 1.
- 16 Optional Operating System Services
- 1.
select— Waiting for I/O completion - 2.
threading— Higher-level threading interface - 3.
thread— Multiple threads of control - 4.
dummy_threading— Drop-in replacement for thethreadingmodule - 5.
dummy_thread— Drop-in replacement for thethreadmodule - 6.
multiprocessing— Process-based “threading” interface - 7.
mmap— Memory-mapped file support - 8.
readline— GNU readline interface - 9.
rlcompleter— Completion function for GNU readline
- 1.
- 17 Interprocess Communication and Networking
- 1.
subprocess— Subprocess management - 2.
socket— Low-level networking interface - 3.
ssl— TLS/SSL wrapper for socket objects - 4.
signal— Set handlers for asynchronous events - 5.
popen2— Subprocesses with accessible I/O streams - 6.
asyncore— Asynchronous socket handler - 7.
asynchat— Asynchronous socket command/response handler
- 1.
- 18 Internet Data Handling
- 1.
email— An email and MIME handling package - 2.
json— JSON encoder and decoder - 3.
mailcap— Mailcap file handling - 4.
mailbox— Manipulate mailboxes in various formats - 5. (depr)
mhlib— Access to MH mailboxes - 6. (depr)
mimetools— Tools for parsing MIME messages - 7.
mimetypes— Map filenames to MIME types - 8. (depr)
MimeWriter— Generic MIME file writer - 9. (depr)
mimify— MIME processing of mail messages - 10. (depr)
multifile— Support for files containing distinct parts - 11. (depr)
rfc822— Parse RFC 2822 mail headers - 12.
base64— RFC 3548: Base16, Base32, Base64 Data Encodings - 13.
binhex— Encode and decode binhex4 files - 14.
binascii— Convert between binary and ASCII - 15.
quopri— Encode and decode MIME quoted-printable data - 16.
uu— Encode and decode uuencode files
- 1.
- 19 Structured Markup Processing Tools
- 1.
HTMLParser— Simple HTML and XHTML parser - 2. (depr)
sgmllib— Simple SGML parser - 3. (depr)
htmllib— A parser for HTML documents - 4.
htmlentitydefs— Definitions of HTML general entities - 5. XML Processing Modules
- 6. XML vulnerabilities
- 7.
xml.etree.ElementTree— The ElementTree XML API - 8.
xml.dom— The Document Object Model API - 9.
xml.dom.minidom— Minimal DOM implementation - 10.
xml.dom.pulldom— Support for building partial DOM trees - 11.
xml.sax— Support for SAX2 parsers - 12.
xml.sax.handler— Base classes for SAX handlers - 13.
xml.sax.saxutils— SAX Utilities - 14.
xml.sax.xmlreader— Interface for XML parsers - 15.
xml.parsers.expat— Fast XML parsing using Expat
- 1.
- 20a Internet Protocols and Support
- 1.
webbrowser— Convenient Web-browser controller - 2.
cgi— Common Gateway Interface support - 3.
cgitb— Traceback manager for CGI scripts - 4.
wsgiref— WSGI Utilities and Reference Implementation - 5.
urllib— Open arbitrary resources by URL - 6.
urllib2— extensible library for opening URLs - 7.
httplib— HTTP protocol client - 8.
ftplib— FTP protocol client - 9.
poplib— POP3 protocol client - 10.
imaplib— IMAP4 protocol client - 11.
nntplib— NNTP protocol client - 12.
smtplib— SMTP protocol client - 13.
smtpd— SMTP Server
- 1.
- 20b Internet Protocols and Support
- 1.
telnetlib— Telnet client - 2.
uuid— UUID objects according to RFC 4122 - 3.
urlparse— Parse URLs into components - 4.
SocketServer— A framework for network servers - 5.
BaseHTTPServer— Basic HTTP server - 6.
SimpleHTTPServer— Simple HTTP request handler - 7.
CGIHTTPServer— CGI-capable HTTP request handler - 8.
cookielib— Cookie handling for HTTP clients - 9.
Cookie— HTTP state management - 10.
xmlrpclib— XML-RPC client access - 11.
SimpleXMLRPCServer— Basic XML-RPC server - 12.
DocXMLRPCServer— Self-documenting XML-RPC server
- 1.
- 21 Multimedia Services
- 1.
audioop— Manipulate raw audio data - 2.
imageop— Manipulate raw image data - 3.
aifc— Read and write AIFF and AIFC files - 4.
sunau— Read and write Sun AU files - 5.
wave— Read and write WAV files - 6.
chunk— Read IFF chunked data - 7.
colorsys— Conversions between color systems - 8.
imghdr— Determine the type of an image - 9.
sndhdr— Determine type of sound file - 10.
ossaudiodev— Access to OSS-compatible audio devices
- 1.
- 22 Internationalization
- 23 Program Frameworks
- 24 Graphical User Interfaces with Tk
- 25 Development Tools
- 26. Debugging and Profiling
- 27 Software Packaging and Distribution
- 28 Python Runtime Services
- 1.
sys— System-specific parameters and functions - 2.
sysconfig— Provide access to Python’s configuration information - 3.
__builtin__— Built-in objects - 4.
future_builtins— Python 3 builtins - 5.
__main__— Top-level script environment - 6.
warnings— Warning control - 7.
contextlib— Utilities forwith-statement contexts - 8.
abc— Abstract Base Classes - 9.
atexit— Exit handlers - 10.
traceback— Print or retrieve a stack traceback - 11.
__future__— Future statement definitions - 12.
gc— Garbage Collector interface - 13.
inspect— Inspect live objects - 14.
site— Site-specific configuration hook - 15.
user— User-specific configuration hook - 16.
fpectl— Floating point exception control
- 1.
- 29 Custom Python Interpreters
- 30 Restricted Execution
- 31 Importing Modules
- 1.
imp— Access theimportinternals - 2.
importlib– Convenience wrappers for__import__() - 3. (depr)
imputil— Import utilities - 4.
zipimport— Import modules from Zip archives - 5.
pkgutil— Package extension utility - 6.
modulefinder— Find modules used by a script - 7.
runpy— Locating and executing Python modules
- 1.
- 32 Python Language Services
- 1.
parser— Access Python parse trees - 2.
ast— Abstract Syntax Trees - 3.
symtable— Access to the compiler’s symbol tables - 4.
symbol— Constants used with Python parse trees - 5.
token— Constants used with Python parse trees - 6.
keyword— Testing for Python keywords - 7.
tokenize— Tokenizer for Python source - 8.
tabnanny— Detection of ambiguous indentation - 9.
pyclbr— Python class browser support - 10.
py_compile— Compile Python source files - 11.
compileall— Byte-compile Python libraries - 12.
dis— Disassembler for Python bytecode - 13.
pickletools— Tools for pickle developers
- 1.
- 33 (depr) Python compiler package
- 34. Miscellaneous Services
- 35 MS Windows Specific Services
- 36. Unix Specific Services
- 1.
posix— The most common POSIX system calls - 2.
pwd— The password database - 3.
spwd— The shadow password database - 4.
grp— The group database - 5.
crypt— Function to check Unix passwords - 6. (deprecated)
dl— Call C functions in shared objects - 7.
termios— POSIX style tty control - 8.
tty— Terminal control functions - 9.
pty— Pseudo-terminal utilities - 10.
fcntl— Thefcntlandioctlsystem calls - 11.
pipes— Interface to shell pipelines - 12.
posixfile— File-like objects with locking support - 13.
resource— Resource usage information - 14.
nis— Interface to Sun’s NIS (Yellow Pages) - 15.
syslog— Unix syslog library routines - 16. (deprecated)
commands— Utilities for running commands
- 1.
- 37 Mac OS X specific services
- 1.
ic— Access to the Mac OS X Internet Config - 2.
MacOS— Access to Mac OS interpreter features - 3.
macostools— Convenience routines for file manipulation - 4.
findertools— The finder‘s Apple Events interface - 5.
EasyDialogs— Basic Macintosh dialogs - 6.
FrameWork— Interactive application framework - 7.
autoGIL— Global Interpreter Lock handling in event loops - 8. Mac OS Toolbox Modules
- 9.
ColorPicker— Color selection dialog
- 1.