
Python Documentation contents
*****************************

* What's New in Python
  * What's New In Python 3.0
    * Common Stumbling Blocks
      * Print Is A Function
      * Views And Iterators Instead Of Lists
      * Ordering Comparisons
      * Integers
      * Text Vs. Data Instead Of Unicode Vs. 8-bit
    * Overview Of Syntax Changes
      * New Syntax
      * Changed Syntax
      * Removed Syntax
    * Changes Already Present In Python 2.6
    * Library Changes
    * **PEP 3101**: A New Approach To String Formatting
    * Changes To Exceptions
    * Miscellaneous Other Changes
      * Operators And Special Methods
      * Builtins
    * Build and C API Changes
    * Performance
    * Porting To Python 3.0
  * What's New in Python 2.7
    * Other Language Changes
      * Optimizations
    * New, Improved, and Deprecated Modules
    * Build and C API Changes
      * Port-Specific Changes: Windows
      * Port-Specific Changes: Mac OS X
    * Porting to Python 2.7
    * Acknowledgements
  * What's New in Python 2.6
    * Python 3.0
    * Changes to the Development Process
      * New Issue Tracker: Roundup
      * New Documentation Format: reStructuredText Using Sphinx
    * PEP 343: The 'with' statement
      * Writing Context Managers
      * The contextlib module
    * PEP 366: Explicit Relative Imports From a Main Module
    * PEP 370: Per-user ``site-packages`` Directory
    * PEP 371: The ``multiprocessing`` Package
    * PEP 3101: Advanced String Formatting
    * PEP 3105: ``print`` As a Function
    * PEP 3110: Exception-Handling Changes
    * PEP 3112: Byte Literals
    * PEP 3116: New I/O Library
    * PEP 3118: Revised Buffer Protocol
    * PEP 3119: Abstract Base Classes
    * PEP 3127: Integer Literal Support and Syntax
    * PEP 3129: Class Decorators
    * PEP 3141: A Type Hierarchy for Numbers
      * The ``fractions`` Module
    * Other Language Changes
      * Optimizations
      * Interpreter Changes
    * New, Improved, and Deprecated Modules
      * The ``ast`` module
      * The ``future_builtins`` module
      * The ``json`` module: JavaScript Object Notation
      * The ``plistlib`` module: A Property-List Parser
      * ctypes Enhancements
      * Improved SSL Support
    * Build and C API Changes
      * Port-Specific Changes: Windows
      * Port-Specific Changes: Mac OS X
      * Port-Specific Changes: IRIX
    * Porting to Python 2.6
    * Acknowledgements
  * What's New in Python 2.5
    * PEP 308: Conditional Expressions
    * PEP 309: Partial Function Application
    * PEP 314: Metadata for Python Software Packages v1.1
    * PEP 328: Absolute and Relative Imports
    * PEP 338: Executing Modules as Scripts
    * PEP 341: Unified try/except/finally
    * PEP 342: New Generator Features
    * PEP 343: The 'with' statement
      * Writing Context Managers
      * The contextlib module
    * PEP 352: Exceptions as New-Style Classes
    * PEP 353: Using ssize_t as the index type
    * PEP 357: The '__index__' method
    * Other Language Changes
      * Interactive Interpreter Changes
      * Optimizations
    * New, Improved, and Removed Modules
      * The ctypes package
      * The ElementTree package
      * The hashlib package
      * The sqlite3 package
      * The wsgiref package
    * Build and C API Changes
      * Port-Specific Changes
    * Porting to Python 2.5
    * Acknowledgements
  * What's New in Python 2.4
    * PEP 218: Built-In Set Objects
    * PEP 237: Unifying Long Integers and Integers
    * PEP 289: Generator Expressions
    * PEP 292: Simpler String Substitutions
    * PEP 318: Decorators for Functions and Methods
    * PEP 322: Reverse Iteration
    * PEP 324: New subprocess Module
    * PEP 327: Decimal Data Type
      * Why is Decimal needed?
      * The ``Decimal`` type
      * The ``Context`` type
    * PEP 328: Multi-line Imports
    * PEP 331: Locale-Independent Float/String Conversions
    * Other Language Changes
      * Optimizations
    * New, Improved, and Deprecated Modules
      * cookielib
      * doctest
    * Build and C API Changes
      * Port-Specific Changes
    * Porting to Python 2.4
    * Acknowledgements
  * What's New in Python 2.3
    * PEP 218: A Standard Set Datatype
    * PEP 255: Simple Generators
    * PEP 263: Source Code Encodings
    * PEP 273: Importing Modules from ZIP Archives
    * PEP 277: Unicode file name support for Windows NT
    * PEP 278: Universal Newline Support
    * PEP 279: enumerate()
    * PEP 282: The logging Package
    * PEP 285: A Boolean Type
    * PEP 293: Codec Error Handling Callbacks
    * PEP 301: Package Index and Metadata for Distutils
    * PEP 302: New Import Hooks
    * PEP 305: Comma-separated Files
    * PEP 307: Pickle Enhancements
    * Extended Slices
    * Other Language Changes
      * String Changes
      * Optimizations
    * New, Improved, and Deprecated Modules
      * Date/Time Type
      * The optparse Module
    * Pymalloc: A Specialized Object Allocator
    * Build and C API Changes
      * Port-Specific Changes
    * Other Changes and Fixes
    * Porting to Python 2.3
    * Acknowledgements
  * What's New in Python 2.2
    * Introduction
    * PEPs 252 and 253: Type and Class Changes
      * Old and New Classes
      * Descriptors
      * Multiple Inheritance: The Diamond Rule
      * Attribute Access
      * Related Links
    * PEP 234: Iterators
    * PEP 255: Simple Generators
    * PEP 237: Unifying Long Integers and Integers
    * PEP 238: Changing the Division Operator
    * Unicode Changes
    * PEP 227: Nested Scopes
    * New and Improved Modules
    * Interpreter Changes and Fixes
    * Other Changes and Fixes
    * Acknowledgements
  * What's New in Python 2.1
    * Introduction
    * PEP 227: Nested Scopes
    * PEP 236: __future__ Directives
    * PEP 207: Rich Comparisons
    * PEP 230: Warning Framework
    * PEP 229: New Build System
    * PEP 205: Weak References
    * PEP 232: Function Attributes
    * PEP 235: Importing Modules on Case-Insensitive Platforms
    * PEP 217: Interactive Display Hook
    * PEP 208: New Coercion Model
    * PEP 241: Metadata in Python Packages
    * New and Improved Modules
    * Other Changes and Fixes
    * Acknowledgements
  * What's New in Python 2.0
    * Introduction
    * What About Python 1.6?
    * New Development Process
    * Unicode
    * List Comprehensions
    * Augmented Assignment
    * String Methods
    * Garbage Collection of Cycles
    * Other Core Changes
      * Minor Language Changes
      * Changes to Built-in Functions
    * Porting to 2.0
    * Extending/Embedding Changes
    * Distutils: Making Modules Easy to Install
    * XML Modules
      * SAX2 Support
      * DOM Support
      * Relationship to PyXML
    * Module changes
    * New modules
    * IDLE Improvements
    * Deleted and Deprecated Modules
    * Acknowledgements
