简体   繁体   中英

Why is Colab still running Python 3.7?

I saw on this tweet that Google Colab move to Python 3.7 on February 2021. As of today however (January 2022), Python 3.10 is out, but Colab still runs Python 3.7.
My (voluntarily) naive take is that this is quite a significant lag.

Why are they not at least on Python 3.8 or even 3.9?
Is it simply to make sure that some compatibility criteria are met?

The only reason is they want to have the most compatible version of Python worldwide. Based on the Python Readiness report ( Python 3.7 Readiness ), version 3.7 supports almost 80.6% of the most used packages so far. Still, this coverage is 78.3% for version 3.8, 70.6% for version 3.9 and 49.7% for version 3.10 (as of March 29, 2022).

Frankly, if Python 3.6 was not in its EOL, they still used this version today. Lucky us, python.org decide to rid of versions below 3.7.

On the other hand, You can update the Python version in your Colab by running some Linux commands in the notebook. But the problem is that whenever you start a new notebook, google ignores the updates and will turn back to the original version.

The best action that google can take is to have options to select the python version. Because of this, I am not using Colab in most cases, especially when teaching Python to my students.

Update (January 12, 2023):

Now google Colaboratory supports Python 3.8.16 . After a long time, we see some improvement. But it's still outdated because the current version is 3.11.1 . Python Readiness report says 80.8% of most used packages support Python 3.8, and 30.6% support 3.11. But we know it comes from info on PyPi. In practice, this support is far more than what the package maintainer says in the repository. Many packages support 3.11, but they still mention the lower version of Python. The reason is the maintainer didn't have a chance to check and update their production yet.

You can use Python 3.10 with this notebook .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM