I Can’t Sleep - Python Coding Language | Calm Bedtime Reading
Episode Date: March 7, 2024Unwind with this calm bedtime reading on the Python programming language, created to ease insomnia and bring peace to restless nights. In this soothing episode, Benjamin explores the origins of Python..., its design philosophy of readability and simplicity, and its widespread use in web development, data science, and beyond. His steady, gentle narration provides both knowledge and relaxation—no whispers, no hypnosis, just calm, fact-filled storytelling to quiet the mind. Whether you’re struggling with stress, anxiety, or sleeplessness, press play, relax, and drift into restful sleep while learning about the story of Python. Want More? Request a Topic: https://www.icantsleeppodcast.com/request-a-topic Ad-Free Episodes: https://icantsleep.supportingcast.fm/ Shop Sleep-Friendly Products: https://www.icantsleeppodcast.com/sponsors Join the Discussion on Discord: https://discord.gg/myhGhVUhn7 This content is derived from the Wikipedia article on Python (programming language), available under the Creative Commons Attribution-ShareAlike (CC BY-SA) license. Read the full article: Wikipedia – Python (programming language). Happy sleeping! Learn more about your ad choices. Visit megaphone.fm/adchoices
Transcript
Discussion (0)
You're listening to a Glassbox media podcast.
What if I told you that most of the modern day self-help advice you've been hearing could actually make you worse?
The key to a better life isn't about feel-good gimmicks that sound catchy.
The Mentally Stronger Podcast gives you access to a licensed therapist who shares science-backed tools that will actually change your life.
Hi, I'm Amy Morin, psychotherapist, mental strength trainer, and international best-selling author.
In each episode, we cover research-back strategies, like how to stop relying on willpower and start
creating habits for lasting change.
And the five mental strength-building exercises you can do from your couch.
I also speak to world-class experts like Dr. Nicole Kane, who shares how to permanently
heal anxiety by addressing the root cause.
With over 200 episodes in our catalog, this podcast is for you if you're ready to crush
self-doubt, conquer challenges, and become stronger than ever with therapist-approved
strategies that can change your life. Listen to Mentally Stronger with Therapist Amy Morin, wherever
you get your podcasts. Welcome to the I Can't Sleep Podcast, where I read random articles
from across the web to bore you to sleep with my soothing voice. I'm your host, Benjamin Boster.
Today's episode is from a Wikipedia article titled Python Programming Language.
Python is a high-level general-purpose programming language.
Its design philosophy emphasizes code readability with the use of significant indentation.
Python is dynamically typed and garbage collected.
It supports multiple programming paradigms, including structure,
partially procedural, object-oriented, and functional programming.
It is often described as a battery's included language due to its comprehensive standard library.
Guido Van Rossum began working on Python in the late 1980s,
as a successor to the ABC programming language,
and first released it in 1991 as Python 0.9.0.
Python 2.0 was released in 2000.
Python 3.0, released in 2008, was a major revision, not completely backward compatible with earlier versions.
Python 2.7.18 released in 2020 was the last release of Python 2.
Python consistently ranks as one of the most popular programming languages,
and has gained widespread use in the machine.
learning community. Python was conceived in the late 1980s by Guido Fenrosum at Centrum
Wiskund and Informatica, CWI, in the Netherlands, as a successor to the ABC program and language,
which was inspired by CEDL, capable of exception handling and interfering with the amoeba operating
system. Its implementation began in December 1989. Van Rasm's shoulders shoulders
some responsibility for the project as the lead developer until 12th of July 2018,
when he announced his permanent vacation from his responsibilities as Python's benevolent dictator
for life, a title the Python community bestowed upon him to reflect his long-term commitment
as the project's chief decision-maker. In January 2019, active Python core developers elected
a five-member steering council to lead the project.
Python 2.0 was released on the 16th of October 2000,
with many major new features, such as list comprehensions,
cycle-detecting, garbage collection, reference counting, and unicode support.
Python 3.0 released on the 3rd of December 2008,
with many of its major features backboarded to Python 2.6.X
and 2.7.X. Releases of Python 3 include the 2-3 utility, which automates the translation
of Python 2 code to Python 3. Python 2.7's end of life was initially set for 2015, then postponed
to 2020 out of a concern that a large body of existing code could not easily be forward-ported
to Python 3. No further security patches or other improvements.
will be released for it.
Currently, only 3.8 and later are supported.
2023 security issues were fixed in, e.g. 3.7.17,
the final 3.7.X release.
While Python 2.7 and older is officially unsupported,
a different unofficial Python implementation, Pi Pi Pi,
continues to support Python 2, i.e. 2.7,
7.18 plus, plus 3.9 and 3.10. With the plus, meaning at least some, backported security updates.
In 2021, and again twice in 2022, security updates were expedited since all Python versions were
insecure, including 2.7, because of security issues leading to possible remote code execution
and web cache poisoning.
In 2022, Python 3.10.4 and 3.9.12 were expedited and 3.8.13 because of many security issues.
When Python 3.9.13 was released in May 2022, it was announced that the 3.9 series, joining the older series 3.8 and 3.7,
would only receive security fixes in the future.
On September 7, 2022, four new releases were made due to a potential denial of service attack.
3.10.7, 3.9.14, 3.8.14 and 3.7.14 and 3.7.14.
As of October 2020, Python 3.12 is the stable release,
and 3.12 and 3.11 are the only versions with active as opposed to just security.
support. Notable changes in 3.11 from 3.10 include increased probable execution speed and improved error
reporting. Python 3.12 adds syntax, and in fact every Python sins at least 3.5 adds some syntax to the
language. The new soft keyword type, recent releases have added a lot of typing support,
e.g. new type union operator in 3.10, and 3.11 for exception handling, and 3.10, the matching case,
soft keywords, for structural pattern matching statements.
Python 3.12 also drops outdated modules and functionality, and future versions will too.
Python 3.11 claims to be between 10 and 60% faster than Python 3.10,
And Python 3.12 adds another 5% on top of that.
It also has improved error messages and many other changes.
Since the 27th of June 2023, Python 3.8 is the oldest supported version of Python,
albeit in the security support phase due to Python 3.7 reaching end of life.
Python is a multi-paradigm programming language.
Object-oriented programming and structured programming are fully
supported, and many of their features support functional programming and aspect-oriented programming,
including meta-programming and meta-objects.
Many other paradigms are supported via extensions, including design by contract and logic programming.
Python uses dynamic typing and a combination of reference counting, and a cycle-detecting
garbage collector for memory management. It uses dynamic name resolution, late binding,
which binds method and variable names during program execution. Its design offers some
support for functional programming in the LISP tradition. It has filter, map, and reduce functions,
list comprehensions, dictionaries, sets, and generator expressions. The standard library has two
modules, iter tools and funk tools that implement functional tools borrowed from Haskell and
Standard ML. Its core philosophy is summarized in the Zen of Python, PEP20, which includes
aphorisms such as, Beautiful is better than ugly, explicit is better than implicit, simple is better
than complex, complex is better than complicated, readability counts.
However, Python features regularly violate these principles
and received criticism for adding unnecessary language bloat.
Responses to these criticisms are that the Zen of Python is a guideline rather than a rule.
New features have been so controversial that Guido Van Rossum resigned as benevolent dictator for life,
following vitriol over addition of the assignment expression operator in Python 3.8.
Nevertheless, rather than building all of its functionality into its core,
Python was designed to be highly extensible via modules.
This compact modularity has made it particularly popular as a means of adding programmable interfaces to existing applications.
Ben Rossum's vision of a small core language with a large standard library
and easily extensible interpreters stemmed from as frustrations with ABC.
which espouse the opposite approach.
Python claims to strive for a simpler, less cluttered syntax and grammar
while giving developers a choice in their coding methodology.
In contrast to pearls, there's more than one way to do it, motto.
Python embraces a there should be one,
and preferably only one obvious way to do it, philosophy.
In practice, however, Python provides many ways to achieve the same,
same task. There are, for example, at least three ways to format a string literal, with no certainty
as to which one a programmer should use. Alex Martelli, a fellow at the Python Software Foundation
and Python book author wrote, to describe something as clever is not considered a compliment in
the Python culture. Python's developers usually strive to avoid premature optimization and reject patches
to non-critical parts of the C-Python reference implementation
that would offer marginal increases in speed
of the cost of clarity.
Execution speed can be improved by moving speed critical functions
to extension modules, written in languages such as C,
or by using a just-in-time compiler like Pi-Pi.
It is also possible to cross-compile to other languages,
but it either doesn't provide the full speed,
that might be expected, since Python is a very dynamic language, or a restricted subset of
Python is compiled, and possibly semantics are slightly changed. Python's developers aim for it to be
fun to use. This is reflected in its name, a tribute to the British comedy group Monty Python,
and in occasionally playful approaches to tutorials and reference materials, such as the use of the terms
spam and eggs, a reference to a Monty Python sketch, and examples instead of the often used
foo and bar. A common neologism in the Python community is Pythonic, which has a wide range of
meanings related to program style. Pythonic code may use Python idioms well, be natural or show
fluency in the language, or conform with Python's minimalist philosophy and else.
emphasis on readability. Code that is difficult to understand or reads like a rough transcript
from another programming language is called un-Pythonic. Python is meant to be an easily
readable language. Its formatting is visually unc cluttered and often uses English keywords where
other languages use punctuation. Unlike many other languages, it does not use curly brackets to
deliminate blocks, and semicolons after statements are allowed but rarely used. It has fewer syntactic
exceptions and special cases than C or Pascal. Python uses white space indentation rather than curly brackets
or keywords to delimit blocks. An increase in indentation comes after certain statements. A decrease in
indentation signifies the end of the current block. Thus, the program's visual structure accurate
represents its semantic structure.
This feature is sometimes termed the off-side rule.
Some other languages use indentation this way,
but in most, indentation has no semantic meaning.
The recommended indent size is four spaces.
Python's statements include
the assignment statement using a single equals sign,
the if statement,
which conditionally executes a block of
code, along with else and elif, a contraction of elsif.
The four statement, which iterates over an iterable object, capturing each element to a local
variable for use by the attached block.
The while statement, while executes a block of code as long as its condition is true.
The try statement, which allows exceptions raised in its attached code block to be caught and handled
by accept clauses, or new syntax except in Python 3.11 for exception groups.
It also ensures that cleanup code in a finally block is always run regardless of how the block exits.
The raise statement used to raise a specified exception or re-raise a caught exception.
The class statement, which executes a block of code and attaches its local namespaces
to a class for use in object-oriented programming.
The DEF statement, which defines a function or method.
The with statement, which encloses a code block with a context manager,
for example, acquiring a lock before it is run, then releasing the lock,
or opening and closing a file, allowing resource acquisition is initialization or a AII-like behavior,
and replacing a common tri-finale idiom,
the break statement which exits a loop,
the continuous statement which skips the rest of the current iteration,
and continues with the next.
The Dell statement, which removes a variable,
deleting the reference from the name to the value,
and producing an error if the variable is referred to before it is redefined.
The past statement, serving as a knob,
syntactically needed to create an empty code block.
The assert statement used in debugging to check for conditions that should apply.
The yield statement, which returns a value from a generator function,
and also an operator, used to implement core routines.
The return statement used to return a value from a function.
The import and from statements used to import modules whose
functions or variables can be used in the current program.
The assignment statement binds a name as a reference to a separate dynamically allocated object.
Variables may subsequently be rebound at any time to any object.
In Python, a variable name is a generic reference holder with a fixed data type.
However, it always refers to some object with a type.
This is called dynamic typing, in contrast to static
typically typed languages, where each variable may contain only a value of a certain type.
Python does not support tail-call optimization or first-class continuations,
and according to Van Rossum, it never will. However, better support for core routine-like
functionality is provided by extending Python's generators. Before 2.5, generators were lazy
iterators. Data was passed unidirectionally out of the generator. From Python 2.5 on, it is possible to
pass data back into a generator function, and from version 3.3, it can be passed through multiple
stack levels. Python's expressions include the plus, minus, and times operators for mathematical
addition, subtraction, and multiplication are similar to other languages, but the behavior of
division differs. There are two types of divisions in Python, floor division or integer division,
and floating point division. Python uses the double asterix operator for exponentiation.
Python uses the plus operator for string concatenation. Python uses the asterix operator for
duplicating a string a specified number of times. The
At infix operator, it is intended to be used by libraries such as NumPy for matrix multiplication.
The syntax, colon equals, called the walrus operator, was introduced in Python 3.8.
It assigns values to variables as part of a larger expression.
In Python, the 2 equals sign compares by value.
Python's is operator may be used to,
to compare object identities, comparison by reference.
And comparisons may be chained, for example,
A is less than or equal to B, which is less than or equal to C.
Python uses and or and not as Boolean operators.
Python has a type of expression called a list comprehension,
as well as a more general expression called a generator expression.
Anonymous functions are implemented,
using lambda expressions. However, there may only be one expression in each body. Conditional
expressions are written as X if C else Y, different in order of operands from the C question mark X colon Y
operator, common to many other languages. Ison makes a distinction between lists and tuffles.
lists are written as bracket 1 comma 2 comma 3 close bracket are mutable and cannot be used as the keys of dictionaries dictionary keys must be immutable in python
tuples written as parentheses 1 comma 2 comma 3 close parentheses are immutable and thus can be used as keys of dictionaries provided all the tuples elements are immutable
The plus operator can be used to concatenate two tuples, which does not directly modify their contents,
but produces a new tuple containing the elements of both.
Thus, given the variable T initially equal to open parentheses 1 comma 2, 3 close parentheses, executing T equals T plus open parentheses 4 comma 5 close parentheses,
first evaluates T plus, open parentheses, 4, 5, closed parentheses,
which yields open parentheses 1, 2, 3, 4, 4, 5, close parentheses,
which is then assigned back to T, thereby effectively modifying the contents of T
while conforming to the immutable nature of tuple objects.
Parentheses are optional for tuples in unambiguous,
contexts. Python features sequence unpacking where multiple expressions, each evaluating to anything
that can be assigned to a variable, writable property, etc., are associated in an identical manner to that
forming tuple literals, and as a whole are put on the left-hand side of the equal sign in an assignment
statement. The statement expects an iterable object on the right-hand side of the equal sign that produces
the same number of values as the provided writable expressions.
When iterated through them, it assigns each of the produced values to the corresponding
expression on the left.
Python has a string format operator modulo that functions analogously to print F-format strings
in C, e.g. spam equals modulo S, eggs equal module D,
modulo open parentheses, quote, blah, close quote, comma, two, close parentheses.
Evaluates to, quote, spam equals blah, eggs equal two, close quote.
In Python 2.6 plus and 3 plus, this was supplemented by the format method of the string class,
e.g., quote, spam equals zero, eggs equals 1, close quote, dot,
Format, open parentheses, quote, blah, quote, comma, two, close parentheses.
Python 3.6 added F strings, colon, spam equals, quote, blah, close quote, semicolon, eggs equal to, semicolon.
F, spam, close curly bracket, spam, close curly bracket.
Eggs equals open curly bracket, eggs, close curly bracket.
strings in Python can be concatenated by adding them with the same operator as for adding integers and floats,
e.g. quote, spam, close quote, plus, quote, eggs, close quote, returns, quote, spam eggs with no space, close quote.
If strings contain numbers, they are added as strings rather than integers,
e.g. Open quote 2, close quote, plus open quote to close quote, returns open quote to 2, close quote.
Python has various string literals, delimited by single or double quotes, unlike in Unix shells, Pearl and Pearl Influence languages, single and double quotes work the same.
Both use the backslash as an escape character.
string interpolation became available in Python 3.6 as formatted string literals.
Triple-quoted, beginning and ending with three single or double quotes,
which may span multiple lines and function like hear documents and shells, Pearl and Ruby.
Raw string varieties denoted by prefixing the string literal with R,
escape sequences are not interpreted.
Hence, the raw strings are useful where,
literal backslashes are common, such as regular expressions and Windows-style paths.
Compare at quoting in C-sharp.
Python has array index and array slicing expressions in lists, denoted as a key, a start-stop,
or a start-stop-step.
Indexes are zero-based, and negative indexes are relative to the end.
Slices take elements from the start index up to, but not including the stop index.
The third slice parameter called step and stride allows elements to be skipped and reversed.
Slice indexes may be omitted, for example, a colon returns a copy of the entire list.
Each element of a slice is a shallow copy.
In Python, a distinction between expressions and statements.
is rigidly enforced, in contrast to languages such as common Lisp, Scheme, or Ruby.
This leads to duplicating some functionality.
For example, list comprehensions versus for loops.
Conditional expressions versus if blocks.
The E-Val versus exec built-in functions in Python 2 exec is a statement.
The former is for expressions, the latter is for statements.
Statements cannot be a part of an expression, so list and other comprehensions or lambda expressions, all being expressions, cannot contain statements.
A particular case is that an assignment statement such as a equals 1 cannot form part of the conditional expression of a conditional statement.
This has the advantage of avoiding a classic C error of mistaking an assignment operator equals for an equality operator's
double equals in conditions.
If open parentheses C equals 1 close parentheses,
open curly bracket, dot, dot, dot, close curly bracket,
is syntactically valid but probably unintended C code,
but if C equals 1 colon dot dot dot dot causes a syntax error in Python.
Methods on objects are functions attached to the object's class.
the syntax instance. Method, open parentheses, argument, close parentheses,
is for normal methods and functions, syntax sugar for class.
method, open parentheses, instance, comma, argument, close parentheses.
Python methods have an explicit self-parimeter to access instance data.
In contrast to the implicit self or this in some other object-oriented programming languages,
e.g. C++, Java, Objective C, Ruby.
Python also provides methods, often called dunder methods,
due to their names being an ending with double underscores,
to allow user-defined classes to modify how they are handled by native operations,
including length, comparison, and arithmetic operations, and type conversion.
Python uses duct typing and has typed objects, but untimbed,
typed variable names. Type constraints are not checked at compile time, rather operations on an
object may fail, signifying that it is not of a suitable type. Despite being dynamically typed,
Python is strongly typed, forbidding operations that are not well defined, for example adding a
number to a string rather than silently attempting to make sense of them. Python allows
programmers to define their own types using classes, most often used for object-oriented programming.
New instances of classes are constructed by calling the class, for example, spam class or
eggs class, and the classes are instances of the meta-class type itself and instance of itself,
allowing metaprogramming and reflection.
Before version 3.0, Python had two kinds of classes.
both using the same syntax.
Old style and new style.
Current Python versions only support the semantics of new style.
Python supports optional type annotations.
These annotations are not enforced by the language,
but may be used by external tools such as MyPy to catch errors.
MyPy also supports a Python compiler called MyPick,
which leverages type annotations for optimization.
Python's large standard library provides tools suited to many tasks and is commonly cited as one of its greatest strengths.
For internet-facing applications, many standard formats and protocols such as MIME and HTTP are supported.
It includes modules for creating graphical user interfaces, connecting to relational databases,
generating pseudo-random numbers, arithmetic with arbitrary
precision decimals, manipulating regular expressions, and unit testing. Some parts of the standard
library are covered by specifications. For example, the Web Service Gateway Interface
WSGI implementation WSGIREF follows PEP3333, but most are specified by their code, internal documentation,
and test suites. However, because most of the
the standard library is cross-platform Python code. Only a few modules need altering or
rewriting for variant implementations. As of the 14th of November 2022, the Python Package Index,
Pi Pi, the official repository for third-party Python software, contains over 415,000 packages
with a wide range of functionality, including automation, data analytics, data,
databases, documentation, graphical user interfaces, image processing, machine learning, mobile apps, multimedia, computer networking, scientific computing, system administration, test frameworks, web scraping.
Most Python implementations, including C-Python, include a read-eval print loop, R-EPL,
permitting them to function as a command-line interpreter,
for which users enter statements sequentially and receive results immediately.
Python also comes with an integrated development environment, IDE, called Idle,
which is more beginner-oriented.
Other shells, including idle and iPypocket,
Python add further abilities, such as improved auto-completion, session state retention,
and syntax highlighting.
As well as standard desktop integrated development environments, including PiCharm, IntelliJ, Idea,
Visual Studio, Code, etc.
There are web browser-based IDs, including SageMath for developing science and math-related
programs.
Python Anywhere, a browser-based IDE and hosting environment,
and Canopy IDE, a commercial IDE emphasizing scientific computing.
C-Python is the reference implementation of Python.
It is written in C-E, meeting the C-89 standard.
Python 3.11 uses C-11, with several select C-99 features.
C-Python includes its own C-E extensions,
but third-party extensions are not limited to older C-versions,
e-g. they can be implemented with C-11 or C++.
It compiles Python programs into an intermediate bytecode,
which is then executed by its virtual machine.
Python is distributed with a large standard library
written in a mixture of C and native Python,
and is available for many platforms including Windows,
starting with Python 3.9,
the Python installer deliberately fails to install on Windows 7 and 8.
Windows XP was supported until Python 3.5,
and most modern Unix-like systems,
including MacOS and Apple M1 Macs,
since Python 3.9.1,
with experimental installer and unofficial support for EGVMS.
Platform portability was one of its earliest
priorities. During Python 1 and 2 development, even OS2 and Solaris were supported, but support has
since been dropped for many platforms. Pi Pi is a fast, compliant interpreter of Python 2.7 and 3.8.
Its just-in-time compiler often brings a significant speed improvement over C-Python, but some
libraries written in C cannot be used with it. Stackless Python is a significant fork of
Python that implements microthreads.
It does not use the call stack in the same way,
thus allowing massively concurrent programs.
PiPy also has a stackless version.
MicroPython and Circuit Python
are Python-3 variants optimized for microcontrollers,
including Lego Mindstorm's EV3.
Pistin is a variant of the Python runtime that uses just-in-time compilation
to speed up the execution of Python programs.
Cinder is a performance-oriented fork for C-Python 3.8
that contains a number of optimizations,
including bytecode inline caching,
eager evaluation of co-routines,
a method at a time, J-I-T,
and an experimental bytecode compiler.
SNAC-embedded computing language,
supporting eG 8-bit AVR microcontrollers,
such as AT Mega-328P-based Arduino,
and larger ones that are MicroPython can also support.
Is Python inspired but is not Python?
It is possible to write SNCC programs that run under a full Python system,
but most Python programs will not run under SNCC.
It's an imperative language, not including OOP classes unlike Python,
and simplifying to one number type like JavaScript.
except using smaller 32-bit single-precision integer values of less than 24-bids can be expressed
exactly in these floating-point values. Other just-in-time Python compilers have been developed,
but are now unsupported. Google began a project named Unladen Swallow in 2009,
with the aim of speeding up the Python interpreter five-fold by using the LLVM,
and of improving its multi-threading ability to scale to thousands of cores,
while ordinary implementations suffer from the global interpreter lock.
Psycho is a discontinued just-in-time specialization compiler that integrates with C-Python
and transforms bytecode to machine code at runtime.
The emitted code is specialized for certain data types and is faster than the standard Python code.
Psycho does not support Python 2.7 or later.
PiS60 was a Python 2 interpreter for Series 60 mobile phones,
released by Nokia in 2005.
It implemented many of the modules from the standard library
and some additional modules for integrating with the Symbian operating system.
The Nokia N900 also supports Python with GTK widget libraries,
enabling programs to be written and run on the target device.
There are several compilers transpilers to high-level object languages
with either unrestricted Python, a restricted subset of Python,
or a language similar to Python as a source language.
Brython, Transcript, and PiJS, latest release in 2012,
compile Python to JavaScript.
Kodon compiles a subset of static,
typed Python to machine code via LLVM and supports native multithreading.
Cithon compiles a superset of Python to C.
The resulting code is also usable with Python via direct C-level API calls into the Python interpreter.
IJL compiles, transpiles, a subset of Python to human-readable, maintainable, and high-performance
Julia's source code.
Despite claiming high performance,
no tool can claim to do that for arbitrary Python code,
i.e. it's known not possible to compile to a faster language or machine code.
Unless semantics of Python are changed,
but in many cases speed up is possible with few or no changes in the Python code.
The faster Julia's source code can then be used from Python or compiled.
the machine code and based that way.
Nuitka compiles Python into C.
Numba uses LLVM to compile a subset of Python to machine code.
Python compiles a subset of Python 3 to C++, C++11.
Our Python can be compiled to C and is used to build the Pi PiPi interpreter of Python.
MyHtL is a Python-based hardware description language HTL.
that converts my HtL code to Verilog or VHTL code.
Older projects.
Google's Grumpy, latest release in 2017, transpiles Python 2 to go.
Iron Python allows running Python 2.7 programs,
and an alpha released in 2021 is also available for Python 3.4,
although features and behaviors from later versions may be included on the dot-net common language runtime.
Githon compiles Python 2.7 to Java bytecode, allowing the use of the Java libraries from a Python program.
Pyrex, latest release in 2010, and Shedskin, latest release in 2013, compile to C and C++, respectively.
Performance comparison of various Python implementations on a non-numerical combinatorial workload
was presented at Euro-SciPi-Pi-13.
Python's performance compared to other programming languages
is also benchmarked by the computer language benchmarks game.
Python's development is conducted largely
through the Python enhancement proposal PEP process.
The primary mechanism for proposing major new features,
collecting community input on issues,
and documenting Python design decisions.
Python coding style is covered in PEP8.
Outstanding PEPs are reviewed and commented on by the Python community and the steering council.
Enhancement of the language corresponds with the development of the C-Python reference implementation.
The mailing list Python Dev is the primary forum for the language's development.
Specific issues were originally discussed in the Roundup bug tracker hosted at by the foundation.
In 2022, all issues and discussions were migrated to GitHub.
Development originally took place on a self-hosted source code repository running Mercurial
until Python moved to GitHub in January 2017.
See Python's public releases come in three types,
distinguished by which part of the version number is incremented.
Backward-incompatible versions, where code is expected to break and needs to be,
be manually ported. The first part of the version number is incremented. These releases happen infrequently.
Version 3.0 was released eight years after 2.0. According to Guido Van Rasm, a version 4.0 is very
unlikely to ever happen. Major or feature releases are largely compatible with the previous version,
but introduce new features. The second part of the version number is incremented.
Starting with Python 3.9, these releases are expected to happen annually.
Each major version is supported by bug fixes for several years after its release.
Bug fix releases, which introduce no new features, occur about every three months
and are made when a sufficient number of bugs have been fixed upstream since the last release.
Security vulnerabilities are also patched in these releases.
The third and final part of the version number is incremented.
Many alpha, beta, and release candidates are also released as previews and for testing before final releases.
Although there is a rough schedule for each release, they are often delayed if the code is not ready.
Python's development team monitors the state of the code by running the large unit test suite during development.
The major academic conference on Python is PyCon.
There are also special Python mentoring programs such as PiLadies.
Python 3.12 removed WSTR, meaning Python extensions need to be modified,
and 3.10 added pattern matching to the language.
Python 3.12 dropped some outdated modules,
and more will be dropped in the future, deprecated as of 3.13.
Already deprecated array U format code will emit deprecation warning since 3.13
and will be removed in Python 3.16.
The W format code should be used instead.
Part of C-types is also deprecated,
an htteprver.cg.g.htp request handler
will emit a deprecation warning and will be removed in 3.15.
Using that code already has a high potential for both security and functionality bugs.
Parts of the typing module are deprecated,
e.g. creating a typing. named tuple class,
using keyword arguments to denote the fields and such, and more,
will be disallowed in Python 3.15.
Tools that can generate documentation for Python API include PiDoc,
available as part of the standard library,
Sphinx, P. Doc and its Forks, Doxygen, and GraphViz, among others.