* The Python Tutorial
  * Whetting Your Appetite
  * Using the Python Interpreter
    * Invoking the Interpreter
      * Argument Passing
      * Interactive Mode
    * The Interpreter and Its Environment
      * Error Handling
      * Executable Python Scripts
      * Source Code Encoding
      * The Interactive Startup File
  * An Informal Introduction to Python
    * Using Python as a Calculator
      * Numbers
      * Strings
      * About Unicode
      * Lists
    * First Steps Towards Programming
  * More Control Flow Tools
    * ``if`` Statements
    * ``for`` Statements
    * The ``range`` Function
    * ``break`` and ``continue`` Statements, and ``else`` Clauses on
      Loops
    * ``pass`` Statements
    * Defining Functions
    * More on Defining Functions
      * Default Argument Values
      * Keyword Arguments
      * Arbitrary Argument Lists
      * Unpacking Argument Lists
      * Lambda Forms
      * Documentation Strings
    * Intermezzo: Coding Style
  * Data Structures
    * More on Lists
      * Using Lists as Stacks
      * Using Lists as Queues
      * List Comprehensions
      * Nested List Comprehensions
    * The ``del`` statement
    * Tuples and Sequences
    * Sets
    * Dictionaries
    * Looping Techniques
    * More on Conditions
    * Comparing Sequences and Other Types
  * Modules
    * More on Modules
      * Executing modules as scripts
      * The Module Search Path
      * "Compiled" Python files
    * Standard Modules
    * The ``dir`` Function
    * Packages
      * Importing * From a Package
      * Intra-package References
      * Packages in Multiple Directories
  * Input and Output
    * Fancier Output Formatting
      * Old string formatting
    * Reading and Writing Files
      * Methods of File Objects
      * The ``pickle`` Module
  * Errors and Exceptions
    * Syntax Errors
    * Exceptions
    * Handling Exceptions
    * Raising Exceptions
    * User-defined Exceptions
    * Defining Clean-up Actions
    * Predefined Clean-up Actions
  * Classes
    * A Word About Terminology
    * Python Scopes and Name Spaces
      * Scopes and Namespaces Example
    * A First Look at Classes
      * Class Definition Syntax
      * Class Objects
      * Instance Objects
      * Method Objects
    * Random Remarks
    * Inheritance
      * Multiple Inheritance
    * Private Variables
    * Odds and Ends
    * Exceptions Are Classes Too
    * Iterators
    * Generators
    * Generator Expressions
  * Brief Tour of the Standard Library
    * Operating System Interface
    * File Wildcards
    * Command Line Arguments
    * Error Output Redirection and Program Termination
    * String Pattern Matching
    * Mathematics
    * Internet Access
    * Dates and Times
    * Data Compression
    * Performance Measurement
    * Quality Control
    * Batteries Included
  * Brief Tour of the Standard Library -- Part II
    * Output Formatting
    * Templating
    * Working with Binary Data Record Layouts
    * Multi-threading
    * Logging
    * Weak References
    * Tools for Working with Lists
    * Decimal Floating Point Arithmetic
  * What Now?
  * Interactive Input Editing and History Substitution
    * Line Editing
    * History Substitution
    * Key Bindings
    * Commentary
  * Floating Point Arithmetic:  Issues and Limitations
    * Representation Error
* Using Python
  * Command line and environment
    * Command line
      * Interface options
      * Generic options
      * Miscellaneous options
    * Environment variables
      * Debug-mode variables
  * Using Python on Unix platforms
    * Getting and installing the latest version of Python
      * On Linux
      * On FreeBSD and OpenBSD
      * On OpenSolaris
    * Building Python
    * Python-related paths and files
    * Miscellaneous
    * Editors
  * Using Python on Windows
    * Installing Python
    * Alternative bundles
    * Configuring Python
      * Excursus: Setting environment variables
      * Finding the Python executable
      * Finding modules
      * Executing scripts
    * Additional modules
      * PyWin32
      * Py2exe
      * WConio
    * Compiling Python on Windows
    * Other resources
  * Using Python on a Macintosh
    * Getting and Installing MacPython
      * How to run a Python script
      * Running scripts with a GUI
      * Configuration
    * The IDE
    * Installing Additional Python Packages
    * GUI Programming on the Mac
    * Distributing Python Applications on the Mac
    * Application Scripting
    * Other Resources
* The Python Language Reference
  * Introduction
    * Alternate Implementations
    * Notation
  * Lexical analysis
    * Line structure
      * Logical lines
      * Physical lines
      * Comments
      * Encoding declarations
      * Explicit line joining
      * Implicit line joining
      * Blank lines
      * Indentation
      * Whitespace between tokens
    * Other tokens
    * Identifiers and keywords
      * Keywords
      * Reserved classes of identifiers
    * Literals
      * String and Bytes literals
      * String literal concatenation
      * Numeric literals
      * Integer literals
      * Floating point literals
      * Imaginary literals
    * Operators
    * Delimiters
  * Data model
    * Objects, values and types
    * The standard type hierarchy
    * Special method names
      * Basic customization
      * Customizing attribute access
        * Implementing Descriptors
        * Invoking Descriptors
        * __slots__
          * Notes on using *__slots__*
      * Customizing class creation
      * Emulating callable objects
      * Emulating container types
      * Emulating numeric types
      * With Statement Context Managers
      * Special method lookup
  * Execution model
    * Naming and binding
      * Interaction with dynamic features
    * Exceptions
  * Expressions
    * Arithmetic conversions
    * Atoms
      * Identifiers (Names)
      * Literals
      * Parenthesized forms
      * Displays for lists, sets and dictionaries
      * List displays
      * Set displays
      * Dictionary displays
      * Generator expressions
      * Yield expressions
    * Primaries
      * Attribute references
      * Subscriptions
      * Slicings
      * Calls
    * The power operator
    * Unary arithmetic operations
    * Binary arithmetic operations
    * Shifting operations
    * Binary bitwise operations
    * Comparisons
    * Boolean operations
    * Lambdas
    * Expression lists
    * Evaluation order
    * Summary
  * Simple statements
    * Expression statements
    * Assignment statements
      * Augmented assignment statements
    * The ``assert`` statement
    * The ``pass`` statement
    * The ``del`` statement
    * The ``return`` statement
    * The ``yield`` statement
    * The ``raise`` statement
    * The ``break`` statement
    * The ``continue`` statement
    * The ``import`` statement
      * Future statements
    * The ``global`` statement
    * The ``nonlocal`` statement
  * Compound statements
    * The ``if`` statement
    * The ``while`` statement
    * The ``for`` statement
    * The ``try`` statement
    * The ``with`` statement
    * Function definitions
    * Class definitions
  * Top-level components
    * Complete Python programs
    * File input
    * Interactive input
    * Expression input
  * Full Grammar specification
* The Python Standard Library
  * Introduction
  * Built-in Functions
  * Built-in Constants
    * Constants added by the ``site`` module
  * Built-in Objects
  * Built-in Types
    * Truth Value Testing
    * Boolean Operations --- ``and``, ``or``, ``not``
    * Comparisons
    * Numeric Types --- ``int``, ``float``, ``complex``
      * Bit-string Operations on Integer Types
      * Additional Methods on Float
    * Iterator Types
    * Sequence Types --- ``str``, ``bytes``, ``bytearray``, ``list``,
      ``tuple``, ``range``
      * String Methods
      * Old String Formatting Operations
      * Range Type
      * Mutable Sequence Types
      * Bytes and Byte Array Methods
    * Set Types --- ``set``, ``frozenset``
    * Mapping Types --- ``dict``
      * Dictionary view objects
    * File Objects
    * memoryview Types
    * Context Manager Types
    * Other Built-in Types
      * Modules
      * Classes and Class Instances
      * Functions
      * Methods
      * Code Objects
      * Type Objects
      * The Null Object
      * The Ellipsis Object
      * Boolean Values
      * Internal Objects
    * Special Attributes
  * Built-in Exceptions
  * String Services
    * ``string`` --- Common string operations
      * String constants
      * String Formatting
      * Format String Syntax
        * Format Specification Mini-Language
      * Template strings
      * String functions
    * ``re`` --- Regular expression operations
      * Regular Expression Syntax
      * Matching vs Searching
      * Module Contents
      * Regular Expression Objects
      * Match Objects
      * Examples
        * Checking For a Pair
        * Simulating scanf()
        * Avoiding recursion
        * search() vs. match()
        * Making a Phonebook
        * Text Munging
        * Finding all Adverbs
        * Finding all Adverbs and their Positions
        * Raw String Notation
    * ``struct`` --- Interpret bytes as packed binary data
      * Struct Objects
    * ``difflib`` --- Helpers for computing deltas
      * SequenceMatcher Objects
      * SequenceMatcher Examples
      * Differ Objects
      * Differ Example
      * A command-line interface to difflib
    * ``textwrap`` --- Text wrapping and filling
    * ``codecs`` --- Codec registry and base classes
      * Codec Base Classes
        * Codec Objects
        * IncrementalEncoder Objects
        * IncrementalDecoder Objects
        * StreamWriter Objects
        * StreamReader Objects
        * StreamReaderWriter Objects
        * StreamRecoder Objects
      * Encodings and Unicode
      * Standard Encodings
      * ``encodings.idna`` --- Internationalized Domain Names in
        Applications
      * ``encodings.utf_8_sig`` --- UTF-8 codec with BOM signature
    * ``unicodedata`` --- Unicode Database
    * ``stringprep`` --- Internet String Preparation
  * Data Types
    * ``datetime`` --- Basic date and time types
      * Available Types
      * ``timedelta`` Objects
      * ``date`` Objects
      * ``datetime`` Objects
      * ``time`` Objects
      * ``tzinfo`` Objects
      * ``strftime`` Behavior
    * ``calendar`` --- General calendar-related functions
    * ``collections`` --- Container datatypes
      * ABCs - abstract base classes
      * ``deque`` objects
        * ``deque`` Recipes
      * ``defaultdict`` objects
        * ``defaultdict`` Examples
      * ``namedtuple`` Factory Function for Tuples with Named Fields
      * ``UserDict`` objects
      * ``UserList`` objects
      * ``UserString`` objects
    * ``heapq`` --- Heap queue algorithm
      * Theory
    * ``bisect`` --- Array bisection algorithm
      * Examples
    * ``array`` --- Efficient arrays of numeric values
    * ``sched`` --- Event scheduler
      * Scheduler Objects
    * ``queue`` --- A synchronized queue class
      * Queue Objects
    * ``weakref`` --- Weak references
      * Weak Reference Objects
      * Example
    * ``types`` --- Names for built-in types
    * ``copy`` --- Shallow and deep copy operations
    * ``pprint`` --- Data pretty printer
      * PrettyPrinter Objects
      * pprint Example
    * ``reprlib`` --- Alternate ``repr`` implementation
      * Repr Objects
      * Subclassing Repr Objects
  * Numeric and Mathematical Modules
    * ``numbers`` --- Numeric abstract base classes
      * The numeric tower
      * Notes for type implementors
        * Adding More Numeric ABCs
        * Implementing the arithmetic operations
    * ``math`` --- Mathematical functions
    * ``cmath`` --- Mathematical functions for complex numbers
      * Complex coordinates
      * cmath functions
    * ``decimal`` --- Decimal fixed point and floating point
      arithmetic
      * Quick-start Tutorial
      * Decimal objects
        * Logical operands
      * Context objects
      * Signals
      * Floating Point Notes
        * Mitigating round-off error with increased precision
        * Special values
      * Working with threads
      * Recipes
      * Decimal FAQ
    * ``fractions`` --- Rational numbers
    * ``random`` --- Generate pseudo-random numbers
    * ``itertools`` --- Functions creating iterators for efficient
      looping
      * Itertool functions
      * Examples
      * Recipes
    * ``functools`` --- Higher order functions and operations on
      callable objects
      * ``partial`` Objects
    * ``operator`` --- Standard operators as functions
      * Mapping Operators to Functions
  * File and Directory Access
    * ``os.path`` --- Common pathname manipulations
    * ``fileinput`` --- Iterate over lines from multiple input streams
    * ``stat`` --- Interpreting ``stat`` results
    * ``filecmp`` --- File and Directory Comparisons
      * The ``dircmp`` class
    * ``tempfile`` --- Generate temporary files and directories
    * ``glob`` --- Unix style pathname pattern expansion
    * ``fnmatch`` --- Unix filename pattern matching
    * ``linecache`` --- Random access to text lines
    * ``shutil`` --- High-level file operations
      * Example
    * ``macpath`` --- Mac OS 9 path manipulation functions
  * Data Persistence
    * ``pickle`` --- Python object serialization
      * Relationship to other Python modules
      * Data stream format
      * Module Interface
      * What can be pickled and unpickled?
      * Pickling Class Instances
        * Persistence of External Objects
        * Handling Stateful Objects
      * Restricting Globals
      * Example
    * ``copyreg`` --- Register ``pickle`` support functions
    * ``shelve`` --- Python object persistence
      * Restrictions
      * Example
    * ``marshal`` --- Internal Python object serialization
    * ``dbm`` --- Interfaces to Unix "databases"
      * ``dbm.gnu`` --- GNU's reinterpretation of dbm
      * ``dbm.ndbm`` --- Interface based on ndbm
      * ``dbm.dumb`` --- Portable DBM implementation
    * ``sqlite3`` --- DB-API 2.0 interface for SQLite databases
      * Module functions and constants
      * Connection Objects
      * Cursor Objects
      * Row Objects
      * SQLite and Python types
        * Introduction
        * Using adapters to store additional Python types in SQLite
          databases
          * Letting your object adapt itself
          * Registering an adapter callable
        * Converting SQLite values to custom Python types
        * Default adapters and converters
      * Controlling Transactions
      * Using pysqlite efficiently
        * Using shortcut methods
        * Accessing columns by name instead of by index
        * Using the connection as a context manager
  * Data Compression and Archiving
    * ``zlib`` --- Compression compatible with **gzip**
    * ``gzip`` --- Support for **gzip** files
      * Examples of usage
    * ``bz2`` --- Compression compatible with **bzip2**
      * (De)compression of files
      * Sequential (de)compression
      * One-shot (de)compression
    * ``zipfile`` --- Work with ZIP archives
      * ZipFile Objects
      * PyZipFile Objects
      * ZipInfo Objects
    * ``tarfile`` --- Read and write tar archive files
      * TarFile Objects
      * TarInfo Objects
      * Examples
      * Supported tar formats
      * Unicode issues
  * File Formats
    * ``csv`` --- CSV File Reading and Writing
      * Module Contents
      * Dialects and Formatting Parameters
      * Reader Objects
      * Writer Objects
      * Examples
    * ``configparser`` --- Configuration file parser
      * RawConfigParser Objects
      * ConfigParser Objects
      * SafeConfigParser Objects
      * Examples
    * ``netrc`` --- netrc file processing
      * netrc Objects
    * ``xdrlib`` --- Encode and decode XDR data
      * Packer Objects
      * Unpacker Objects
      * Exceptions
    * ``plistlib`` --- Generate and parse Mac OS X ``.plist`` files
      * Examples
  * Cryptographic Services
    * ``hashlib`` --- Secure hashes and message digests
    * ``hmac`` --- Keyed-Hashing for Message Authentication
  * Generic Operating System Services
    * ``os`` --- Miscellaneous operating system interfaces
      * Process Parameters
      * File Object Creation
      * File Descriptor Operations
      * Files and Directories
      * Process Management
      * Miscellaneous System Information
      * Miscellaneous Functions
    * ``io`` --- Core tools for working with streams
      * Module Interface
      * I/O Base Classes
      * Raw File I/O
      * Buffered Streams
      * Text I/O
    * ``time`` --- Time access and conversions
    * ``optparse`` --- More powerful command line option parser
      * Background
        * Terminology
        * What are options for?
        * What are positional arguments for?
      * Tutorial
        * Understanding option actions
        * The store action
        * Handling boolean (flag) options
        * Other actions
        * Default values
        * Generating help
        * Printing a version string
        * How ``optparse`` handles errors
        * Putting it all together
      * Reference Guide
        * Creating the parser
        * Populating the parser
        * Defining options
        * Standard option actions
        * Option attributes
        * Standard option types
        * Parsing arguments
        * Querying and manipulating your option parser
        * Conflicts between options
        * Cleanup
        * Other methods
      * Option Callbacks
        * Defining a callback option
        * How callbacks are called
        * Raising errors in a callback
        * Callback example 1: trivial callback
        * Callback example 2: check option order
        * Callback example 3: check option order (generalized)
        * Callback example 4: check arbitrary condition
        * Callback example 5: fixed arguments
        * Callback example 6: variable arguments
      * Extending ``optparse``
        * Adding new types
        * Adding new actions
    * ``getopt`` --- Parser for command line options
    * ``logging`` --- Logging facility for Python
      * Logging tutorial
        * Simple examples
        * Loggers
        * Handlers
        * Formatters
        * Configuring Logging
        * Configuring Logging for a Library
      * Logging Levels
      * Logger Objects
      * Basic example
      * Logging to multiple destinations
      * Adding contextual information to your logging output
      * Sending and receiving logging events across a network
      * Handler Objects
        * StreamHandler
        * FileHandler
        * WatchedFileHandler
        * RotatingFileHandler
        * TimedRotatingFileHandler
        * SocketHandler
        * DatagramHandler
        * SysLogHandler
        * NTEventLogHandler
        * SMTPHandler
        * MemoryHandler
        * HTTPHandler
      * Formatter Objects
      * Filter Objects
      * LogRecord Objects
      * LoggerAdapter Objects
      * Thread Safety
      * Configuration
        * Configuration functions
        * Configuration file format
        * Configuration server example
      * More examples
        * Multiple handlers and formatters
        * Using logging in multiple modules
    * ``getpass`` --- Portable password input
    * ``curses`` --- Terminal handling for character-cell displays
      * Functions
      * Window Objects
      * Constants
    * ``curses.textpad`` --- Text input widget for curses programs
      * Textbox objects
    * ``curses.wrapper`` --- Terminal handler for curses programs
    * ``curses.ascii`` --- Utilities for ASCII characters
    * ``curses.panel`` --- A panel stack extension for curses.
      * Functions
      * Panel Objects
    * ``platform`` ---  Access to underlying platform's identifying
      data.
      * Cross Platform
      * Java Platform
      * Windows Platform
        * Win95/98 specific
      * Mac OS Platform
      * Unix Platforms
    * ``errno`` --- Standard errno system symbols
    * ``ctypes`` --- A foreign function library for Python.
      * ctypes tutorial
        * Loading dynamic link libraries
        * Accessing functions from loaded dlls
        * Calling functions
        * Fundamental data types
        * Calling functions, continued
        * Calling functions with your own custom data types
        * Specifying the required argument types (function prototypes)
        * Return types
        * Passing pointers (or: passing parameters by reference)
        * Structures and unions
        * Structure/union alignment and byte order
        * Bit fields in structures and unions
        * Arrays
        * Pointers
        * Type conversions
        * Incomplete Types
        * Callback functions
        * Accessing values exported from dlls
        * Surprises
        * Variable-sized data types
      * ctypes reference
        * Finding shared libraries
        * Loading shared libraries
        * Foreign functions
        * Function prototypes
        * Utility functions
        * Data types
        * Fundamental data types
        * Structured data types
        * Arrays and pointers
  * Optional Operating System Services
    * ``select`` --- Waiting for I/O completion
      * Edge and Level Trigger Polling (epoll) Objects
      * Polling Objects
      * Kqueue Objects
      * Kevent Objects
    * ``threading`` --- Higher-level threading interface
      * Thread Objects
      * Lock Objects
      * RLock Objects
      * Condition Objects
      * Semaphore Objects
        * ``Semaphore`` Example
      * Event Objects
      * Timer Objects
      * Using locks, conditions, and semaphores in the ``with``
        statement
      * Importing in threaded code
    * ``dummy_threading`` --- Drop-in replacement for the
      ``threading`` module
    * ``_thread`` --- Low-level threading API
    * ``_dummy_thread`` --- Drop-in replacement for the ``_thread``
      module
    * ``multiprocessing`` --- Process-based "threading" interface
      * Introduction
        * The ``Process`` class
        * Exchanging objects between processes
        * Synchronization between processes
        * Sharing state between processes
        * Using a pool of workers
      * Reference
        * ``Process`` and exceptions
        * Pipes and Queues
        * Miscellaneous
        * Connection Objects
        * Synchronization primitives
        * Shared ``ctypes`` Objects
          * The ``multiprocessing.sharedctypes`` module
        * Managers
          * Namespace objects
          * Customized managers
          * Using a remote manager
        * Proxy Objects
          * Cleanup
        * Process Pools
        * Listeners and Clients
          * Address Formats
        * Authentication keys
        * Logging
        * The ``multiprocessing.dummy`` module
      * Programming guidelines
        * All platforms
        * Windows
      * Examples
    * ``mmap`` --- Memory-mapped file support
    * ``readline`` --- GNU readline interface
      * Example
    * ``rlcompleter`` --- Completion function for GNU readline
      * Completer Objects
  * Interprocess Communication and Networking
    * ``subprocess`` --- Subprocess management
      * Using the subprocess Module
        * Convenience Functions
        * Exceptions
        * Security
      * Popen Objects
      * Replacing Older Functions with the subprocess Module
        * Replacing /bin/sh shell backquote
        * Replacing shell pipeline
        * Replacing os.system()
        * Replacing os.spawn*
        * Replacing os.popen*
    * ``socket`` --- Low-level networking interface
      * Socket Objects
      * Example
    * ``ssl`` --- SSL wrapper for socket objects
      * Functions, Constants, and Exceptions
      * SSLSocket Objects
      * Certificates
      * Examples
        * Testing for SSL support
        * Client-side operation
        * Server-side operation
    * ``signal`` --- Set handlers for asynchronous events
      * Example
    * ``asyncore`` --- Asynchronous socket handler
      * asyncore Example basic HTTP client
    * ``asynchat`` --- Asynchronous socket command/response handler
      * asynchat - Auxiliary Classes and Functions
      * asynchat Example
  * Internet Data Handling
    * ``email`` --- An email and MIME handling package
      * ``email``: Representing an email message
      * ``email``: Parsing email messages
        * FeedParser API
        * Parser class API
        * Additional notes
      * ``email``: Generating MIME documents
      * ``email``: Creating email and MIME objects from scratch
      * ``email``: Internationalized headers
      * ``email``: Representing character sets
      * ``email``: Encoders
      * ``email``: Exception and Defect classes
      * ``email``: Miscellaneous utilities
      * ``email``: Iterators
      * ``email``: Examples
      * Package History
      * Differences from ``mimelib``
    * ``json`` --- JSON encoder and decoder
      * Basic Usage
      * Encoders and decoders
    * ``mailcap`` --- Mailcap file handling
    * ``mailbox`` --- Manipulate mailboxes in various formats
      * ``Mailbox`` objects
        * ``Maildir``
        * ``mbox``
        * ``MH``
        * ``Babyl``
        * ``MMDF``
      * ``Message`` objects
        * ``MaildirMessage``
        * ``mboxMessage``
        * ``MHMessage``
        * ``BabylMessage``
        * ``MMDFMessage``
      * Exceptions
      * Examples
    * ``mimetypes`` --- Map filenames to MIME types
      * MimeTypes Objects
    * ``base64`` --- RFC 3548: Base16, Base32, Base64 Data Encodings
    * ``binhex`` --- Encode and decode binhex4 files
      * Notes
    * ``binascii`` --- Convert between binary and ASCII
    * ``quopri`` --- Encode and decode MIME quoted-printable data
    * ``uu`` --- Encode and decode uuencode files
  * Structured Markup Processing Tools
    * ``html.parser`` --- Simple HTML and XHTML parser
      * Example HTML Parser Application
    * ``html.entities`` --- Definitions of HTML general entities
    * ``xml.parsers.expat`` --- Fast XML parsing using Expat
      * XMLParser Objects
      * ExpatError Exceptions
      * Example
      * Content Model Descriptions
      * Expat error constants
    * ``xml.dom`` --- The Document Object Model API
      * Module Contents
      * Objects in the DOM
        * DOMImplementation Objects
        * Node Objects
        * NodeList Objects
        * DocumentType Objects
        * Document Objects
        * Element Objects
        * Attr Objects
        * NamedNodeMap Objects
        * Comment Objects
        * Text and CDATASection Objects
        * ProcessingInstruction Objects
        * Exceptions
      * Conformance
        * Type Mapping
        * Accessor Methods
    * ``xml.dom.minidom`` --- Lightweight DOM implementation
      * DOM Objects
      * DOM Example
      * minidom and the DOM standard
    * ``xml.dom.pulldom`` --- Support for building partial DOM trees
      * DOMEventStream Objects
    * ``xml.sax`` --- Support for SAX2 parsers
      * SAXException Objects
    * ``xml.sax.handler`` --- Base classes for SAX handlers
      * ContentHandler Objects
      * DTDHandler Objects
      * EntityResolver Objects
      * ErrorHandler Objects
    * ``xml.sax.saxutils`` --- SAX Utilities
    * ``xml.sax.xmlreader`` --- Interface for XML parsers
      * XMLReader Objects
      * IncrementalParser Objects
      * Locator Objects
      * InputSource Objects
      * The ``Attributes`` Interface
      * The ``AttributesNS`` Interface
    * ``xml.etree.ElementTree`` --- The ElementTree XML API
      * Functions
      * The Element Interface
      * ElementTree Objects
      * QName Objects
      * TreeBuilder Objects
      * XMLTreeBuilder Objects
  * Internet Protocols and Support
    * ``webbrowser`` --- Convenient Web-browser controller
      * Browser Controller Objects
    * ``cgi`` --- Common Gateway Interface support.
      * Introduction
      * Using the cgi module
      * Higher Level Interface
      * Functions
      * Caring about security
      * Installing your CGI script on a Unix system
      * Testing your CGI script
      * Debugging CGI scripts
      * Common problems and solutions
    * ``cgitb`` --- Traceback manager for CGI scripts
    * ``wsgiref`` --- WSGI Utilities and Reference Implementation
      * ``wsgiref.util`` -- WSGI environment utilities
      * ``wsgiref.headers`` -- WSGI response header tools
      * ``wsgiref.simple_server`` -- a simple WSGI HTTP server
      * ``wsgiref.validate`` --- WSGI conformance checker
      * ``wsgiref.handlers`` -- server/gateway base classes
      * Examples
    * ``urllib.request`` --- extensible library for opening URLs
      * Request Objects
      * OpenerDirector Objects
      * BaseHandler Objects
      * HTTPRedirectHandler Objects
      * HTTPCookieProcessor Objects
      * ProxyHandler Objects
      * HTTPPasswordMgr Objects
      * AbstractBasicAuthHandler Objects
      * HTTPBasicAuthHandler Objects
      * ProxyBasicAuthHandler Objects
      * AbstractDigestAuthHandler Objects
      * HTTPDigestAuthHandler Objects
      * ProxyDigestAuthHandler Objects
      * HTTPHandler Objects
      * HTTPSHandler Objects
      * FileHandler Objects
      * FTPHandler Objects
      * CacheFTPHandler Objects
      * UnknownHandler Objects
      * HTTPErrorProcessor Objects
      * Examples
      * ``urllib.request`` Restrictions
    * ``urllib.response`` --- Response classes used by urllib.
    * ``urllib.parse`` --- Parse URLs into components
      * Results of ``urlparse`` and ``urlsplit``
    * ``urllib.error`` --- Exception classes raised by urllib.request
    * ``urllib.robotparser`` ---  Parser for robots.txt
    * ``http.client`` --- HTTP protocol client
      * HTTPConnection Objects
      * HTTPResponse Objects
      * Examples
    * ``ftplib`` --- FTP protocol client
      * FTP Objects
    * ``poplib`` --- POP3 protocol client
      * POP3 Objects
      * POP3 Example
    * ``imaplib`` --- IMAP4 protocol client
      * IMAP4 Objects
      * IMAP4 Example
    * ``nntplib`` --- NNTP protocol client
      * NNTP Objects
    * ``smtplib`` --- SMTP protocol client
      * SMTP Objects
      * SMTP Example
    * ``smtpd`` --- SMTP Server
      * SMTPServer Objects
      * DebuggingServer Objects
      * PureProxy Objects
      * MailmanProxy Objects
    * ``telnetlib`` --- Telnet client
      * Telnet Objects
      * Telnet Example
    * ``uuid`` --- UUID objects according to RFC 4122
      * Example
    * ``socketserver`` --- A framework for network servers
      * Server Creation Notes
      * Server Objects
      * RequestHandler Objects
      * Examples
        * ``socketserver.TCPServer`` Example
        * ``socketserver.UDPServer`` Example
        * Asynchronous Mixins
    * ``http.server`` --- HTTP servers
    * ``http.cookies`` --- HTTP state management
      * Cookie Objects
      * Morsel Objects
      * Example
    * ``http.cookiejar`` --- Cookie handling for HTTP clients
      * CookieJar and FileCookieJar Objects
      * FileCookieJar subclasses and co-operation with web browsers
      * CookiePolicy Objects
      * DefaultCookiePolicy Objects
      * Cookie Objects
      * Examples
    * ``xmlrpc.client`` --- XML-RPC client access
      * ServerProxy Objects
      * DateTime Objects
      * Binary Objects
      * Fault Objects
      * ProtocolError Objects
      * MultiCall Objects
      * Convenience Functions
      * Example of Client Usage
      * Example of Client and Server Usage
    * ``xmlrpc.server`` --- Basic XML-RPC servers
      * SimpleXMLRPCServer Objects
        * SimpleXMLRPCServer Example
      * CGIXMLRPCRequestHandler
      * Documenting XMLRPC server
      * DocXMLRPCServer Objects
      * DocCGIXMLRPCRequestHandler
  * Multimedia Services
    * ``audioop`` --- Manipulate raw audio data
    * ``aifc`` --- Read and write AIFF and AIFC files
    * ``sunau`` --- Read and write Sun AU files
      * AU_read Objects
      * AU_write Objects
    * ``wave`` --- Read and write WAV files
      * Wave_read Objects
      * Wave_write Objects
    * ``chunk`` --- Read IFF chunked data
    * ``colorsys`` --- Conversions between color systems
    * ``imghdr`` --- Determine the type of an image
    * ``sndhdr`` --- Determine type of sound file
    * ``ossaudiodev`` --- Access to OSS-compatible audio devices
      * Audio Device Objects
      * Mixer Device Objects
  * Internationalization
    * ``gettext`` --- Multilingual internationalization services
      * GNU **gettext** API
      * Class-based API
        * The ``NullTranslations`` class
        * The ``GNUTranslations`` class
        * Solaris message catalog support
        * The Catalog constructor
      * Internationalizing your programs and modules
        * Localizing your module
        * Localizing your application
        * Changing languages on the fly
        * Deferred translations
      * Acknowledgements
    * ``locale`` --- Internationalization services
      * Background, details, hints, tips and caveats
      * For extension writers and programs that embed Python
      * Access to message catalogs
  * Program Frameworks
    * ``cmd`` --- Support for line-oriented command interpreters
      * Cmd Objects
    * ``shlex`` --- Simple lexical analysis
      * shlex Objects
      * Parsing Rules
  * Graphical User Interfaces with Tk
    * ``tkinter`` --- Python interface to Tcl/Tk
      * Tkinter Modules
      * Tkinter Life Preserver
        * How To Use This Section
        * A Simple Hello World Program
      * A (Very) Quick Look at Tcl/Tk
      * Mapping Basic Tk into Tkinter
      * How Tk and Tkinter are Related
      * Handy Reference
        * Setting Options
        * The Packer
        * Packer Options
        * Coupling Widget Variables
        * The Window Manager
        * Tk Option Data Types
        * Bindings and Events
        * The index Parameter
        * Images
    * ``tkinter.tix`` --- Extension widgets for Tk
      * Using Tix
      * Tix Widgets
        * Basic Widgets
        * File Selectors
        * Hierarchical ListBox
        * Tabular ListBox
        * Manager Widgets
        * Image Types
        * Miscellaneous Widgets
        * Form Geometry Manager
      * Tix Commands
    * ``tkinter.scrolledtext`` --- Scrolled Text Widget
    * ``turtle`` --- Turtle graphics for Tk
      * Introduction
      * Overview over available Turtle and Screen methods
        * Turtle methods
        * Methods of TurtleScreen/Screen
      * Methods of RawTurtle/Turtle and corresponding functions
        * Turtle motion
        * Tell Turtle's state
        * Settings for measurement
        * Pen control
          * Drawing state
          * Color control
          * Filling
          * More drawing control
        * Turtle state
          * Visibility
          * Appearance
        * Using events
        * Special Turtle methods
        * Excursus about the use of compound shapes
      * Methods of TurtleScreen/Screen and corresponding functions
        * Window control
        * Animation control
        * Using screen events
        * Settings and special methods
        * Methods specific to Screen, not inherited from TurtleScreen
      * The public classes of the module ``turtle``
      * Help and configuration
        * How to use help
        * Translation of docstrings into different languages
        * How to configure Screen and Turtles
      * Demo scripts
      * Changes since Python 2.6
    * IDLE
      * Menus
        * File menu
        * Edit menu
        * Windows menu
        * Debug menu (in the Python Shell window only)
      * Basic editing and navigation
        * Automatic indentation
        * Python Shell window
      * Syntax colors
        * Command line usage
    * Other Graphical User Interface Packages
  * Development Tools
    * ``pydoc`` --- Documentation generator and online help system
    * ``doctest`` --- Test interactive Python examples
      * Simple Usage: Checking Examples in Docstrings
      * Simple Usage: Checking Examples in a Text File
      * How It Works
        * Which Docstrings Are Examined?
        * How are Docstring Examples Recognized?
        * What's the Execution Context?
        * What About Exceptions?
        * Option Flags and Directives
        * Warnings
      * Basic API
      * Unittest API
      * Advanced API
        * DocTest Objects
        * Example Objects
        * DocTestFinder objects
        * DocTestParser objects
        * DocTestRunner objects
        * OutputChecker objects
      * Debugging
      * Soapbox
    * ``unittest`` --- Unit testing framework
      * Basic example
      * Organizing test code
      * Re-using old test code
      * Classes and functions
      * TestCase Objects
      * TestSuite Objects
      * TestResult Objects
      * TestLoader Objects
    * 2to3 - Automated Python 2 to 3 code translation
      * Using 2to3
      * ``lib2to3`` - 2to3's library
    * ``test`` --- Regression tests package for Python
      * Writing Unit Tests for the ``test`` package
      * Running tests using ``test.regrtest``
    * ``test.support`` --- Utility functions for tests
  * Debugging and Profiling
    * ``bdb`` --- Debugger framework
    * ``pdb`` --- The Python Debugger
    * Debugger Commands
    * The Python Profilers
      * Introduction to the profilers
      * Instant User's Manual
      * What Is Deterministic Profiling?
      * Reference Manual -- ``profile`` and ``cProfile``
        * The ``Stats`` Class
      * Limitations
      * Calibration
      * Extensions --- Deriving Better Profilers
    * ``timeit`` --- Measure execution time of small code snippets
      * Command Line Interface
      * Examples
    * ``trace`` --- Trace or track Python statement execution
      * Command Line Usage
      * Programming Interface
  * Python Runtime Services
    * ``sys`` --- System-specific parameters and functions
    * ``builtins`` --- Built-in objects
    * ``__main__`` --- Top-level script environment
    * ``warnings`` --- Warning control
      * Warning Categories
      * The Warnings Filter
      * Temporarily Suppressing Warnings
      * Testing Warnings
      * Available Functions
      * Available Context Managers
    * ``contextlib`` --- Utilities for ``with``-statement contexts.
    * ``abc`` --- Abstract Base Classes
    * ``atexit`` --- Exit handlers
      * ``atexit`` Example
    * ``traceback`` --- Print or retrieve a stack traceback
      * Traceback Examples
    * ``__future__`` --- Future statement definitions
    * ``gc`` --- Garbage Collector interface
    * ``inspect`` --- Inspect live objects
      * Types and members
      * Retrieving source code
      * Classes and functions
      * The interpreter stack
    * ``site`` --- Site-specific configuration hook
    * ``fpectl`` --- Floating point exception control
      * Example
      * Limitations and other considerations
  * Custom Python Interpreters
    * ``code`` --- Interpreter base classes
      * Interactive Interpreter Objects
      * Interactive Console Objects
    * ``codeop`` --- Compile Python code
  * Importing Modules
    * ``imp`` --- Access the ``import`` internals
      * Examples
    * ``zipimport`` --- Import modules from Zip archives
      * zipimporter Objects
      * Examples
    * ``pkgutil`` --- Package extension utility
    * ``modulefinder`` --- Find modules used by a script
      * Example usage of ``ModuleFinder``
    * ``runpy`` --- Locating and executing Python modules
  * Python Language Services
    * ``parser`` --- Access Python parse trees
      * Creating ST Objects
      * Converting ST Objects
      * Queries on ST Objects
      * Exceptions and Error Handling
      * ST Objects
      * Examples
        * Emulation of ``compile``
        * Information Discovery
    * Abstract Syntax Trees
      * Node classes
      * Abstract Grammar
      * ``ast`` Helpers
    * ``symtable`` --- Access to the compiler's symbol tables
      * Generating Symbol Tables
      * Examining Symbol Tables
    * ``symbol`` --- Constants used with Python parse trees
    * ``token`` --- Constants used with Python parse trees
    * ``keyword`` --- Testing for Python keywords
    * ``tokenize`` --- Tokenizer for Python source
    * ``tabnanny`` --- Detection of ambiguous indentation
    * ``pyclbr`` --- Python class browser support
      * Class Objects
      * Function Objects
    * ``py_compile`` --- Compile Python source files
    * ``compileall`` --- Byte-compile Python libraries
    * ``dis`` --- Disassembler for Python bytecode
      * Python Bytecode Instructions
    * ``pickletools`` --- Tools for pickle developers.
    * ``distutils`` --- Building and installing Python modules
  * Miscellaneous Services
    * ``formatter`` --- Generic output formatting
      * The Formatter Interface
      * Formatter Implementations
      * The Writer Interface
      * Writer Implementations
  * MS Windows Specific Services
    * ``msilib`` --- Read and write Microsoft Installer files
      * Database Objects
      * View Objects
      * Summary Information Objects
      * Record Objects
      * Errors
      * CAB Objects
      * Directory Objects
      * Features
      * GUI classes
      * Precomputed tables
    * ``msvcrt`` -- Useful routines from the MS VC++ runtime
      * File Operations
      * Console I/O
      * Other Functions
    * ``winreg`` -- Windows registry access
      * Registry Handle Objects
    * ``winsound`` --- Sound-playing interface for Windows
  * Unix Specific Services
    * ``posix`` --- The most common POSIX system calls
      * Large File Support
      * Notable Module Contents
    * ``pwd`` --- The password database
    * ``spwd`` --- The shadow password database
    * ``grp`` --- The group database
    * ``crypt`` --- Function to check Unix passwords
    * ``termios`` --- POSIX style tty control
      * Example
    * ``tty`` --- Terminal control functions
    * ``pty`` --- Pseudo-terminal utilities
    * ``fcntl`` --- The ``fcntl`` and ``ioctl`` system calls
    * ``pipes`` --- Interface to shell pipelines
      * Template Objects
    * ``resource`` --- Resource usage information
      * Resource Limits
      * Resource Usage
    * ``nis`` --- Interface to Sun's NIS (Yellow Pages)
    * ``syslog`` --- Unix syslog library routines
  * Undocumented Modules
    * Platform specific modules
