Core Python developers had a chaotic start to 2022, but they’re creating headway on making Python a faster language like C.
Liam Tung is a full-time freelance technology journalist who writes for several Australian publications.
The Python Software Foundation (PSF) has released three new versions of popular programming language Python in what has been a bumpy start to 2022, but Core Python developers are making progress on Python creator Guido van Rossum’s goal for version 3.11 to be twice as fast as its predecessor.
New versions for the Python 3.10, 3.9 and preview 3.11 series are out today and arrived in spite of numerous hold ups, including a “more complex than expected” code signing certificate renewal. Version 3.10.x is the latest feature release series of Python 3, while 3.9.x is the legacy series and Python 3.11.x is the future.
The best programming languages
Here’s a list of the most popular programming languages and where to learn them
“The releases you’re looking at were all cursed in some way. What a way to start 2022! Besides the certificate hold up, Python 3.10.2 is an expedited release (you’ll want to upgrade, read below!), Python 3.11.0a4 had almost 20 (sic, twenty!) release blockers before being finally green, and Python 3.9.10 was made from a new M1 Mac on macOS Monterey which made the usually boring process quite a ride,” the release team said.
SEE: The IT skills gap is getting worse. Here are 10 ways you can avoid a crisis
None of the new versions of Python – 3.10.2, 3.9.1, and 3.11.0a4 – contain Windows installers due to a certificate renewal issue. Despite this obvious gap, the Core Python (CPython) development team decided to release the new versions due to a serious memory leak issue affecting 3.10 and earlier that makes 3.10.2 “highly recommended” to install.
“We’ve held the releases all week while the situation is getting resolved but the urgency of 3.10.2 in particular made us release without the Windows installers after all,” explained Lukasz Langa, a CPython developer and release manager.
“We apologize for the inconvenience and are doing everything we can to put the Windows installer in place as soon as possible.”
CPython is the reference implementation of Python that other variants of Python are based on.
“The first three releases of 2022 were cursed! What is usually a pretty mundane and largely automated process, turned out to be three separate curveballs. Fortunately, we didn’t let ’em strike us out,” added Langa.
The certificate issue is being addressed by CPython developer Ee Durbin and Steve Dower, a Microsoft-employed Windows expert for CPython who is responsible for Windows installers.
PSF expects the certificate renewal and Windows installer issue to be fixed this week.
The memory leak affecting Python 3.10 occurred on certain function calls when developers use Cython, a superset of Python with a compiler that makes it easier to write extensions in C code that interact with Python code. Cython gives faster C-like performance to Python code execution.
“The memory leak consisted of a small constant amount of bytes in certain function calls from Cython code,” explains Langa. “Although in most cases this was not very noticeable, it was very impactful for long-running applications and certain usage patterns.”
CPython developer Pablo Galindo Salgado notes the memory leak fairly drastically affects Cython with one bug report implying that “every function call using __Pyx_PyCFunction_FastCall is leaking memory in 3.10, which is quite bad.” Bug reports indicated it was leaking megabytes of memory, making it worth fixing the bug urgently.
CPython developers determined the leak is in PyEval_EvalFrameEx, which is used by Cython rather than Python, but is only present in Python 3.10 and earlier, but not Python 3.11 and later.
The next Python 3.10 maintenance release will be 3.10.3 and is scheduled for release on April 4, 2022.
SEE: Want to get things done in tech? You’ll need these surprising new allies
Version 3.11.0a4 is the fourth of seven planned alpha releases for testing. Key changes for 3.11 include speed improvements outlined by Python creator Guido van Rossum at the PyCon 2021 conference. Now employed by Microsoft, van Rossum wants Python 3.11 to be twice as fast as 3.10. The Faster CPython Project is Microsoft’s way of giving back to the Python community, which has grown with the rising popularity of machine learning.
PyPerformance benchmarks run by The Faster CPython Project indicate CPython 3.11 is about 19% faster on the geometric mean than 3.10.0.
Other key improvements include:
Version 3.9.10 is the ninth maintenance release of the legacy 3.9 series. Python 3.9.10 contains 130 new commits. For macOS, the default installer is a Universal 2 binary that is compatible with Intel and and Apple’s Arm silicon.
Top programming languages: This coding favourite just topped the list again
Please review our terms of service to complete your newsletter subscription.