Close Menu
  • Home
  • Crypto News
  • Tech News
  • Gadgets
  • NFT’s
  • Luxury Goods
  • Gold News
  • Cat Videos
What's Hot

Whoop Will Soon Offer Users In-App Video Consultations With Licensed Clinicians

May 10, 2026

Funniest Cats and Dogs Clips 2026😼🐶Try Not To Laugh😜 Part 6

May 10, 2026

Dua Lipa Is Suing Samsung For $15 Million

May 10, 2026
Facebook X (Twitter) Instagram
  • Contact Us
  • Disclaimer
  • Privacy Policy
  • Terms of Use
  • DMCA
Facebook X (Twitter) Instagram
KittyBNK
  • Home
  • Crypto News
  • Tech News
  • Gadgets
  • NFT’s
  • Luxury Goods
  • Gold News
  • Cat Videos
KittyBNK
Home » Python 3.12 new features explained
Gadgets

Python 3.12 new features explained

September 30, 2023No Comments3 Mins Read
Facebook Twitter Pinterest LinkedIn Tumblr Email
Python 3.12 new features explained
Share
Facebook Twitter LinkedIn Pinterest Email

The latest stable release of the Python programming language Python 3.12, is set to be released on October 2, 2023. This new version brings a host of changes and improvements, including enhanced error messages, performance upgrades, the introduction of Immortal objects and sub interpreters, changes to F strings, modifications related to types and type annotations, the removal of certain modules, and improvements in type implementations.

One of the most notable changes in Python 3.12 is the improvement in error messages. The new version offers smarter error messages, providing more explicit recommendations for common errors. Modules from the standard library are now suggested as part of the error messages, making it easier for developers to troubleshoot and resolve issues.

Performance improvements are another key feature of Python 3.12. While the leap in performance may not be as significant as the one from Python 3.10 to Python 3.11, there are still notable enhancements. For instance, comprehension inlining has been introduced, which can speed up the execution of comprehension up to two times in some benchmarks. The asyncio package has also seen a number of performance improvements, with some benchmarks showing a 75% speed up.

Python 3.12

Python 3.12 introduces the concept of Immortal objects. These are objects that are always needed by the system and therefore have a constant reference count. This new feature can help improve the efficiency and performance of Python programs.

Another significant addition in Python 3.12 is the introduction of sub interpreters. Each sub interpreter has its own Global Interpreter Lock, enabling Python to better utilize multiple CPU cores. This feature can significantly enhance the performance of Python programs, especially those that are designed to take advantage of multi-core processors.

 

Other articles you may find of interest on the subject of Python :

New Python features

F strings in Python 3.12 have also seen some changes. They have become less finicky, allowing for nested double quotes. This change can make it easier for developers to write and read code that uses F strings. Python 3.12 also brings changes related to types and type annotations. The new version introduces the override keyword and a new syntax for type parameters or generic classes and functions. These changes can make it easier for developers to write code that is more robust and easier to understand.

The pathlib module now has a walk method, allowing for the exploration of directory trees. This new feature can make it easier for developers to work with file systems in their Python programs. Python 3.12 also supports the ability to monitor calls, returns, lines, exceptions, and other events using instrumentation. This feature can be very useful for debugging and performance tuning.

However, Python 3.12 is not just about additions and improvements. Several modules have been removed in this version, including async ads and asyncore, which have been replaced by async IO. Deprecated aliases from the unit test package have also been removed.

Python 3.12 brings a host of changes and improvements that can make it easier for developers to write robust, efficient, and readable code. Whether you are a seasoned Python developer or a beginner, it is worth taking the time to familiarize yourself with these new features and changes.

Filed Under: Technology News, Top News





Latest Geeky Gadgets Deals

Disclosure: Some of our articles include affiliate links. If you buy something through one of these links, Geeky Gadgets may earn an affiliate commission. Learn about our Disclosure Policy.


Credit: Source link

Share. Facebook Twitter Pinterest LinkedIn Tumblr Email

Related Posts

The Creaseless Galaxy Z Fold 8 Arrives This July

May 10, 2026

Xbox Confirms Halo 2 and 3 Remakes Alongside Project Helix

May 10, 2026

Apple Watch Ultra 4 Leaks: Slimmer Design and Touch ID

May 10, 2026

ChatGPT 5.5 Instant Review: The Good, The Bad, and The Insane

May 10, 2026
Add A Comment
Leave A Reply Cancel Reply

What's New Here!

10 Tricks & Tips to Improve ChatGPT-4o Prompts

May 19, 2024

Samsung Galaxy Book4 Edge AI Laptop Launched

May 21, 2024

Google opens its AI-generated search experience to teens

September 28, 2023

Garmin Index Sleep Monitor: Features, Benefits, and More

June 22, 2025

Cardano vs Option2Trade – Why O2T dominates altcoin since Jan 2024?

April 29, 2024
Facebook X (Twitter) Instagram Telegram
  • Contact Us
  • Disclaimer
  • Privacy Policy
  • Terms of Use
  • DMCA
© 2026 kittybnk.com - All Rights Reserved!

Type above and press Enter to search. Press Esc to cancel.