* Extending and Embedding the Python Interpreter
  * Extending Python with C or C++
    * A Simple Example
    * Intermezzo: Errors and Exceptions
    * Back to the Example
    * The Module's Method Table and Initialization Function
    * Compilation and Linkage
    * Calling Python Functions from C
    * Extracting Parameters in Extension Functions
    * Keyword Parameters for Extension Functions
    * Building Arbitrary Values
    * Reference Counts
      * Reference Counting in Python
      * Ownership Rules
      * Thin Ice
      * NULL Pointers
    * Writing Extensions in C++
    * Providing a C API for an Extension Module
  * Defining New Types
    * The Basics
      * Adding data and methods to the Basic example
      * Providing finer control over data attributes
      * Supporting cyclic garbage collection
      * Subclassing other types
    * Type Methods
      * Finalization and De-allocation
      * Object Presentation
      * Attribute Management
        * Generic Attribute Management
        * Type-specific Attribute Management
      * Object Comparison
      * Abstract Protocol Support
      * Weak Reference Support
      * More Suggestions
  * Building C and C++ Extensions with distutils
    * Distributing your extension modules
  * Building C and C++ Extensions on Windows
    * A Cookbook Approach
    * Differences Between Unix and Windows
    * Using DLLs in Practice
  * Embedding Python in Another Application
    * Very High Level Embedding
    * Beyond Very High Level Embedding: An overview
    * Pure Embedding
    * Extending Embedded Python
    * Embedding Python in C++
    * Linking Requirements
* Python/C API Reference Manual
  * Introduction
    * Include Files
    * Objects, Types and Reference Counts
      * Reference Counts
        * Reference Count Details
      * Types
    * Exceptions
    * Embedding Python
    * Debugging Builds
  * The Very High Level Layer
  * Reference Counting
  * Exception Handling
    * Standard Exceptions
  * Utilities
    * Operating System Utilities
    * System Functions
    * Process Control
    * Importing Modules
    * Data marshalling support
    * Parsing arguments and building values
    * String conversion and formatting
    * Reflection
  * Abstract Objects Layer
    * Object Protocol
    * Number Protocol
    * Sequence Protocol
    * Mapping Protocol
    * Iterator Protocol
    * Buffer Protocol
  * Concrete Objects Layer
    * Fundamental Objects
      * Type Objects
      * The None Object
    * Numeric Objects
      * Integer Objects
      * Boolean Objects
      * Floating Point Objects
      * Complex Number Objects
        * Complex Numbers as C Structures
        * Complex Numbers as Python Objects
    * Sequence Objects
      * Bytes Objects
      * Byte Array Objects
      * Unicode Objects and Codecs
        * Unicode Objects
        * Built-in Codecs
        * Methods and Slot Functions
      * Buffer Objects
        * Buffer related functions
        * MemoryView objects
      * Tuple Objects
      * List Objects
    * Mapping Objects
      * Dictionary Objects
    * Other Objects
      * Set Objects
      * Function Objects
      * Instance Method Objects
      * Method Objects
      * File Objects
      * Module Objects
      * Iterator Objects
      * Descriptor Objects
      * Slice Objects
      * Weak Reference Objects
      * CObjects
      * Cell Objects
      * Generator Objects
      * DateTime Objects
  * Initialization, Finalization, and Threads
    * Thread State and the Global Interpreter Lock
    * Profiling and Tracing
    * Advanced Debugger Support
  * Memory Management
    * Overview
    * Memory Interface
    * Examples
  * Object Implementation Support
    * Allocating Objects on the Heap
    * Common Object Structures
    * Type Objects
    * Number Object Structures
    * Mapping Object Structures
    * Sequence Object Structures
    * Buffer Object Structures
    * Supporting Cyclic Garbage Collection
