Python - What is new in version 3.13
blog post
Gary Owl  

Best Fixes and Features In New Python Version 3.13

Python 3.13.0 brings a number of interesting new features and improvements. Here are some of the most important new features:

Improved Interactive Interpreter

  • A new interactive interpreter based on the PyPy project has been introduced.
  • It supports multi-line editing so that entire blocks of code can be edited at once.
  • Color highlighting of syntax and tracebacks is now enabled by default.
  • New features such as paste mode (F3) and history browse mode (F2) improve usability.

Experimental Functions

  • An experimental free-threaded mode has been introduced which allows to disable the Global Interpreter Lock (GIL).
  • A preliminary, experimental Just-In-Time (JIT) compiler has been added, which lays the foundation for future performance improvements.

Improvements in Typing and Error Handling

  • Added support for default values in type parameters.
  • A new type constraint annotation typing. TypeIs has been introduced.
  • Error messages have been further improved, with traces highlighted in color.

Changes to the Standard Library

  • Several deprecated modules have been removed, including aifc, cgi, imghdr and others.
  • The dbm module has a new dbm.sqlite3 backend, which is used by default for new files.
  • The locals() function now has clearly defined semantics when changing the returned mapping.

Platform Support

  • WebAssembly with WASI is now an officially supported platform (Tier 2).
  • iOS and Android are now officially supported as Tier 3 platforms.

These additions are aimed at further improving the performance, usability and flexibility of Python. However, it is important to note that some of the features, especially the free-threaded mode and the JIT compiler, are still experimental and will be further optimized in future versions.

When was Python Version 3.13.0 released?

Version 3.13.0 was released on October 7, 2024. The release schedule was adhered to.

Does it make Sense to Upgrade already?

No. I advise the majority of users not to upgrade immediately after release. With the expected release of Python 3.13.1 (not before December 2024), an upgrade will make sense for the majority of users, as most packages should have been updated by then.

In large Python releases such as the current one, a longer transition period is to be expected until full compatibility is guaranteed again.

You can find more detailed information here:

https://docs.python.org/3/whatsnew/3.13.html

https://www.python.org/downloads/release/python-3130/

https://realpython.com/python313-new-features/

*This article will be updated on an ongoing basis