Python News

Python News: What's New From July 2023

by Kate Finegan Aug 07, 2023 community

It’s always a good month to be a Pythonista, but July 2023 really drove this point home! The release of a new Python 3.12 beta version and Cython 3.0 moved the language forward, and more change is on the way with the steering council’s announcement that a no-GIL CPython is in the works.

Development in the Python world is a collective effort, with big contributions coming not from only the core developers but also everyday programmers. Sharing ideas is key to innovation, and the Python Steering Foundation (PSF) is offering grants for virtual events where that kind of collaboration can happen.

With Python’s commitment to open-source development and community involvement, it’s no surprise that the PSF is a founding member of the new Open Policy Alliance (OPA).

Don’t have a swimming pool nearby? No worries—you’re about to dive headfirst into Python’s July news!

Final Python 3.12 Beta Version Released

If you’ve been following the development of Python 3.12, then you already know that it brings a lot of exciting capabilities to the table. These include better error messages, more intuitive f-strings, support for the Linux perf profiler, and more. You can check out all the developments in the changelog.

The stable release of Python 3.12 isn’t due out until October, but you can go ahead and start experimenting with the final beta version, Python 3.12.0b4, now. Installing a pre-release version and reporting issues to the Python bug tracker is a great way to contribute to Python. The more people who use the new version in its beta form, the more opportunities there are to find problems before the stable version’s release.

As the release announcement explains, this beta version has all the intended features, but changes and bug fixes may still occur as needed.

Cython 3.0 Out Now

If you’re reading this, then you’re probably already a fan of Python. Maybe you’re devoted to the Zen of Python and the beauty of PEP 8, and you understand why so many companies in the real world use Python. But maybe you’ve dipped a toe into C or C++ and have found yourself craving the speed of compiled machine code.

Then it’s time to meet Cython, a binding that allows you to compile Python code to C or C++. That means you get the speed of these languages with the convenience of Python!

The release of Cython 3.0 makes bringing the best of both worlds together even better. This new version has been in development for several years, starting with the release of Python 3.8 in 2019.

Major changes in this new version of Cython include:

  • No more support for Python 2
  • Support for Python features up to 3.12
  • Expansion of pure Python mode

The bit about pure Python mode is particularly exciting. Previously, you had to write in a hybrid of Python and C to get significantly faster code, which meant a steep learning curve. The new version addresses this weakness, which is great news. For more information or to try it out, visit Cython’s documentation.

No-GIL Python in the Works

A big change is coming to Python. On July 28, the steering council announced its intention to accept PEP 703 and make the global interpreter lock (GIL) optional.

Currently, CPython includes a GIL by default, which means that you’re limited to executing one thread at a time, regardless of how many CPU cores your computer has. PEP 703 details the problems that this can cause, particularly for programmers working in data science and scientific computing:

Python’s global interpreter lock makes it difficult to use modern multi-core CPUs efficiently for many scientific and numeric computing applications. (Source)

This can be a major problem for neural networks and machine learning programs in particular.

The current work to remove the GIL has been spearheaded by Sam Gross. He announced the project in October 2021, and presented the status of it at the Python Language Summit in April 2022 and April 2023. PEP 703, which describes the no-GIL proposal in detail, was created in January 2023.

The announcement of a probable no-GIL Python comes after the steering council found that core developers overwhelmingly supported making Python free-threaded:

Poll asking "Conceptually, do you think we should be actively looking to make Python free-threaded?" Results: 87% Yes, 13% No.
Image source

The timeline for making no-GIL Python the default is intentionally conservative, with an estimate of five-plus years for full implementation if everything goes as planned. This long runway gives the steering council and core developers ample time to ensure there are no backward-compatibility issues.

PSF Offers Virtual Event Grants

Are you planning a Python event? Does it facilitate access by being virtual or focusing on diversity and inclusion? If so, then you might be able to get some financial support from the Python Software Foundation (PSF) through its grant program!

You can apply for up to USD 2500 for larger virtual events, but you can also apply for smaller grants as needed. Sprints are fair game, and they can be a great way to get some work done on open-source software. For more information, check out the program overview, FAQs, and resources for virtual events.

Note that you need to apply for funding at least six weeks before your event. Good luck!

Conferences Connect Python Community

Maybe you’re not ready to host an event, but you enjoy going to conferences. Did you attend EuroPython from July 17 to 23 in Prague? If so, you’re part of a robust tradition, as the event’s home page explains:

We’re the oldest and longest running volunteer-led Python programming conference on the planet! (Source)

If you’d like another opportunity to connect with the Python community in Prague, then be sure to put PyCon CZ on your calendar for September 15 to 17. To get a feel for the conference, check out PyCon CZ’s Youtube channel.

Across the pond, SciPy brought together users of NumPy, Matplotlib, IPython, pandas, statistical libraries, and more from July 10 to 16 in Austin, Texas. While this year’s sessions aren’t available online yet, you can check out last year’s playlist to get a sense of the conference.

If those topics pique your interest, then you’d probably enjoy EuroSciPy. It’s happening from August 14 to 18, and it’s not too late to register. If you’re close to Basel, Switzerland, or want an escape to a beautiful river city, then you should sign up.

Open Policy Alliance Formed

The Python Software Foundation has joined forces with a dozen other nonprofit organizations to form the Open Policy Alliance (OPA), which will bring together stakeholders across the open-source ecosystem to inform public policy. In particular, the alliance aims to amplify underrepresented voices:

The OPA will focus on educating public policy makers on Open Source to inform their development and deliberation of new policy concepts. There are unintended consequences that come from a lack of understanding of how open collaboration works in practice. The OPA will address this as well as the historic absence of contribution from underrepresented groups. (Source)

One key area of concern is policy surrounding articial intelligence (AI). To that end, the Open Source Initiative (OSI) is getting ready to launch a Deep Dive webinar series with the goal of defining open-source AI. To get a better sense of what sorts of questions this series will explore, check out the recap of a recent stakeholder meeting.

What’s Next for Python?

Several new developments are on the horizon! The Open Policy Alliance (OPA) will help to shape policy surrounding open source, and the Python Steering Council aims to one day make no-GIL Python the default. You can speed up your Python with Cython 3.0, and you can put yourself on the bleeding edge by installing Python 3.12.0b4.

Maybe you’ll get a grant for a virtual event that will land you in a future edition of Python News! Do you have any ideas or want to find collaborators? Feel free to connect with your fellow programmers in the comments.

🐍 Python Tricks 💌

Get a short & sweet Python Trick delivered to your inbox every couple of days. No spam ever. Unsubscribe any time. Curated by the Real Python team.

Python Tricks Dictionary Merge

About Kate Finegan

Kate relishes a well-placed comma as Tutorial Editor for Real Python.

» More about Kate

Each tutorial at Real Python is created by a team of developers so that it meets our high quality standards. The team members who worked on this tutorial are:

Master Real-World Python Skills With Unlimited Access to Real Python

Locked learning resources

Join us and get access to thousands of tutorials, hands-on video courses, and a community of expert Pythonistas:

Level Up Your Python Skills »

Master Real-World Python Skills
With Unlimited Access to Real Python

Locked learning resources

Join us and get access to thousands of tutorials, hands-on video courses, and a community of expert Pythonistas:

Level Up Your Python Skills »

What Do You Think?

Rate this article:

What’s your #1 takeaway or favorite thing you learned? How are you going to put your newfound skills to use? Leave a comment below and let us know.

Commenting Tips: The most useful comments are those written with the goal of learning from or helping out other students. Get tips for asking good questions and get answers to common questions in our support portal.

Looking for a real-time conversation? Visit the Real Python Community Chat or join the next “Office Hours” Live Q&A Session. Happy Pythoning!

Keep Learning

Related Topics: community