* Distributing Python Modules
  * An Introduction to Distutils
    * Concepts & Terminology
    * A Simple Example
    * General Python terminology
    * Distutils-specific terminology
  * Writing the Setup Script
    * Listing whole packages
    * Listing individual modules
    * Describing extension modules
      * Extension names and packages
      * Extension source files
      * Preprocessor options
      * Library options
      * Other options
    * Relationships between Distributions and Packages
    * Installing Scripts
    * Installing Package Data
    * Installing Additional Files
    * Additional meta-data
    * Debugging the setup script
  * Writing the Setup Configuration File
  * Creating a Source Distribution
    * Specifying the files to distribute
    * Manifest-related options
  * Creating Built Distributions
    * Creating dumb built distributions
    * Creating RPM packages
    * Creating Windows Installers
    * Cross-compiling on Windows
      * The Postinstallation script
    * Vista User Access Control (UAC)
  * Registering with the Package Index
    * The .pypirc file
  * Uploading Packages to the Package Index
  * Examples
    * Pure Python distribution (by module)
    * Pure Python distribution (by package)
    * Single extension module
  * Extending Distutils
    * Integrating new commands
    * Adding new distribution types
  * Command Reference
    * Installing modules: the **install** command family
      * **install_data**
      * **install_scripts**
    * Creating a source distribution: the **sdist** command
  * API Reference
    * ``distutils.core`` --- Core Distutils functionality
    * ``distutils.ccompiler`` --- CCompiler base class
    * ``distutils.unixccompiler`` --- Unix C Compiler
    * ``distutils.msvccompiler`` --- Microsoft Compiler
    * ``distutils.bcppcompiler`` --- Borland Compiler
    * ``distutils.cygwincompiler`` --- Cygwin Compiler
    * ``distutils.emxccompiler`` --- OS/2 EMX Compiler
    * ``distutils.mwerkscompiler`` --- Metrowerks CodeWarrior support
    * ``distutils.archive_util`` ---  Archiving utilities
    * ``distutils.dep_util`` --- Dependency checking
    * ``distutils.dir_util`` --- Directory tree operations
    * ``distutils.file_util`` --- Single file operations
    * ``distutils.util`` --- Miscellaneous other utility functions
    * ``distutils.dist`` --- The Distribution class
    * ``distutils.extension`` --- The Extension class
    * ``distutils.debug`` --- Distutils debug mode
    * ``distutils.errors`` --- Distutils exceptions
    * ``distutils.fancy_getopt`` --- Wrapper around the standard
      getopt module
    * ``distutils.filelist`` --- The FileList class
    * ``distutils.log`` --- Simple PEP 282-style logging
    * ``distutils.spawn`` --- Spawn a sub-process
    * ``distutils.sysconfig`` --- System configuration information
    * ``distutils.text_file`` --- The TextFile class
    * ``distutils.version`` --- Version number classes
    * ``distutils.cmd`` --- Abstract base class for Distutils commands
    * ``distutils.command`` --- Individual Distutils commands
    * ``distutils.command.bdist`` --- Build a binary installer
    * ``distutils.command.bdist_packager`` --- Abstract base class for
      packagers
    * ``distutils.command.bdist_dumb`` --- Build a "dumb" installer
    * ``distutils.command.bdist_msi`` --- Build a Microsoft Installer
      binary package
    * ``distutils.command.bdist_rpm`` --- Build a binary distribution
      as a Redhat RPM and SRPM
    * ``distutils.command.bdist_wininst`` --- Build a Windows
      installer
    * ``distutils.command.sdist`` --- Build a source distribution
    * ``distutils.command.build`` --- Build all files of a package
    * ``distutils.command.build_clib`` --- Build any C libraries in a
      package
    * ``distutils.command.build_ext`` --- Build any extensions in a
      package
    * ``distutils.command.build_py`` --- Build the .py/.pyc files of a
      package
    * ``distutils.command.build_scripts`` --- Build the scripts of a
      package
    * ``distutils.command.clean`` --- Clean a package build area
    * ``distutils.command.config`` --- Perform package configuration
    * ``distutils.command.install`` --- Install a package
    * ``distutils.command.install_data`` --- Install data files from a
      package
    * ``distutils.command.install_headers`` --- Install C/C++ header
      files from a package
    * ``distutils.command.install_lib`` --- Install library files from
      a package
    * ``distutils.command.install_scripts`` --- Install script files
      from a package
    * ``distutils.command.register`` --- Register a module with the
      Python Package Index
    * Creating a new Distutils command
* Installing Python Modules
  * Introduction
    * Best case: trivial installation
    * The new standard: Distutils
  * Standard Build and Install
    * Platform variations
    * Splitting the job up
    * How building works
    * How installation works
  * Alternate Installation
    * Alternate installation: the home scheme
    * Alternate installation: Unix (the prefix scheme)
    * Alternate installation: Windows (the prefix scheme)
  * Custom Installation
    * Modifying Python's Search Path
  * Distutils Configuration Files
    * Location and names of config files
    * Syntax of config files
  * Building Extensions: Tips and Tricks
    * Tweaking compiler/linker flags
    * Using non-Microsoft compilers on Windows
      * Borland/CodeGear C++
      * GNU C / Cygwin / MinGW
* Documenting Python
  * Introduction
  * Style Guide
  * reStructuredText Primer
    * Paragraphs
    * Inline markup
    * Lists and Quotes
    * Source Code
    * Hyperlinks
      * External links
      * Internal links
    * Sections
    * Explicit Markup
    * Directives
    * Footnotes
    * Comments
    * Source encoding
    * Gotchas
  * Additional Markup Constructs
    * Meta-information markup
    * Module-specific markup
    * Information units
    * Showing code examples
    * Inline markup
    * Cross-linking markup
    * Paragraph-level markup
    * Table-of-contents markup
    * Index-generating markup
    * Grammar production displays
    * Substitutions
  * Differences to the LaTeX markup
    * Inline markup
    * Information units
    * Structure
