Index
Symbols
- !# (shebang) character, Running Python Programs
- != (inequality) comparisons, Comparisons
- " (double quotes), Strings
- """" (triple quotes), Strings
- # (hash sign), Lines and Indentation
- % (percent) character, Expressions and Operators, Division
- % formatting (see format with %)
- %r (for logging errors), When to use %r
- %s (in SQL), Parameter Style
- ' (single quotes), Strings
- () (parentheses)
- function calls, The def Statement, Calling Functions
- generator expressions, Generator expressions
- import, The from Statement
- list comprehension, List comprehensions
- operator precedence, Expressions and Operators
- regular expressions, Pattern-String Syntax, Alternatives
- ternary operator, The ternary operator
- tuples, Tuples
- , (commas)
- - (hyphens), Command-Line Syntax and Options
- -c command, Command-Line Syntax and Options
- -m module, Command-Line Syntax and Options
- -O (optimize) command, Command-Line Syntax and Options-Command-Line Syntax and Options, Running Python Programs, The assert Statement, Small-Scale Optimization
- -OO (optimize command), Command-Line Syntax and Options-Command-Line Syntax and Options, Small-Scale Optimization
- -Wdefault flag, asyncio developing and debugging
- -Werror flag, Preparing for Python 3
- ... (prompt string), Interactive Sessions
- .jar files, Jython
- .NET, IronPython
- .py extension, Command-Line Syntax and Options, Running Python Programs, Searching the Filesystem for a Module, The sys Module
- .pyc extension, Running Python Programs, Searching the Filesystem for a Module, The sys Module, Wheels make the Python world go round
- .pyo extension, Running Python Programs, Searching the Filesystem for a Module, The sys Module
- .tar.gz files, Creating an sdist
- / (forward slash), Command-Line Syntax and Options-Command-Line Syntax and Options
- 2to3 utility, Preparing for Python 3
- <> (angle brackets), Bottle routing
- == (equality) comparisons, Comparisons, The math and cmath Modules
- >>> (prompt string), Interactive Sessions
- @ (matrix multiplication) operator, Operators, Matrix Operations in NumPy
- [] (square brackets), Reference Conventions, Command-Line Syntax and Options, Lines and Indentation, Literals, Tuples, Modifying a list
- (backslash), Command-Line Syntax and Options, Lines and Indentation, Strings
- _ (single underscore), Interactive Sessions, Identifiers, New in 3.6: Underscores in numeric literals, Module-private variables
- __bytes__, General-Purpose Special Methods
- __call__, General-Purpose Special Methods
- __contains__, Container methods
- __debug__, The __debug__ Built-in Variable
- __delattr__, General-Purpose Special Methods
- __delitem__, Container methods
- __del__, General-Purpose Special Methods
- __dir__, General-Purpose Special Methods
- __eq__, General-Purpose Special Methods
- __format__, General-Purpose Special Methods
- __future__, Keywords, Division
- __future__ module, Preparing for Python 3
- __getattribute__, __getattribute__, General-Purpose Special Methods
- __getattr__, General-Purpose Special Methods
- __getitem__, Container methods
- __ge__, General-Purpose Special Methods
- __gt__, General-Purpose Special Methods
- __hash__, General-Purpose Special Methods
- __import__, sys.modules Entries
- __init__, Python Classes, General-Purpose Special Methods
- __iter__, Container methods
- __len__, Container methods
- __le__, General-Purpose Special Methods
- __lt__, General-Purpose Special Methods
- __metaclass__, How Python v2 Determines a Class’s Metaclass
- __new__, General-Purpose Special Methods
- __next__, Iterators
- __ne__, General-Purpose Special Methods
- __nonzero__, General-Purpose Special Methods
- __repr__, General-Purpose Special Methods
- __setattr__, General-Purpose Special Methods
- __setitem__, Container methods
- __slots__, __slots__
- __str__, General-Purpose Special Methods
- __unicode__, General-Purpose Special Methods
- {} (curly braces), Command-Line Syntax and Options, Lines and Indentation, Sets-Dictionaries
- | (vertical bars), Command-Line Syntax and Options
A
- abc module, abc
- ABCs (abstract base classes), Abstract Base Classes-The numbers module, Built-in Types, The collections Module
- accessor (see getter)
- acknowledgments, Acknowledgments
- Adafruit Feather, MicroPython: Is your child already a programmer?
- aiohttp, The asyncio Module (v3 Only)
- Anaconda, Anaconda and Miniconda, Distributing Extensions and Programs, v2 source with conversion to v3
- ancestor, Method resolution order
- angle brackets (<>), Bottle routing
- annotations, Function Annotations and Type Hints (v3 Only)
- application (process) layer, Networking Basics
- argparse module, The argparse Module
- arguments
- command-line, Command-Line Syntax and Options, The jython Interpreter, The argparse Module-The argparse Module, C-coded extensions
- keyword, Kinds of arguments
- kinds of, Kinds of arguments
- named, Dictionaries, Kinds of arguments
- optional, Reference Conventions
- passing, The semantics of argument passing
- positional, Dictionaries, Kinds of arguments
- arithmetic operations, Arithmetic Operations, Special Methods for Numeric Objects
- array module, The array Module-The array Module
- arrays, processing, Array Processing
- ASCII, Character Sets, Built-in Functions, The string Module-Value Selection, Unicode-The codecs Module
- assert statements, Keywords, The assert Statement
- assignment
- asynchronous
- architectures, Networking Basics
- asyncio module, The asyncio Module (v3 Only)-Asyncio queues
- benefits of, Asynchronous Alternatives
- callback-based, Asynchronous Alternatives
- coroutine-based, Asynchronous Alternatives-Coroutine-Based Async Architectures
- multiplexed, Asynchronous Alternatives
- protocol, Transports and protocols
- queue, Synchronization and Queues
- selectors module, The selectors Module-selectors echo server example
- synchronization, Synchronization and Queues
- task, Tasks
- transport, Transports and protocols
- vs. threads and processes, Threads and Processes
- asyncio module
- async and await keywords, async and await
- async for statement, async for
- async with statement, async with
- asyncio coroutines, asyncio coroutines
- asyncio streams, asyncio streams
- asyncio.Future class, Futures
- asyncio.Task class, Tasks
- authoring open source code, The asyncio Module (v3 Only)
- awaitable object, async and await
- backward compatibility, Coroutines in asyncio
- call scheduling, Calls, time, and sleep
- connections and servers, Connections and server
- developing and debugging, asyncio developing and debugging
- error handling, Error handling
- event loop interface, asyncio’s Event Loop
- executors, Executor
- file descriptors, Watching file descriptors
- generators, The asyncio Module (v3 Only)
- higher-abstraction modules, The asyncio Module (v3 Only)
- loop state and debugging mode, Loop state and debugging mode
- protocol-based examples, Protocol-based examples: echo client and server
- socket operations and hostnames, socket operations; hostnames
- synchronization and queues, Synchronization and Queues
- tasks, Tasks
- transports and protocols, Transports and protocols
- Unix signals, Unix signals
- AsyncSSH, The asyncio Module (v3 Only)
- atexit module, Termination Functions
- atomic, Threads in Python
- attribute
- attribute names, Object attributes and items, Attribute Reference Basics
- authentication handlers, Handling authentication
- automatic code conversion, Preparing for Python 3
- (see also v2/v3 migration and coexistence)
- awaitable objects, async and await
B
- backport, v2/v3 Migration and Coexistence
- backslash (), Command-Line Syntax and Options, Lines and Indentation, Strings
- backward compatibility, Python Development and Versions, Avoid “Old-Style” Classes
- Barrier objects, Barrier objects (v3 only)
- base class, The class Statement, Inheritance
- base64 module, The base64 Module
- BaseException, Exception Objects
- BDFL (Benevolent Dictator For Life), Python Development and Versions
- (see also van Rossum, Guido)
- Beagle Board, MicroPython: Is your child already a programmer?
- BeautifulSoup package
- attribute references, Attribute references on instances of BeautifulSoup and Tag
- BeautifulSoup class, The BeautifulSoup Class
- CSS selectors, bs4 CSS Selectors
- elements, next_element, previous_element, next_elements, previous_elements
- encoding, BeautifulSoup, Unicode, and encoding
- HTML editing and creation, Editing and Creating HTML with bs4-Building HTML with bs4
- installing vs. importing, The BeautifulSoup Third-Party Package
- navigable classes, The Navigable Classes of bs4
- parents and siblings, parent, parents
- parser selection, Which parser BeautifulSoup uses
- parsing example, An HTML Parsing Example with BeautifulSoup
- search methods, bs4 find... Methods (“Search Methods”)-Search method arguments: other named arguments
- string handling, Getting an actual string
- Tag instance contents, children and descendants, contents, children, descendants
- Tag instance indexing, Indexing instances of Tag
- version selection, The BeautifulSoup Third-Party Package
- behavior-driven development, Unit Testing and System Testing
- benchmarking (load testing), Testing, Debugging, and Optimizing, Benchmarking
- Berkeley Database (BSD DB), Berkeley DB Interfacing
- Big Data (see data science)
- big-O notation, Large-Scale Optimization
- binaries (see binary distribution)
- binary data, in v2 vs. v3, Text and Binary Data
- binary distribution, Installation, Numeric Constants
- binding/unbinding methods, General-Purpose Special Methods
- bitwise operations on integers, Bitwise Operations on Integers
- black-box testing, Unit Testing and System Testing
- BLOB, Factory Functions
- blocking, Lines and Indentation, Threads and Processes, Client-Server Computing, Parsing XML within an asynchronous loop
- bool data type, Boolean Values, Built-in Types
- Boolean values, Boolean Values
- Bottle web framework
- bottlenecks, Optimization
- bound method objects, Bound and Unbound Methods
- break statements, The while Statement-The for Statement, The break Statement
- breakpoint, The pdb Module
- BSD DB (Berkeley Database), Berkeley DB Interfacing
- BSD Unix system, The Berkeley Socket Interface
- buffering, Buffering
- built-ins (see core built-ins)
- byte object, Strings, Functions and classes of pickle and cPickle
- byte strings, Strings and Things, The json Module, Methods of mmap Objects, The base64 Module, Text and Binary Data
- bytearray data type, Built-in Types
- bytecode, The Python Language, Running Python Programs
- bytes data type, Built-in Types
- BytesIO class, In-Memory “Files”: io.StringIO and io.BytesIO
- bytestring, Strings and Things, String Formatting
- bz2 module, The bz2 Module
C
- C API
- abstract layer functions, Abstract Layer Functions-Abstract Layer Functions
- accessing arguments, Accessing Arguments-Accessing Arguments
- building/installing C-coded extensions, Building and Installing C-Coded Python Extensions
- concrete layer functions, Concrete Layer Functions-Concrete Layer Functions
- creating Python values, Creating Python Values-Creating Python Values
- defining new types, Defining New Types-Type definition example
- exceptions, Exceptions-Exceptions
- module initialization, The Initialization Module
- overview of C-coded extension modules, Overview of C-Coded Python Extension Modules-Overview of C-Coded Python Extension Modules
- PyMethodDef struct, The PyMethodDef struct
- reference counting, Reference Counting
- return values of C API functions, Return Values of Python’s C API Functions
- simple extension example, A Simple Extension Example-A Simple Extension Example
- x extension module, Extending Python with Python’s C API
- C language, Extending and Embedding Classic Python, Embedding Python
- C++ language, Extending Python Without Python’s C API
- cache, The linecache Module
- calendar module, The calendar Module
- callable, Callables, General-Purpose Special Methods, Introspecting callables in v3
- callbacks, Asynchronous Alternatives
- Cascading Style Sheets (CSS), bs4 CSS Selectors
- certificates, security, Transport Layer Security (TLS, AKA SSL)
- CFFI, The Python Standard Library and Extension Modules, Extending and Embedding Classic Python
- ChainMap, ChainMap (v3 Only)
- character sets, Character Sets
- class
- Abstract Base Class, Abstract Base Classes
- attribute, The Class Body, Attribute Reference Basics
- base class, How Python v2 Determines a Class’s Metaclass
- body, The Class Body-Class documentation strings
- bound and unbound methods, Bound and Unbound Methods-Bound method details
- built-in object type, The Built-in object Type
- characteristics of Python, Python Classes
- class methods, Class methods
- class statement, The class Statement
- class-level methods, Class-Level Methods-Class methods
- concrete, Abstract Base Classes
- creating, Data Types
- definition of, Classes and Instances
- descriptors, Descriptors
- identifiers, Identifiers
- inheritance, Inheritance-“Deleting” class attributes
- inheritance from built-in types, Inheritance from Built-in Types
- instance, Instances-__new__
- instances of, Python Classes
- metaclass, Metaclasses
- new-style vs. old-style, Object-Oriented Python, Avoid “Old-Style” Classes
- per-instance methods, Per-Instance Methods
- properties, Properties-Properties and inheritance
- __getattribute__, __getattribute__
- __slots__, __slots__
- CLDR (Common Locale Data Repository), More Internationalization Resources
- (see also locale conventions)
- client-server networking, Client-Server Computing
- client-side network protocol modules (see also modules; standard library)
- closure, Nested functions and nested scopes
- CLR (Common Language Runtime), IronPython
- cmd module
- cmp named argument, Never Sort Using cmp
- cmp_to_key function, The functools Module
- code hoisting, Optimizing loops
- code objects, Compile and Code Objects, The Code Object Type
- codec, Character Sets, Unicode, The Response class
- coding directive, Character Sets
- coercion, Numeric Conversions, Accessing Arguments
- coexistence (see v2/v3 migration and coexistence)
- collections module, ABCs in the collections module, The collections Module-namedtuple
- comma separated values (see CSV)
- command-line
- command-line syntax, Command-Line Syntax and Options
- commas (,)
- comment, Lines and Indentation
- community (Python), Python Development and Versions-Mailing lists and newsgroups
- comparison chaining, Comparison Chaining
- comparison methods, General-Purpose Special Methods
- comparisons, Comparisons
- compatibility, v2/v3 Support with a Single Source Tree
- compile function, Compile and Code Objects, What C compiler do you need?
- compiled bytecode, Running Python Programs
- compilers
- complex data type, Built-in Types
- complex numbers, Complex numbers, The math and cmath Modules
- compound statements, Compound statements
- compressed files
- concatenation, Concatenation and repetition, Building up a string from pieces
- concurrency mechanisms, Client-Server Computing
- concurrent.futures module
- conda, Anaconda and Miniconda, Distributing Extensions and Programs
- Condition objects, Condition objects
- conditional statements, Control Flow Statements
- connection-oriented protocols, Networking Principles, Client-Server Computing
- connectionless (datagram) protocols, Networking Principles, Connectionless client and server structures
- console I/O
- contact information, How to Contact Us
- container
- context manager, The with Statement and Context Managers, The concurrent.futures Module, async with
- continue statements, The continue Statement
- continuous integration, Preparing for Python 3
- control flow statements
- break statements, The break Statement
- continue statements, The continue Statement
- control flow statements, The else Clause on Loop Statements
- dict comprehensions, Dict comprehensions
- for statements, The for Statement
- if statements, The if Statement
- iterators, Iterators
- list comprehensions, List comprehensions-List comprehensions
- overview of, Control Flow Statements
- pass statements, The pass Statement
- raise statements, The try and raise Statements
- range and xrange, range and xrange
- set comprehensions, Set comprehensions
- try statements, The try and raise Statements
- while statements, The while Statement
- with statements, The with Statement
- conversion (see v2/v3 migration and coexistence)
- cookie, Some Popular Lightweight Frameworks
- coordinated universal time (UTC) (see UTC)
- copy
- copy_reg module, Pickling customization with the copy_reg module
- core built-ins (see also data types; standard library)
- avoiding type checking, Built-in Types
- bool, Built-in Types
- bytearray, Built-in Types
- bytes, Built-in Types
- complex, Built-in Types
- dict, Built-in Types
- float, Built-in Types
- frozenset, Built-in Types
- functions, Built-in Functions-Built-in Functions
- int, Built-in Types
- list, Built-in Types
- meaning of "built-in", Core Built-ins and Standard Library Modules
- memoryview, Built-in Types
- object, Built-in Types
- set, Built-in Types
- slice, Built-in Types
- str, Built-in Types
- summary of big-O times, Summary of big-O times for operations on Python built-in types
- super, Built-in Types
- tuple, Built-in Types
- type, Built-in Types
- unicode, Built-in Types
- coroutine-based architectures, Asynchronous Alternatives
- Counter, Counter
- counter-party sockets, The Berkeley Socket Interface
- counting semaphores, Semaphore objects
- CPU bound, Threads and Processes
- CPython, CPython
- cryptographic-quality random numbers, Physically Random and Cryptographically Strong Random Numbers
- CSS (Cascading Style Sheets), Search method arguments: attrs
- CSV (Comma Separated Values), Creating a NumPy Array, Building an ElementTree from Scratch
- ctypes module, ctypes
- curly braces ({}), Command-Line Syntax and Options, Lines and Indentation, Sets-Dictionaries
- curses package, The curses package-The curses package
- customization
- Cython
D
- daemons, Thread Objects
- data analysis, Array Processing
- data interchange, formatting for, Serialization
- data persistence
- data science, Distributing Extensions and Programs
- data types (see also core built-ins)
- Boolean values, Boolean Values
- callable, Callables
- dictionary, Dictionaries
- list, Lists
- None, None
- number, Numbers-New in 3.6: Underscores in numeric literals
- overview of, Data Types
- sequences, Sequences-Lists
- set, Sets
- string, Strings-Strings
- tuple, Tuples
- database (see also data persistence)
- datagram (connectionless) protocols, Networking Principles, Connectionless client and server structures
- datagrams, Networking Basics
- datetime module
- dateutil package
- DBAPI (Python Database API 2.0)
- connect function, The connect Function
- connection objects, Connection Objects
- cursor objects, Cursor Objects
- DBAPI-compliant modules, DBAPI-Compliant Modules
- exception classes, Exception Classes
- factory functions, Factory Functions
- parameter style, Parameter Style
- SQLite, SQLite-A sqlite3 example
- third-party modules, Persistence and Databases, The Python Database API (DBAPI) 2.0
- thread safety, Thread Safety
- type description attributes, Type Description Attributes
- DBM modules, DBM Modules-Examples of DBM-Like File Use
- debugging
- asyncio event loop mode, Loop state and debugging mode
- challenges of, Before You Debug
- definition of, Testing, Debugging, and Optimizing
- initial steps, Before You Debug
- inspect module, The inspect Module-An example of using inspect
- interactive, Debugging
- most effective approach, Debugging
- pdb module, The pdb Module
- printing/logging results, Debugging
- traceback module, The traceback Module
- decimal
- decimal floating-point numbers, Numbers
- decimal module, The decimal Module
- decorate-sort-undecorate (DSU) idiom, The Decorate-Sort-Undecorate Idiom
- decorator, Properties, Decorators
- def statement, The def Statement
- defaultdict, defaultdict
- deferreds (see futures)
- defusedxml module, ElementTree
- del statement, Variables, del Statements
- delegation, Delegating to superclass methods
- deletion, del Statements
- (see also garbage collection)
- delimiters, Tokens, Delimiters
- dependency
- deque, deque
- descriptor, Python Classes, Descriptors
- dict data type
- built-in type, Dictionaries
- defaultdict, Dictionary Methods
- denoting, Dictionaries
- dict comprehensions, Dictionaries, Dict comprehensions
- dict.fromkeys, Dictionaries
- dictionary creation, Dictionaries
- dictionary membership, Dictionary Membership
- dictionary methods, Dictionary Methods-Dictionary Methods
- empty, Dictionaries
- indexing dictionaries, Indexing a Dictionary
- items, Dictionaries
- keys, Dictionaries
- optimizing operations, Dictionary operations
- overview of, Dictionary Operations, Built-in Types
- values, Dictionaries
- dictionary (see dict data type)
- dircmp instance attributes, dircmp instance attributes
- directories (see also file and text operations)
- distributed computing, Threads and Processes, Networking Basics (see also networking)
- distribution
- built, Wheels make the Python world go round
- definition of, The Distribution and Its Root
- dependencies, Dependencies and requirements
- manylinux, Creating wheels
- metadata, Metadata about the distribution
- non-pure, The Distribution and Its Root
- pure, The Distribution and Its Root
- requirements, Dependencies and requirements
- setuptools, setuptools-The setup.cfg File
- source, Create the Distribution
- step by step guide to, Distributing Your Package
- tools for, Distributing Extensions and Programs
- universal, The Distribution and Its Root
- wheel
- distribution utilities (distutils)
- division, Division
- divmod function, Division
- Django, A Few Popular Full-Stack Frameworks
- DNS (Domain Name Service), Networking Principles
- docstring
- doctest module, The doctest Module-The doctest Module
- documentation, Documentation, The doctest Module
- Domain Name Service (DNS) (see DNS)
- dot operator, Attributes of instance objects
- dot reference, Object attributes and items
- double-ended queue, deque
- double-underscore names, Python Classes
- DST (daylight saving time), The time Module
- duck typing (see type checking)
- dunder names, Python Classes
- dynamic arrays, List operations
- dynamic execution
E
- EAFP (Easier to Ask Forgiveness than Permission), LBYL Versus EAFP
- Easter dates, The dateutil Module
- egg (see distribution, built)
- ElementTree package
- additional classes, Functions in the ElementTree Module
- attributes, The Element Class
- benefits of, Structured Text: XML
- building trees from scratch, Building an ElementTree from Scratch
- editing trees, Editing an ElementTree
- Element class
- ElementTree class, The ElementTree Class
- functions, Functions in the ElementTree Module
- implementations, ElementTree
- importing, ElementTree
- overview of, ElementTree
- parsing untrusted sources, Structured Text: XML
- parsing with ElementTree.parse, Parsing XML with ElementTree.parse
- selecting elements from trees, Selecting Elements from an ElementTree
- tutorials and documentation, Structured Text: XML
- elif clauses, The if Statement
- else clauses, The if Statement, The while Statement, The else Clause on Loop Statements, The try Statement
- (see also exception; for statements; if statements; while statements)
- email (see also MIME (Multipurpose Internet Mail Extensions))
- email package
- email.encoders module, The email.encoders Module
- email.Generator module, The email.Generator Module
- email.message module, The email.message Module-The email.message Module
- email.utils module, The email.utils Module
- example uses of, Example Uses of the email Package
- factory functions in, Functions in the email Package
- message creation, Creating Messages
- vs. older modules, MIME and Email Format Handling
- rfc822.Message and mimetools.Message, rfc822 and mimetools Modules (v2)
- tasks handled by, MIME and Email Format Handling
- embedding
- encoding
- Base 64, Encoding Binary Data as ASCII Text
- base64 module, The base64 Module
- encoding declaration, Character Sets
- HTML, BeautifulSoup, Unicode, and encoding
- Python support for, Encoding Binary Data as ASCII Text
- QP, The quopri Module
- quopri module, The quopri Module
- reading files in different, Character Sets
- UU, Encoding Binary Data as ASCII Text, The uu Module
- end-to-end testing, Unit Testing and System Testing
- endpoints, URL Access
- entry_points, What are entry_points?
- environment
- environment variables, Environment Variables
- ephemeral ports, The Berkeley Socket Interface
- epoch, Time Operations
- equality (==) comparisons, Comparisons, The math and cmath Modules
- errata, How to Contact Us
- errno module, The errno Module
- error (see also exception)
- error code, The errno Module
- escape sequences, Strings
- eval statements, Built-in Functions
- event loops, Coroutine-Based Async Architectures, asyncio’s Event Loop
- Event objects, Event objects
- event schedulers, The sched Module
- event-driven architectures, Asynchronous Alternatives
- except clauses, The try Statement, except Clauses
- exception
- assert statements, The assert Statement
- bare except, try/except
- clean-up handler, try/finally
- custom classes, Custom Exception Classes-Custom Exceptions and Multiple Inheritance
- error-checking strategies, Error-Checking Strategies-The logging package
- exception objects, Exception Objects-Exceptions “wrapping” other exceptions or tracebacks
- generators and, Generators and Exceptions
- handle, Exceptions
- handler, try/except
- hierarchy of standard, The Hierarchy of Standard Exceptions
- nonexistent references, Accessing nonexistent references
- OSError and subclasses (v3), OSError and subclasses (v3 only)
- other used in standard library, Other Exceptions Used in the Standard Library
- propagation, Exception Propagation
- purpose of, Exceptions
- raise, Exceptions, The raise Statement
- standard classes, Standard Exception Classes
- try statements, The try Statement-The try/except/finally Statement
- with statements and context managers, The with Statement and Context Managers
- wrapping and tracebacks, Exceptions “wrapping” other exceptions or tracebacks
- exec statements
- executable, What are entry_points?
- execution, controlling
- executors, Executor
- exponentiation, Exponentiation
- expression statements, Expressions
- expressions and operators
- extension modules
- extensions (see extension modules)
F
- f-strings (see formatted string literals)
- F2PY, Extending Python Without Python’s C API
- factory function, The factory-function idiom
- Falcon web framework
- false (see False value (bool))
- False value (bool), Boolean Values, The if Statement
- file and text operations (see also files)
- auxiliary modules for file I/O, Auxiliary Modules for File I/O-The struct Module
- compressed files, Compressed Files-The zlib Module
- filesystem operations, Filesystem Operations-File Descriptor Operations
- in memory "files", In-Memory “Files”: io.StringIO and io.BytesIO
- interactive command sessions, Interactive Command Sessions-A Cmd Example
- internationalization, Internationalization-More Internationalization Resources
- io module, The io Module-The tempfile Module
- optimizing, Optimizing I/O
- os module, The os Module, Running Other Programs with the os Module
- overview of, Other Chapters That Also Deal with Files-Organization of This Chapter
- richer-text I/O, Richer-Text I/O-The msvcrt Module
- text input and output, Text Input and Output-The getpass Module
- file-like objects, Organization of This Chapter, File-Like Objects and Polymorphism
- filecmp module, The filecmp Module
- fileinput module, The fileinput Module-The fileinput Module
- files (see also file and text operations)
- attributes and methods, Attributes and Methods of “file” Objects
- compressed, Organization of This Chapter, Compressed Files
- definition of, File and Text Operations
- descriptors, Organization of This Chapter, File Descriptor Operations-File Descriptor Operations
- file paths, Organization of This Chapter
- in-memory, In-Memory “Files”: io.StringIO and io.BytesIO
- modes, Permissions
- opening, Creating a “file” Object with io.open
- paths
- permissions, Permissions
- reading, Attributes and Methods of “file” Objects
- symbolic link, File and Directory Functions of the os Module
- temporary, The io Module, The tempfile Module
- variety of types, Organization of This Chapter
- writing, Attributes and Methods of “file” Objects
- filesystem (see also file and text operations; os module)
- filters, Search method arguments: filters
- finally clause, The try Statement
- fixers, v2 source with conversion to v3
- Flask web framework
- float data type, Built-in Types, The decimal Module
- floating-point numbers, Numbers, Boolean Values, The math and cmath Modules
- fnmatch module, The fnmatch Module
- for statements, The for Statement
- formal parameters, Parameters
- format
- alignment, Alignment, with optional (preceding) fill
- columns, Nested format specifications
- comma separation, Comma separation
- field width, Field width
- fill, Alignment, with optional (preceding) fill
- nested, Nested format specifications
- precision, Precision specification
- replacement fields, String Formatting
- sign, Optional sign indication
- specifier, Value Formatting, Legacy String Formatting with %
- with %, Legacy String Formatting with %
- formatted string literals, Strings
- Fortran, Extending Python Without Python’s C API
- forward slash (/), Command-Line Syntax and Options-Command-Line Syntax and Options
- fractions, Numbers
- fractions module, The fractions Module
- frame objects, The frame Type
- framed formats, The json Module
- free variables, Nested functions and nested scopes
- from M import *, from ... import *
- from statements
- from __future__ import, Version Conventions, Python Development and Versions, Preparing for Python 3
- frozenset data type, Built-in Types
- FTP, HTTP and URL Clients
- function
- **kwds, Parameters
- *args, Parameters
- arguments, Calling Functions
- attribute, Attributes of Function Objects
- built-in, Callables
- calling, Calling Functions
- closure, Nested functions and nested scopes
- core built-ins, Built-in Functions-Built-in Functions
- def statement, The def Statement
- definition of, Functions
- factory functions, The factory-function idiom
- formal parameters, Parameters
- function calls, Functions
- function signatures, Function signatures
- generator, Generators
- higher-order, Decorators
- identifiers, Identifiers
- keyword argument (see named argument)
- keyword-only parameters, The Python Language, “Keyword-only” Parameters (v3 Only)
- lambda expressions, lambda Expressions
- method, Callables
- named argument, Kinds of arguments
- namespaces, Namespaces
- nested, Nested functions and nested scopes
- parameter
- positional argument, Kinds of arguments
- recursion, Recursion
- return, The return Statement
- signature, Function signatures, The PyMethodDef struct
- type hints, Function Annotations and Type Hints (v3 Only)
- user-defined, Callables
- function objects, Properties and inheritance
- functional programming, The functools Module
- functional testing, Unit Testing and System Testing
- functools module, The functools Module
- futures, Coroutine-Based Async Architectures, Futures
- futurize package, Preparing for Python 3
- fuzzing, Unit tests dealing with large amounts of data
G
- garbage collection
- gc module, The gc Module
- GCD (Greatest Common Divisor), A Cython Example: Greatest Common Divisor
- generator
- generator functions, Generators, The with Statement and Context Managers-Generators and Exceptions
- generator object, Generators, Generators and Exceptions
- getpass module, The getpass Module
- getter, Properties
- gettext module, The gettext Module-Essential gettext functions
- getting help, Python Resources-Mailing lists and newsgroups
- getting started
- GIL (Global Interpreter Lock), Threads and Processes
- glob module, The glob Module
- Global Interpreter Lock (GIL), Threads and Processes
- global variables, Variables, The global statement
- gmpy2 module, The gmpy2 Module
- GMT (Greenwich Mean Time), The time Module
- GNU Readline Library, The readline Module
- goose typing, Built-in Types
- GPL (GNU Public License), Licensing and Price Issues
- greedy matching, Common Regular Expression Idioms
- Grumpy, Grumpy: A Python-to-Go transpiler
- Guido (see van Rossum, Guido)
- gzip module, The gzip Module
H
- hash sign (#), Lines and Indentation
- hash table (see dict data type)
- hashable, General-Purpose Special Methods
- hashable items, Sets
- hashable keys, Dictionaries
- hashing methods, General-Purpose Special Methods
- heap, Reference Counting
- heapq module, The heapq Module-The Decorate-Sort-Undecorate Idiom
- hexadecimal numbers, Numeric Constants
- higher-order functions, Decorators
- hook, Methods of Cmd Instances, Debugging, The pdb Module, Flask, Flask response objects
- Hopper, Grace, LBYL Versus EAFP
- host-to-host (transport) layer, Networking Basics, The Berkeley Socket Interface
- hot spots, Optimization
- HTML (HyperText Markup Language)
- BeautifulSoup package, The BeautifulSoup Third-Party Package-Building HTML with bs4
- generating, Structured Text: HTML, Generating HTML
- html.entities/htmlentitydefs modules, The html.entities (v2: htmlentitydefs) Module
- jinja2 package, The jinja2 Package-Building HTML with jinja2
- overview of, Structured Text: HTML
- parser, Which parser BeautifulSoup uses
- parsing, Structured Text: HTML, The BeautifulSoup Third-Party Package
- tags, Structured Text: HTML, Which parser BeautifulSoup uses
- templating, Structured Text: HTML, Templating
- html.entities/htmlentitydefs modules, The html.entities (v2: htmlentitydefs) Module
- HTTP, Client-Side Network Protocol Modules, HTTP and URL Clients
- GET, Falcon resources
- header, request’s optional named parameters, The Response class, Falcon response objects, Bottle response objects
- PATCH, request’s optional named parameters
- POST, request’s optional named parameters
- PUT, request’s optional named parameters
- request, The Third-Party requests Package
- response, The Third-Party requests Package
- routing, Falcon, webapp2-webapp2 routes
- session, The Third-Party requests Package, webapp2 extras
- status code, The Response class
- HyperText Markup Language (see HTML)
- hyphens (-), Command-Line Syntax and Options
I
- I/O (input/output) (see file and text operations)
- I/O bound, Threads and Processes
- i18n, Internationalization
- ICU package, More Internationalization Resources
- (see also internationalization)
- identifier
- IDEs (Integrated Development Environments)
- IDLE (Integrated DeveLopment Environment), IDLE
- if statements, The if Statement
- if __name__ == '__main__', The Main Program
- if/else, The ternary operator
- imaginary literals, Complex numbers
- IMAP4, Email Protocols
- imaplib module, Email Protocols
- immutable
- implementations
- Anaconda, Anaconda and Miniconda
- choosing between available, Choosing Between CPython, Jython, IronPython, and PyPy
- conda, Anaconda and Miniconda
- CPython, CPython
- current and future, Python Implementations
- Grumpy, Grumpy: A Python-to-Go transpiler
- IPython, IPython
- IronPython, IronPython
- Jython, Jython
- licensing and pricing, Licensing and Price Issues
- MicroPython, MicroPython: Is your child already a programmer?
- Miniconda, Anaconda and Miniconda
- Nuitka, Nuitka: Convert your Python to C++
- Pyjion, Pyjion
- PyPy, PyPy
- Transcrypt, Transcrypt: Convert your Python to JavaScript
- import (see also module loading)
- import this (see Zen of Python)
- in-place list operations, In-place operations on a list
- indentation, Lines and Indentation
- indexing
- inequality (!=) comparisons, Comparisons
- inheritance
- initialization/finalization methods, General-Purpose Special Methods
- input/output (I/O) (see file and text operations)
- inspect module
- installer, Installing Python from Binaries
- installing
- instances (see also class)
- int data type, Built-in Types
- integer literals, in v2 vs. v3, Numeric Constants
- integers
- integration testing, Unit Testing and System Testing
- inter-process communication (IPC), Threads and Processes
- inter-version compatibility, v2/v3 Support with a Single Source Tree
- (see also v2/v3 migration and coexistence)
- interactive sessions, Interactive Sessions
- internal types
- internationalization
- internet (network) layer, Networking Basics
- Internet of Things (IoT), MicroPython: Is your child already a programmer?
- interpreter
- command-line syntax , Command-Line Syntax and Options
- CPython, CPython
- development environments, Python Development Environments-Tools for Checking Python Programs
- interactive sessions, Interactive Sessions
- IronPython, The IronPython Interpreter
- jython, The jython Interpreter
- purpose of, The Python Interpreter
- PyPy, The PyPy Interpreter
- Python, Running Python Programs
- python program, The python Program-Interactive Sessions
- running python programs, Running Python Programs
- io module
- attributes and methods of file objects, Attributes and Methods of “file” Objects
- binary and text modes, Binary and text modes
- buffering requests, Buffering
- creating file objects with io.open, Creating a “file” Object with io.open
- file-like objects and polymorphism, File-Like Objects and Polymorphism
- in-memory files, In-Memory “Files”: io.StringIO and io.BytesIO
- io.BytesIO, In-Memory “Files”: io.StringIO and io.BytesIO
- io.StringIO, In-Memory “Files”: io.StringIO and io.BytesIO
- iteration on file objects, Iteration on “File” Objects
- opening files, Creating a “file” Object with io.open
- opening files, modes of, mode
- overview of, The io Module
- sequential and nonsequential ("random") access, Sequential and nonsequential (“random”) access
- tempfile module, The tempfile Module
- IPv4, The Berkeley Socket Interface, Socket Addresses
- IPv6, The Berkeley Socket Interface, Socket Addresses
- IPython (see Jupyter)
- IronPython, IronPython, Installing IronPython, The IronPython Interpreter
- isinstance, Data Types
- item, Data Types-Object attributes and items
- iterables
- iterator, Iterators, Generators
- itertools module, The itertools Module-The itertools Module
K
- key/value pairs, Dictionaries, Dictionary Methods
- key= argument, Searching and sorting, Never Sort Using cmp
- keyed access, DBM Modules
- keys, Dictionaries
- keyword arguments, Kinds of arguments
- keyword parameters, Parameters
- keyword-only parameters, “Keyword-only” Parameters (v3 Only)
- keywords, Tokens, Keywords
L
- lambda expressions, lambda Expressions
- language basics
- benefits of Python, The Python Language-The Python Language
- control flow statements, Control Flow Statements-The with Statement
- data types, Data Types-Boolean Values
- dictionary operations, Dictionary Operations-Dictionary Methods
- expressions and operators, Expressions and Operators-The ternary operator
- functions, Functions-Recursion
- lexical structure, Lexical Structure-Compound statements
- numeric operations, Numeric Operations
- sequence operations, Sequence Operations-Sorting a list
- set operations, Set Operations
- topics covered, The Python Language
- variables and other references, Variables and Other References-del Statements
- lazy evaluation, Generators, The itertools Module
- LBYL (Look Before You Leap), LBYL Versus EAFP
- leap second, The time Class
- lefthand side (LHS), Plain assignment
- len function, Sequences in General, Set Operations, Dictionary Operations
- Lesser GPL (LGPL), Licensing and Price Issues
- lexical structure
- licensing
- line
- linecache module, The linecache Module
- link (subnetwork) layer, Networking Basics
- list data type, Built-in Types
- creating, Lists
- definition of, Lists
- empty, Lists
- in-place operations on, In-place operations on a list
- list comprehensions, Lists, List comprehensions-List comprehensions
- list methods, List methods
- modifying, Modifying a list
- mutability of, Lists
- optimizing list operations, List operations
- sorting, Sorting a list
- literals
- literate programming style, IPython
- load balancer, WSGI Servers
- load testing (benchmarking), Benchmarking
- local namespace, Namespaces
- local scope, Namespaces
- local variables, Variables, Namespaces
- locale
- locale module, The locale Module-The locale Module
- localization, The gettext Module
- (see also internationalization)
- Lock objects, Lock and RLock objects
- logging, Handling Errors in Large Programs
- logical "and" (see comparison chaining)
- long integers, Numeric Constants
- Look Before You Leap (LBYL), LBYL Versus EAFP
- loop conditions, The while Statement, The else Clause on Loop Statements
M
- magics, IPython
- main program (see python program)
- MANIFEST.in file, The MANIFEST.in File
- mappings, Dictionaries, Mappings
- (see also dict data type)
- markup, Structured Text: HTML
- marshal, Pickling customization with the copy_reg module
- marshaling, Serialization
- math.isclose(), The math and cmath Modules
- math/cmath modules
- Matplotlib, SciPy
- matrix dot product, Matrix Operations in NumPy
- matrix multiplication (@) operator, Matrix Operations in NumPy
- max function, Sequences in General
- membership testing, Membership testing, Set Membership, Dictionary Membership
- memory leaks, The gc Module
- memory-mapped files, Threads and Processes, The mmap Module
- memoryview data type, Built-in Types
- Mersenne Twister algorithm, Random and Pseudorandom Numbers
- metaclasses
- method resolution order (MRO), Getting an attribute from a class, Inheritance
- methods
- bound, Bound and Unbound Methods
- callable attributes as, Object attributes and items
- class, Class methods
- class attributes as, Python Classes
- definition of, Callables
- mutating, List methods
- non-mutating, List methods
- per-instance, Per-Instance Methods
- special, Object-Oriented Python, Special Methods-Special Methods for Numeric Objects
- static, Static methods
- unbound, Bound and Unbound Methods
- micro-services, Serving HTTP
- micro:bit device, MicroPython: Is your child already a programmer?
- microcontrollers, MicroPython: Is your child already a programmer?
- MicroPython, MicroPython: Is your child already a programmer?
- middleware, WSGI Servers-When you use lightweight frameworks
- migration (see v2/v3 migration and coexistence)
- MIME (Multipurpose Internet Mail Extensions)
- mimetools module, rfc822 and mimetools Modules (v2)
- min function, Sequences in General
- min heap algorithms, The heapq Module
- Miniconda (see Anaconda)
- mmap module, The mmap Module
- mocks, Unit Testing and System Testing, Preparing for Python 3
- mode argument, Permissions
- modernize package, Preparing for Python 3
- module loading
- built-in modules, Built-in Modules
- circular imports, Circular Imports
- custom importers, Custom Importers
- filesystem searches for modules, Searching the Filesystem for a Module
- import hooks, Import hooks
- main program, The Main Program
- overview of, Module Loading
- rebinding __import__, Rebinding __import__
- reloading modules, Reloading Modules
- sys.modules entries, sys.modules Entries
- module objects
- modules (see also client-side network protocol modules; extension modules; standard library)
- definition of, Running Python Programs, Module Objects
- distribution utilities and setuptools, Distribution Utilities (distutils) and setuptools-Best Practices with virtualenvs, setuptools-The setup.cfg File
- extension modules, Modules
- identifiers, Identifiers
- loading and running, Command-Line Syntax and Options
- module loading, Module Loading-Import hooks
- module objects, Module Objects-from versus import
- modulo (see remainder)
- overview of, Modules
- packages, Packages
- money-related computations, The decimal Module
- Mono, IronPython
- MRO (method resolution order), Getting an attribute from a class, Inheritance
- msvcrt module, The msvcrt Module
- multiple inheritance, Custom Exceptions and Multiple Inheritance
- multiple-precision arithmetic, The gmpy2 Module
- multiprocessing module
- Array class, The Array class
- AsyncResult class, The AsyncResult class
- Manager class, The Manager class
- overview of, The multiprocessing Module
- Pool class, Multiprocessing Pool-The Pool class
- Process class, The Process class
- Queue class, Differences in queues
- shared memory, Sharing State: Classes Value, Array, and Manager
- synchronization primitives, Differences in synchronization primitives
- vs. threading, Differences Between Multiprocessing and Threading
- Value class, The Value class
- multithreading (see also threads and processes)
- mutable, Data Types
- mutable lists, Lists
- mutable mappings, Dictionaries
- mutable sets, Sets
- mutating methods, List methods, Set Methods, Dictionary Methods
- mutator (see setter)
- mutual reference loops, Garbage Collection
- MySQL, DBAPI-Compliant Modules
N
- name=value syntax, Reference Conventions
- named arguments, Dictionaries, Kinds of arguments
- named parameters, Parameters
- namedtuple, namedtuple
- namespace, Variables, Namespaces
- nested functions, Nested functions and nested scopes
- network (internet) layer, Networking Basics
- network encodings
- network endpoints, Networking Principles
- Network News (NNTP), MIME and Email Format Handling
- networking
- client-server, Client-Server Computing
- clients, Networking Basics
- connection-oriented, Networking Basics
- connectionless (datagram)
- host-to-host (transport) layer, Networking Basics
- IP, The Berkeley Socket Interface
- link (subnetwork) layer, Networking Basics
- network (internet) layer, Networking Basics
- networking principles, Networking Principles
- overview of, Networking Basics
- peer-to-peer, Client-Server Computing
- process (application) layer, Networking Basics
- protocol layers, Networking Basics
- protocols, Networking Basics
- security, Transport Layer Security (TLS, AKA SSL)
- servers, Networking Basics
- sockets, The Berkeley Socket Interface-A Connection-Oriented Socket Server
- transport layer security (TLS), Transport Layer Security (TLS, AKA SSL)
- new features in v3.6
- contextlib AbstractContextManager class, The with Statement and Context Managers
- customizing class creation, How Python v2 Determines a Class’s Metaclass
- dictionaries reimplemented, Dictionary Operations
- formatted string literals, Strings, New in 3.6: Formatted String Literals
- kwds mapping, Parameters
- ModuleNotFoundError, Standard Exception Classes
- OrderedDict unnecessary, How Python v3 Determines a Class’s Metaclass
- strftime
- type annotations, New in 3.6: Type annotations
- underscores in numeric literals, New in 3.6: Underscores in numeric literals
- venv vs. pyvenv, What Is a Virtual Environment?
- new-style class, Avoid “Old-Style” Classes
- next (see __next__)
- non-blocking, Threads and Processes, Asynchronous Alternatives
- non-greedy matching, Common Regular Expression Idioms
- None data type, None
- nonexistent references, Accessing nonexistent references
- nonmutating methods, List methods, Set Methods, Dictionary Methods
- Nuitka, Nuitka: Convert your Python to C++
- number data type
- built-in data types, Numbers
- complex, Complex numbers
- decimal, Numbers
- floating-point, Floating-point numbers
- fractions, The fractions Module
- imaginary, Complex numbers
- integers, Integer numbers
- numbers module, The numbers module
- rational numbers, The fractions Module
- special methods for numeric objects, Special Methods for Numeric Objects-Special Methods for Numeric Objects
- numeric constants, in v2 vs. v3, Numeric Constants
- numeric operations (see also expressions and operators)
- numeric processing
- array module, The array Module-The array Module
- array processing, Array Processing
- decimal module, The decimal Module
- fractions module, The fractions Module
- gmpy2 module, The gmpy2 Module
- math and cmath modules, The math and cmath Modules-The math and cmath Modules
- NumPy, NumPy-Matrix Operations in NumPy
- operator module, The operator Module-The operator Module
- overview of, Numeric Processing
- random and pseudorandom numbers, Random and Pseudorandom Numbers
- SciPy, SciPy
- NumPy (Numeric Python)
- vs. array module, NumPy
- and CPython, Choosing Between CPython, Jython, IronPython, and PyPy
- creating NumPy arrays, Creating a NumPy Array
- matrix operations in, Matrix Operations in NumPy
- ndarray class, NumPy
- shape, indexing, and slicing, Shape, Indexing, and Slicing
O
- object data type, Built-in Types
- object-oriented programming (OOP)
- objects
- octals, Numeric Constants
- octets, Networking Principles, Email, MIME, and Other Network Encodings
- Open DataBase Connectivity (ODBC), DBAPI-Compliant Modules
- operator module
- operators (see also expressions and operators)
- optimization
- optimize flag, The assert Statement
- ordered, Sequences, Tuples, Lists
- OrderedDict, OrderedDict
- os module
- dircmp instance attributes, dircmp instance attributes
- errno module, The errno Module
- file and directory functions, File and Directory Functions of the os Module-File and Directory Functions of the os Module
- filecmp module, The filecmp Module
- getpass module, The getpass Module
- glob module, The glob Module
- os.path module, The os.path Module-The os.path Module
- os.stat module, The stat Module
- os.sytem function, Running Other Programs with the os Module
- os.urandom, Physically Random and Cryptographically Strong Random Numbers
- OSError exceptions, OSError Exceptions
- overview of, The os Module
- path-string attributes, Path-String Attributes of the os Module
- permissions, Permissions
- running other programs with, Running Other Programs with the os Module
- shutil module, The shutil Module-The shutil Module
- outer functions, Nested functions and nested scopes
- OverflowError, Standard Exception Classes
P
- packages
- absolute vs. relative imports, Absolute Versus Relative Imports
- definition of, Packages
- importing, Packages
- namespace packages (v3), Namespace Packages (v3 Only)
- overview of, Packages
- sharing objects in, Packages
- special attributes of package objects, Special Attributes of Package Objects
- step-by-step guide to distributing, Distributing Your Package
- subpackages in, Packages
- __init__.py, Special Attributes of Package Objects
- packaging, Distributing Extensions and Programs
- packet, Networking Basics
- packet-echo services, A Connectionless Socket Client
- pair, Tuples
- pandas, Array Processing
- parallelism, Client-Server Computing
- parameter
- paramiko module, Other Network Protocols
- parent node, parent, parents, Building and adding new nodes, Functions in the ElementTree Module
- pass statements, The pass Statement
- password, The getpass Module, Handling authentication
- PATH, Installing Python from Binaries, The python Program
- paths
- pdb module
- PEPs (Python Enhancement Proposals)
- per-instance methods, Per-Instance Methods
- per-thread data, Thread Local Storage
- percent character (%) (see %)
- permission bits, Permissions
- persistence, Persistence and Databases-A sqlite3 example
- pickle/cPickle modules
- pip freeze, Managing Dependency Requirements
- pipes, Threads and Processes, Subprocess files: stdin, stdout, stderr, bufsize, universal_newlines, close_fds, Connections and server
- plug-in, Bottle templating
- polling, Threaded Program Architecture
- polymorphism, Cooperative superclass method calling, Built-in Types, File-Like Objects and Polymorphism
- pools, Multiprocessing Pool
- pop method
- POP3 (Post Office Protocol version 3), Email Protocols
- poplib module, The poplib Module
- ports
- positional arguments, Kinds of arguments
- positional parameters, Parameters
- PostgreSQL, DBAPI-Compliant Modules
- pprint module, The pprint Module
- pricing and licensing, Licensing and Price Issues
- print
- priority queues, The heapq Module
- process (application) layer, Networking Basics
- processes (see also threads and processes)
- profile module, The profile module
- profiling
- promises, Coroutine-Based Async Architectures
- prompt string (...), Interactive Sessions
- prompt string (>>>), Interactive Sessions
- property, Properties-Properties and inheritance
- protocol layers, Networking Basics
- protocols (see also client-side network protocol modules)
- prototyping, Developing a Fast-Enough Python Application
- pseudorandom, Random and Pseudorandom Numbers, Unit tests dealing with large amounts of data
- PSF (Python Software Foundation), Python Development and Versions, Python Software Foundation
- pstats module, The pstats module
- Pyjion, Pyjion
- PyObject, Reference Counting
- PyPI (Python Package Index), Extension modules and Python sources, Register and upload to PyPI
- PyPy, PyPy, Installing PyPy, The PyPy Interpreter
- Pyramid, A Few Popular Full-Stack Frameworks
- pyrex (see cython)
- Pyston, Python Implementations
- Python interpreter (see interpreter)
- python program
- Python Software Foundation License, Licensing and Price Issues
- Python-Future library, python-future
- python-modernize library (see modernize)
- pytz mdoule, The pytz Module
- pytz module, The pytz Module
R
- raise statements, The try and raise Statements, The raise Statement
- random module, Random and Pseudorandom Numbers
- range function, range and xrange
- Raspberry Pi, MicroPython: Is your child already a programmer?
- rational number, The fractions Module
- raw sockets, The Berkeley Socket Interface
- raw strings, Strings
- raw_input, Standard Input
- RDBMS (relational DB management system), Persistence and Databases, DBAPI-Compliant Modules
- re module, Regular Expressions and the re Module, Functions of the re Module
- (see also regular expressions)
- readline module, The readline Module
- recursion, Recursion
- refactor, The unittest Module
- reference
- reference conventions, Reference Conventions
- regular expressions
- alternatives, Alternatives
- anchoring at string start and end, Anchoring at String Start and End
- bytes vs. Unicode strings, re and bytes Versus Unicode Strings
- common idioms, Common Regular Expression Idioms
- escaping strings, Alternatives
- groups in, Groups
- match objects, Match Objects
- match vs. search, Match Versus Search
- optional flags, Optional Flags
- overview of, Regular Expressions and the re Module
- pattern-string syntax, Pattern-String Syntax
- raw string syntax, Strings
- re module, Regular Expressions and the re Module
- re module functions, Functions of the re Module
- regular expression objects, Regular Expression Objects
- sets of characters, Sets of Characters
- uses for, Regular Expressions and the re Module
- release
- remainder, Expressions and Operators, Division
- remote endpoints, The Berkeley Socket Interface
- repetition, Concatenation and repetition
- repository
- reprlib module, The reprlib Module
- requests package
- responder methods, Falcon resources
- restricted execution, Never exec or eval Untrusted Code
- return statements, The return Statement
- rfc822 module, rfc822 and mimetools Modules (v2)
- richer-text I/O
- righthand side (RHS), Plain assignment
- ring buffers, deque
- RLock objects, Lock and RLock objects
- route (see HTTP routing)
- runtime errors, Standard Exception Classes
S
- SBCs (single-board computers), MicroPython: Is your child already a programmer?
- scalar, Matrix Operations in NumPy
- sched module, The sched Module
- SciPy, SciPy
- screen-scraping, Structured Text: HTML
- scripts, Running Python Programs
- sdist (source distribution), Create the Distribution, Creating an sdist
- searching, optimizing, Searching and sorting
- Secure Sockets Layer (SSL), Transport Layer Security (TLS, AKA SSL)
- selectors module
- self, Function definitions in a class body, Bound and Unbound Methods
- semaphores, Semaphore objects
- sentinel, The PyMethodDef struct
- sequence, Strings
- sequence operations
- sequences
- built-in data types, Sequences
- definition of, Sequences, Sequences in General
- iterability of, Iterables
- lists, Sequences, Lists
- special methods for, Sequences
- strings, Sequences-Strings, Strings
- tuples, Sequences, Tuples
- serialization
- server-side programming, Serving HTTP
- (see also WSGI (Web Server Gateway Interface))
- set data type, Built-in Types
- set operations
- setter, Properties
- setup.py, The Distribution and Its Root
- setuptools, Distribution Utilities (distutils) and setuptools, Building and Installing C-Coded Python Extensions, Distributing Extensions and Programs-The setup.cfg File
- shebang (#!) character, Running Python Programs
- shell
- shelve module, The shelve Module-A shelving example
- shutil module, The shutil Module-The shutil Module
- signals, Unix signals
- signature (see function signature)
- significant digits, The decimal Module
- simple statements, Simple statements
- single underscore (_), Interactive Sessions, Identifiers, New in 3.6: Underscores in numeric literals, Module-private variables
- site customization, Site and User Customization
- site-packages, Python Environments, Extending Python with Python’s C API
- site/sitecustomize modules, The site and sitecustomize Modules
- six library, six
- slice data type, Built-in Types
- slicing, Plain assignment, Sequences in General, Container slicing, Special Methods for Numeric Objects
- SLtime12, The time Module
- SMTP (Simple Mail Transport Protocol), Email Protocols
- smtplib module, The smtplib Module
- socket module, The socket Module-A Connectionless Socket Server
- sockets
- software regression bugs, Unit Testing and System Testing
- sort
- sorting, optimizing, Searching and sorting
- source code (see source distribution)
- source distribution, Installation
- source file, The Python Interpreter, Statements, Modules
- spaces vs. tabs, Lines and Indentation
- special methods
- spur module, Other Network Protocols
- SQL (Structured Query Language), Persistence and Databases
- SQLite, Persistence and Databases, SQLite-A sqlite3 example
- square brackets ([]), Reference Conventions, Command-Line Syntax and Options, Lines and Indentation, Literals, Tuples, Modifying a list
- SSDP discovery protocols, Client-Server Computing
- SSH (Secure Shell) protocol, Other Network Protocols
- SSL (Secure Sockets Layer), Transport Layer Security (TLS, AKA SSL)
- ssl module, SSLContext
- standard error, Standard Output and Standard Error
- standard library
- abc module, abc
- argparse module, The argparse Module
- array module, The array Module-The array Module
- asyncio module, The asyncio Module (v3 Only)-Asyncio queues
- atexit module, Termination Functions
- base64 module, The base64 Module
- benefits of, The Python Standard Library and Extension Modules
- bz2 module, The bz2 Module
- calendar module, The calendar Module-The calendar Module
- cmd module, Interactive Command Sessions-A Cmd Example
- codecs module, The codecs Module
- collections module, The collections Module-namedtuple
- concurrent.futures module, The concurrent.futures Module-The concurrent.futures Module
- copy module, The copy Module-The copy Module
- copy_reg module, Pickling customization with the copy_reg module
- ctypes module, ctypes
- datetime module, The datetime Module-The timedelta Class
- dbm package, DBM Modules-Examples of DBM-Like File Use
- decimal module, The decimal Module
- doctest module, The doctest Module-The doctest Module
- email package, MIME and Email Format Handling-rfc822 and mimetools Modules (v2)
- errno module, The errno Module
- filecmp module, The filecmp Module
- fileinput module, The fileinput Module-The fileinput Module
- fnmatch module, The fnmatch Module
- fractions module, The fractions Module
- functools module, The functools Module
- gc module, The gc Module
- getpass module, The getpass Module
- gettext module, The gettext Module-Essential gettext functions
- glob module, The glob Module
- gzip module, The gzip Module
- heapq module, The heapq Module-The Decorate-Sort-Undecorate Idiom
- html.entities/htmlentitydefs modules, The html.entities (v2: htmlentitydefs) Module
- imaplib module, Email Protocols
- inspect module, The inspect Module-An example of using inspect
- io module, The io Module-The tempfile Module
- itertools module, The itertools Module-The itertools Module
- json module, The json Module-A JSON example
- linecache module, The linecache Module
- locale module, The locale Module-The locale Module
- math and cmath modules, The math and cmath Modules-The math and cmath Modules
- mmap module, The mmap Module
- multiprocessing module, The multiprocessing Module-The AsyncResult class
- operator module, The operator Module-The operator Module
- os module, The os Module, Running Other Programs with the os Module
- os.path module, The os.path Module-The os.path Module
- os.stat module, The stat Module
- pickle and cPickle modules, The pickle and cPickle Modules-Pickling customization with the copy_reg module
- pprint module, The pprint Module
- profile module, The profile module
- pstats module, The pstats module
- queue module, The queue Module
- quopri module, The quopri Module
- random module, Random and Pseudorandom Numbers
- re module, Regular Expressions and the re Module, Functions of the re Module
- readline module, The readline Module
- reprlib module, The reprlib Module
- sched module, The sched Module
- selectors module, The selectors Module-selectors echo server example
- shelve module, The shelve Module-A shelving example
- shutil module, The shutil Module-The shutil Module
- site/sitecustomize modules, The site and sitecustomize Modules
- socket module, The socket Module-Socket creation functions
- ssl module, SSLContext
- string module, The string Module
- struct module, The struct Module-The struct Module
- subprocess module, The Subprocess Module
- sys module, The sys Module-The sys Module
- tarfile module, The tarfile Module-The tarfile Module
- telnetlib module, Other Network Protocols
- tempfile module, The tempfile Module-The tempfile Module
- threading module, The threading Module-Thread Local Storage
- time module, The time Module
- timeit module, The timeit module
- traceback module, The traceback Module
- unicodedata module, The unicodedata Module
- urllib.parse/urlparse modules, The urllib.parse (v3) / urlparse (v2) modules, The urllib Package (v3)
- weakref module, The weakref Module
- xml.etree.ElementTree module, ElementTree
- zipfile module, The zipfile Module-The zipfile Module
- zlib module, The zlib Module
- __future__ module, Preparing for Python 3
- standard output, Standard Output and Standard Error
- stat module, The stat Module
- statements
- static methods, Static methods
- stderr, Standard Output and Standard Error
- stdin, Standard Input
- stdout, Standard Output and Standard Error
- str data type, Built-in Types
- stream, Organization of This Chapter, Transports and protocols, asyncio streams
- strftime function, The time Module-The time Module
- string data type
- byte strings, Strings
- bytestring, Strings and Things
- definition of, Strings
- escape sequences, Strings
- formatted string literals, Strings, Strings and Things, New in 3.6: Formatted String Literals
- formatting, Strings and Things, String Formatting
- newline character, Strings
- quoted strings, Strings
- raw strings, Strings
- sequence operations, Strings
- Unicode, Strings, Strings and Things
- v2 vs. v3, Strings
- string handling
- methods of string and bytes objects, Methods of String and Bytes Objects-Methods of String and Bytes Objects
- optimizing string operations, String operations, Building up a string from pieces
- overview of, Strings and Things
- pprint module, The pprint Module
- reprlib module, The reprlib Module
- string formatting, String Formatting-When to use %r
- string module, The string Module-When to use %r
- text wrapping and filling, Text Wrapping and Filling
- Unicode characters, Unicode-The unicodedata Module
- string literals, in v2 vs. v3, String Literals
- StringIO class, In-Memory “Files”: io.StringIO and io.BytesIO
- struct, A substantial custom metaclass example
- struct module, The struct Module-The struct Module
- structured text
- stubs, Unit Testing and System Testing
- subclass, The class Statement, Overriding attributes
- subnetwork (link) layer, Networking Basics
- subpackages, Packages
- subprocess module, The Subprocess Module
- sum function, Sequences in General
- super, Built-in Types
- superclass, Overriding attributes
- support strategies (see v2/v3 migration and coexistence)
- switch (see if)
- symbolic links, File and Directory Functions of the os Module
- syntax
- sys module, The sys Module-The sys Module
- sys.argv, Command-Line Syntax and Options
- (see also command-line arguments)
- sys.module, sys.modules Entries
- system testing, Testing
T
- tabs vs. spaces, Lines and Indentation
- tarfile module, The tarfile Module-The tarfile Module
- TCP/IP (Transmission Control Protocol over common IP)
- telnetlib module, Other Network Protocols
- tempfile module, The tempfile Module-The tempfile Module
- termination functions, Termination Functions
- ternary operator, The ternary operator
- test fixtures, The unittest Module
- test-case methods, The unittest Module
- test-driven development (TDD), Unit Testing and System Testing
- testing
- bug-fixing best practices, Unit Testing and System Testing
- dealing with large amounts of data, Unit tests dealing with large amounts of data
- definition of, Testing, Debugging, and Optimizing
- doctest module, The doctest Module-The doctest Module
- failures discovered by, Unit Testing and System Testing
- frameworks for, Unit Testing and System Testing
- frequency of, Unit Testing and System Testing
- goals of, Unit Testing and System Testing
- integration testing, Unit Testing and System Testing
- reproducible randomness, Unit tests dealing with large amounts of data
- stubs and mocks, Unit Testing and System Testing
- types of, Testing
- unit vs. system, Unit Testing and System Testing
- unittest module, The unittest Module-Unit tests dealing with large amounts of data
- white- vs. black-box, Unit Testing and System Testing
- text (see also file and text operations)
- text editors, Free Text Editors with Python Support
- thread pools, Threaded Program Architecture
- thread-local storage (TLS), Thread Local Storage
- thread-safe, Threads in Python, Futures
- threading module
- threads and processes
- vs. async programming, Threads and Processes
- benefits and drawbacks of, Threads and Processes
- concurrent.futures module, The concurrent.futures Module-The concurrent.futures Module
- connection-oriented networking, Client-Server Computing
- definition of processes, Threads and Processes
- definition of threads, Threads and Processes
- GIL (Global Interpreter Lock), Threads and Processes
- mmap module, The mmap Module
- multiprocessing module, The multiprocessing Module-The AsyncResult class
- os module, Running Other Programs with the os Module
- overview of, Threads in Python
- process environment, Process Environment
- queue module, The queue Module
- subprocess module, The Subprocess Module-Methods of subprocess.Popen instances
- threaded program architecture, Threaded Program Architecture-Threaded Program Architecture
- threading module, The threading Module-Thread Local Storage
- time module
- time operations
- timeit module, Benchmarking, The timeit module
- timeout parameters , Timeout parameters
- (see also threading module)
- Timer objects, Timer objects
- timetuples, The time Module
- timezones (see also time operations)
- TLS (Transport Layer Security), Transport Layer Security (TLS, AKA SSL)
- tokens
- Tornado, Coroutine-Based Async Architectures
- tox, v2/v3 Support with Conversion
- traceback, The traceback Module
- traceback module, The traceback Module
- Transcrypt, Transcrypt: Convert your Python to JavaScript
- transport (host-to-host) layer, Networking Basics, The Berkeley Socket Interface
- Transport Layer Security (TLS), Transport Layer Security (TLS, AKA SSL)
- True value (bool), The if Statement
- truth values, Boolean Values
- try statements (see also exception)
- tuple data type, Built-in Types
- TurboGears, A Few Popular Full-Stack Frameworks
- type, Data Types, Built-in Types
- type checking
- type hints, Function Annotations and Type Hints (v3 Only)
- type objects, Type Objects
- typographic conventions, Typographic Conventions
- tzinfo instances, The pytz Module
U
- UDP (User Datagram Protocol), Networking Principles
- unbound method objects, Bound and Unbound Methods
- unbounded iterators, Generators
- underscore
- unfinished tasks, Methods of Queue Instances
- Unicode characters, Character Sets, Strings, Strings, Unicode-The unicodedata Module, Text and Binary Data
- unicode data type (v2), Built-in Types
- unicodedata module, The unicodedata Module
- unit testing, Testing, Preparing for Python 3
- unittest module
- Unix sockets, The Berkeley Socket Interface
- unpacking
- URI (Uniform Resource Identifier), URL Access, Falcon
- URL (Uniform Resource Locator), Client-Side Network Protocol Modules, URL Access
- urllib module, The urllib Module (v2)
- urllib.parse/urlparse modules, The urllib.parse (v3) / urlparse (v2) modules, The urllib Package (v3)
- urllib2 module, The urllib2 Module (v2)
- UTC (Coordinated Universal Time), The time Module
V
- v2/v3 migration and coexistence
- values, Dictionaries
- van Rossum, Guido, Python Development and Versions
- variable
- assignment, Variables
- binding, Variables
- declaration, Variables
- free, Nested functions and nested scopes
- global, Variables, The global statement
- identifiers, Identifiers
- local, Variables, The global statement
- rebinding, Variables
- unbinding, Variables
- vectors, Matrix Operations in NumPy, List operations
- venv, What Is a Virtual Environment?
- versions and development
- vertical bars (|), Command-Line Syntax and Options
- very-high-level languages (VHLL), The Python Language
- virtual circuits, Client-Server Computing
- virtual environments
- benefits of, Enter the Virtual Environment
- best practices for, Best Practices with virtualenvs
- creating and deleting, Creating and Deleting Virtual Environments
- definition of, What Is a Virtual Environment?
- dependency management, Managing Dependency Requirements
- module installation, Building and Installing C-Coded Python Extensions
- overview of, What Is a Virtual Environment?
- recommendations for, Other Developments, Implementations, and Distributions
- working with, Working with Virtual Environments
- virtualenv (see virtual environments)
W
- W3C (World Wide Web Consortium), Structured Text: XML
- warnings module
- weak reference objects, The weakref Module
- weakref module, The weakref Module
- web frameworks
- Bottle, Some Popular Lightweight Frameworks
- Django, A Few Popular Full-Stack Frameworks
- Falcon, Some Popular Lightweight Frameworks
- Flask, Some Popular Lightweight Frameworks
- full-stack, Full-Stack Versus Lightweight Frameworks
- lightweight, Full-Stack Versus Lightweight Frameworks
- Pyramid, A Few Popular Full-Stack Frameworks
- standard for, WSGI
- TurboGears, A Few Popular Full-Stack Frameworks
- webapp2, Some Popular Lightweight Frameworks
- web servers, Serving HTTP
- web2py, A Few Popular Full-Stack Frameworks
- webapp2 web framework
- WebSocket, The asyncio Module (v3 Only)
- well-known port numbers, The Berkeley Socket Interface, URL Access
- Werkzeug, When you use lightweight frameworks
- wheels
- while statements, The while Statement
- white-box testing, Unit Testing and System Testing
- whitespace, Lines and Indentation
- WiPy, MicroPython: Is your child already a programmer?
- with open, Creating a “file” Object with io.open
- with statements, The with Statement, The with Statement and Context Managers
- (see also finally clauses)
- World Wide Web Consortium (W3C), Structured Text: XML
- WSGI (Web Server Gateway Interface)
..................Content has been hidden....................
You can't read the all page of ebook, please click
here login for view all page.