Python (programming Language) - Standard Library

Standard Library

Python has a large standard library, commonly cited as one of Python's greatest strengths, providing tools suited to many tasks. This is deliberate and has been described as a "batteries included" Python philosophy. The modules of the standard library can be augmented with custom modules written in either C or Python. Boost C++ Libraries includes a library, Boost.Python, to enable interoperability between C++ and Python. Because of the wide variety of tools provided by the standard library, combined with the ability to use a lower-level language such as C and C++, which is already capable of interfacing between other libraries, Python can be a powerful glue language between languages and tools.

The standard library is particularly well tailored to writing Internet-facing applications, with a large number of standard formats and protocols (such as MIME and HTTP) already supported. Modules for creating graphical user interfaces, connecting to relational databases, arithmetic with arbitrary precision decimals, manipulating regular expressions, and doing unit testing are also included.

Some parts of the standard library are covered by specifications (for example, the WSGI implementation wsgiref follows PEP 333), but the majority of the modules are not. They are specified by their code, internal documentation, and test suite (if supplied). However, because most of the standard library is cross-platform Python code, there are only a few modules that must be altered or completely rewritten by alternative implementations.

The standard library is not essential to run Python or embed Python within an application. Blender 2.49 for instance omits most of the standard library.

For software testing, the standard library provides the unittest and doctest modules.

Read more about this topic:  Python (programming Language)

Famous quotes containing the words standard and/or library:

    Any honest examination of the national life proves how far we are from the standard of human freedom with which we began. The recovery of this standard demands of everyone who loves this country a hard look at himself, for the greatest achievments must begin somewhere, and they always begin with the person. If we are not capable of this examination, we may yet become one of the most distinguished and monumental failures in the history of nations.
    James Baldwin (1924–1987)

    Every library should try to be complete on something, if it were only the history of pinheads.
    Oliver Wendell Holmes, Sr. (1809–1894)