* Python HOWTOs
  * Python Advocacy HOWTO
    * Reasons to Use Python
      * Programmability
      * Prototyping
      * Simplicity and Ease of Understanding
      * Java Integration
    * Arguments and Rebuttals
    * Useful Resources
  * Porting Extension Modules to 3.0
    * Conditional compilation
    * Changes to Object APIs
      * str/unicode Unification
      * long/int Unification
    * Module initialization and state
    * Other options
  * Curses Programming with Python
    * What is curses?
      * The Python curses module
    * Starting and ending a curses application
    * Windows and Pads
    * Displaying Text
      * Attributes and Color
    * User Input
    * For More Information
  * Idioms and Anti-Idioms in Python
    * Language Constructs You Should Not Use
      * from module import *
        * Inside Function Definitions
        * At Module Level
        * When It Is Just Fine
      * from module import name1, name2
      * except:
    * Exceptions
    * Using the Batteries
    * Using Backslash to Continue Statements
  * Functional Programming HOWTO
    * Introduction
      * Formal provability
      * Modularity
      * Ease of debugging and testing
      * Composability
    * Iterators
      * Data Types That Support Iterators
    * Generator expressions and list comprehensions
    * Generators
      * Passing values into a generator
    * Built-in functions
    * The itertools module
      * Creating new iterators
      * Calling functions on elements
      * Selecting elements
      * Grouping elements
    * The functools module
      * The operator module
      * The functional module
    * Small functions and the lambda expression
    * Revision History and Acknowledgements
    * References
      * General
      * Python-specific
      * Python documentation
  * Regular Expression HOWTO
    * Introduction
    * Simple Patterns
      * Matching Characters
      * Repeating Things
    * Using Regular Expressions
      * Compiling Regular Expressions
      * The Backslash Plague
      * Performing Matches
      * Module-Level Functions
      * Compilation Flags
    * More Pattern Power
      * More Metacharacters
      * Grouping
      * Non-capturing and Named Groups
      * Lookahead Assertions
    * Modifying Strings
      * Splitting Strings
      * Search and Replace
    * Common Problems
      * Use String Methods
      * match() versus search()
      * Greedy versus Non-Greedy
      * Not Using re.VERBOSE
    * Feedback
  * Socket Programming HOWTO
    * Sockets
      * History
    * Creating a Socket
      * IPC
    * Using a Socket
      * Binary Data
    * Disconnecting
      * When Sockets Die
    * Non-blocking Sockets
      * Performance
  * Unicode HOWTO
    * Introduction to Unicode
      * History of Character Codes
      * Definitions
      * Encodings
      * References
    * Python's Unicode Support
      * The String Type
      * Converting to Bytes
      * Unicode Literals in Python Source Code
      * Unicode Properties
      * References
    * Reading and Writing Unicode Data
      * Unicode filenames
      * Tips for Writing Unicode-aware Programs
      * References
    * Revision History and Acknowledgements
  * HOWTO Fetch Internet Resources Using The urllib Package
    * Introduction
    * Fetching URLs
      * Data
      * Headers
    * Handling Exceptions
      * URLError
      * HTTPError
        * Error Codes
      * Wrapping it Up
        * Number 1
        * Number 2
    * info and geturl
    * Openers and Handlers
    * Basic Authentication
    * Proxies
    * Sockets and Layers
    * Footnotes
  * HOWTO Use Python in the web
    * The low-level view
      * Common Gateway Interface
        * Simple script for testing CGI
        * Setting up CGI on your own server
        * Common problems with CGI scripts
      * mod_python
      * FastCGI and SCGI
        * Setting up FastCGI
      * mod_wsgi
    * Step back: WSGI
      * WSGI Servers
      * Case study: MoinMoin
    * Model-view-controller
    * Ingredients for web sites
      * Templates
      * Data persistence
    * Frameworks
      * Some notable frameworks
        * Django
        * TurboGears
        * Other notable frameworks
* Glossary
* About these documents
  * Contributors to the Python Documentation
* Reporting Bugs in Python
* Copyright
* History and License
  * History of the software
  * Terms and conditions for accessing or otherwise using Python
  * Licenses and Acknowledgements for Incorporated Software
    * Mersenne Twister
    * Sockets
    * Floating point exception control
    * Asynchronous socket services
    * Cookie management
    * Profiling
    * Execution tracing
    * UUencode and UUdecode functions
    * XML Remote Procedure Calls
    * test_epoll
    * Select kqueue