Notice: While JavaScript is not essential for this website, your interaction with the content will be limited. Please turn JavaScript on for the full experience.
...of Python that does not use Apple 8.5.9 Tk. This is an Aqua Cocoa Tk. Apple 8.5.7 This release is included in macOS 10.6. IDLE is known to hang or crash when used with the Apple 8.5.7 included in all versions of macOS 10.6.x. Because of this, we strongly recommend that you do not attempt to use Tkinter or IDLE with the Apple-supplied Python 2.6.1 in 10.6. Instead, install a newer version of Python that supports a newer version of Tk. This is an Aqua Cocoa Tk. How Python Chooses Which Tk L...
...Apples", "Peaches", "Pears", "Bananas"] >>> print [(i, f) for i in nums for f in fruit] [(1, 'Apples'), (1, 'Peaches'), (1, 'Pears'), (1, 'Bananas'), (2, 'Apples'), (2, 'Peaches'), (2, 'Pears'), (2, 'Bananas'), (3, 'Apples'), (3, 'Peaches'), (3, 'Pears'), (3, 'Bananas'), (4, 'Apples'), (4, 'Peaches'), (4, 'Pears'), (4, 'Bananas')] >>> print [(i, f) for i in nums for f in fruit if f[0] == "P"] [(1, 'Peaches'), (1, 'Pears'), (2, 'Peaches'), (2, 'Pears'), (3, 'Peaches'), (3, ...
Version: None
Released: Dec. 7, 2020
This is the first maintenance release of Python 3.9 Note: The release you're looking at is Python 3.9.1, a bugfix release for the legacy 3.9 series. Python 3.11 is now the latest feature release series of Python 3. Get the latest release of 3.11.x here. We've made 282 changes …
View Release Notes
...of this PEP, readers commented that there are two kinds of "settable" language features: those that are designed to eventually become the only option, at which time specifying use of them is not necessary anymore. The features for which the syntax of the "Back to the __future__" PEP 236, Back to the __future__ was proposed fall into this category. This PEP supports declaring such features, and supports phasing out the "old" meaning of constructs whose semantics has changed under the new featu...
...of additional examples of string interpolation may be found at Wikipedia. Now that background and history have been covered, let's continue on for a solution. New Syntax This should be an option of last resort, as every new syntax feature has a cost in terms of real-estate in a brain it inhabits. There is however one alternative left on our list of possibilities, which follows. New String Prefix Given the history of string formatting in Python and backwards-compatibility, implementations in...
...of some important invariants of types and instances. On the other hand, it makes sense to allow sharing some common behavior between a group of enumerations, and subclassing empty enumerations is also used to implement IntEnum. IntEnum A variation of Enum is proposed which is also a subclass of int. Members of an IntEnum can be compared to integers; by extension, integer enumerations of different types can also be compared to each other: >>> from enum import IntEnum >>> cla...
...of the highest profile open source projects that make heavy use of Python. Given the likely existence of large amounts of legacy code that lacks the kind of automated regression test suite needed to help support a migration from Python 2 to Python 3, there are likely to be many cases where reimplementation (perhaps even in Python 3) proves easier than migration. The key point of this PEP is that those situations affect more people than just the developers and users of the affected application: t...
...of Microsoft Installers (MSI). The package also exposes additional APIs to create cabinet files (CAB). The module is used to facilitate distutils to create MSI installers with the bdist_msi command. In the past it was used to create CPython's official Windows installer, too. Microsoft is slowly moving away from MSI in favor of Windows 10 Apps (AppX) as a new deployment model [3]. pipes The pipes module provides helpers to pipe the input of one command into the output of another command. The mo...
...of October 2020 and according to DistroWatch [1] most current BSD and Linux distributions ship with OpenSSL 1.1.1 as well. Some older releases of long-term support (LTS) and enterprise distributions have older versions of OpenSSL or LibreSSL. By the time Python 3.10 will be generally available, several of these distributions will have reached end of lifetime, end of general support, or moved from LibreSSL to OpenSSL. Other software has dropped support for OpenSSL 1.0.2 as well. For example, PyCA...
...of this PEP did a survey of third party libraries for dictionary merging which might be candidates for dict union. This is a cursory list based on a subset of whatever arbitrary third-party packages happened to be installed on one of the authors' computers, and may not reflect the current state of any package. Also note that, while further (unrelated) refactoring may be possible, the rewritten version only adds usage of the new operators for an apples-to-apples comparison. It also reduces the re...
...of JITted frames working in oProfile on Linux. Lowlights: No work yet invested in improving symbolization of JIT-compiled frames for Apple's Shark [20] or Microsoft's Visual Studio profiling tools. Some polishing still desired for oProfile output. We recommend using oProfile 0.9.5 (and newer) to work around a now-fixed bug on x86-64 platforms in oProfile. oProfile 0.9.4 will work fine on 32-bit platforms, however. Given the ease of integrating oProfile with LLVM [21] and Unladen Swallow [22],...
...of Python has been torn down then for __del__ methods and weakref callbacks to execute sanely. The most common symptom was a sequence of uninformative messages on stderr when Python shut down, produced by threads trying to raise exceptions, but unable to report the nature of their problems because too much of the sys module had already been destroyed. Patch #820195: object.__contains__() now returns True or False instead of 1 or 0. Extension modules Bug #852314: Fix return type of tkFileDia...
...offered by a number of Linux distributions (including Debian, Ubuntu, Fedora, Alpine and Android) as an alternative to the ASCII-based C locale. Some other platforms (such as HP-UX) offer an equivalent locale definition under the name C.utf8. Mac OS X and other *BSD systems have taken a different approach: instead of offering a C.UTF-8 locale, they offer a partial UTF-8 locale that only defines the LC_CTYPE category. On such systems, the preferred environmental locale adjustment is to set LC_CTY...
...of the email package. mimetools has been removed in favor of the email package. Patch #2849: Remove use of rfc822 module from standard library. Added C optimized implementation of io.StringIO. The pickle module is now automatically use an optimized C implementation of Pickler and Unpickler when available. The cPickle module is no longer needed. Removed the htmllib and sgmllib modules. The deprecated SmartCookie and SimpleCookie classes have been removed from http.cookies. The commands module has...
...of a TLS connection they will serve. Additionally, it allows implementations to opt-out of one or either side of the connection. For example, SecureTransport on macOS is not really intended for server use and has an enormous amount of functionality missing for server-side use. This would allow SecureTransport implementations to simply not define a concrete subclass of ServerContext to signal their lack of support. One of the other major differences to the current ssl module is that a number of f...
...of recursive functions and attribution of time spent to the wrong function. The code and documentation for the derived OldProfile and HotProfile profiling classes was removed. The code hasn't worked for years (if you tried to use them, they raised exceptions). OldProfile intended to reproduce the behavior of the profiler Python used more than 7 years ago, and isn't interesting anymore. HotProfile intended to provide a faster profiler (but producing less information), and that's a worthy goal ...
...of non-type-hint annotations in 3.6, full deprecation in 3.7, and declare type hints as the only allowed use of annotations in Python 3.8. This should give authors of packages that use annotations plenty of time to devise another approach, even if type hints become an overnight success. (UPDATE: As of fall 2017, the timeline for the end of provisional status for this PEP and for the typing.py module has changed, and so has the deprecation schedule for other uses of annotations. For the updated...
...of their choice, and ideally improve the situation. Following many rounds of proposals, discussion and refinement, the general consensus was clearly in favor of deprecating the legacy means of specifying a license, in favor of "one obvious way to do it", to improve the currently complex and fragmented story around license documentation. Not doing so would leave three different un-deprecated ways of specifying a license for a package, two of them ambiguous, less than clear/obvious how to use, inc...
...of the Python Software Foundation. Approved 10-0-0 on June 14, 2016 RESOLVED, that the Python Software Foundation appoint Lorena Mesa and Kushal Das as Communications Officers of the Python Software Foundation. Approved 10-0-0 on June 14, 2016 RESOLVED, that the Python Software Foundation appoint Kurt Kaiser as the Treasurer of the Python Software Foundation Approved 10-0-0 on June 14, 2016 RESOLVED, that the Python Software Foundation appoint Ewa Jodlowska as the Secretary of the Python Soft...