End Of Life For Python 2 – What’s Next?

Python version 2.0 was released in the year 2000. Two decades later, the developers of Python decided to sunset this version. According to them, the sole reason for ending this version is the need to make broader and more advanced changes to improve Python language. 

Now, this statement does not come as a surprise to the Python community. Back in 2014, Guido van Rossum, the creator of Python language and its principal author, announced ending further developments to Python version 2, and that Python 2.7 would be the last upgraded version. 

The developers of Python version 2 aborted improvements including bug reports, fixes, security check, updates and more. In one of our previous articles, we mentioned some of the interactive tools and resources that you can use to get help while migrating your code from Python 2 to Python 3.

The Reason For Ending Version 2

After releasing version 2, the Python team realized that they needed to make significant changes to improve Python – this is the primary reason to sunset Python 2. They wanted to help the Python user community by improving the Python language in a faster manner. 

Even after launching Python 3 in 2006, developers continued to work in Python 2. This, in retrospect, slowed down the adoption of Python 3 and made it hard for the team to improve the language. 

The developers were focussing on certain improvements which were not possible in Python 2 and since the developers were spending most of their time fixing bugs and security checks for Python 2, the team could not focus on the development of Python 3. 

According to a post, the developer and maintenance team of Python stated that as of January 1 2020, Python 2 is no longer supported. They added, “That means that we will not improve it anymore after that day, even if someone finds a security problem in it. You should upgrade to Python 3 as soon as you can.”

The Special Release

On April 20, Benjamin Peterson, release manager of Python 2.7, released the final update of Python 2, which is Python 2.7.18. Peterson called it a “Special Release” and mentioned that a less transcendent property of Python 2.7.18 is that it is the last Python 2.7 release and therefore, the last Python 2 release. 

He added, “I refer, of course, to the fact that “2.7.18” is the closest any Python version number will ever approximate e, Euler’s number. Users still on Python 2 can use e to compute the instantaneously compounding interest on their technical debt.” 

Reason To Migrate to Python 3

According to the team of Anaconda, there are several important factors in Python 3 which need to be understood by the developers to migrate to it as soon as possible. Anaconda is the standard platform for Python data science that is leading to open-source innovation for machine learning. 

The reasons to migrate are mentioned below:

  • If you are building a new project from scratch. However, if your project is built on Python 2, then as long as your project is stable and reliable without any security concerns, you can carry on with Python 2.
  • If the project relies heavily on features that are different in Python 3. For instance, in Python 3, there will be a lot of changes in how strings are handled, making Unicode strings the default. These changes provide better support for accented characters, foreign languages, etc. If your current application depends on robust handling of international characters, then you need to think seriously about migrating into Python 3 only. Otherwise, it will be a lot harder to maintain code that works on both versions.
  • If your project relies on popular packages like Scikit-learn, which have already announced plans to drop Python 2 support.
  • Most importantly, if you are concerned about security vulnerabilities.

Download our Mobile App

Ambika Choudhury
A Technical Journalist who loves writing about Machine Learning and Artificial Intelligence. A lover of music, writing and learning something out of the box.

Subscribe to our newsletter

Join our editors every weekday evening as they steer you through the most significant news of the day.
Your newsletter subscriptions are subject to AIM Privacy Policy and Terms and Conditions.

Our Recent Stories

Our Upcoming Events

3 Ways to Join our Community

Telegram group

Discover special offers, top stories, upcoming events, and more.

Discord Server

Stay Connected with a larger ecosystem of data science and ML Professionals

Subscribe to our Daily newsletter

Get our daily awesome stories & videos in your inbox
How Generative AI is Revolutionising Data Science Tools

How Generative AI is Revolutionising Data Science Tools

Einblick Prompt enables users to create complete data workflows using natural language, accelerating various stages of data science and analytics. Einblick has effectively combined the capabilities of a Jupyter notebook with the user-friendliness of ChatGPT.

Intel Goes All in on AI

Pat Gelsinger said, there are three types of chip manufacturers, “you’re big, you’re niche or you’re dead”