• You MUST read the Babiato Rules before making your first post otherwise you may get permanent warning points or a permanent Ban.

    Our resources on Babiato Forum are CLEAN and SAFE. So you can use them for development and testing purposes. If your are on Windows and have an antivirus that alerts you about a possible infection: Know it's a false positive because all scripts are double checked by our experts. We advise you to add Babiato to trusted sites/sources or disable your antivirus momentarily while downloading a resource. "Enjoy your presence on Babiato"

Python 3.8, 3.9 or 3.10 for new projects?

craigburmr

New member
Banned User
May 5, 2022
20
1
3
Basically, I deploy on Ubuntu server 20.04 which ships with python 3.8. I developed Python apps using Linux/macOS. Currently, it's 3.9 on macOS. How to Downgrade Python 3.10 to 3.9 was just released days ago and claimed to be 10% faster than Python 3.9. (I use the Python framework Django/Flask/Tornado mostly)

Which version for a new project is better and why? Thanks
 
Last edited:
I'm sticking with 3.9 for time being. Not going to use any incompatible syntax/language constructs in my apps for the next 3 years. In my humble experience, backwards compatibility is far more important than using nice syntactic sugars du jour... especially if you'll have to revisit and support an app after a few years...

Get a list of installed python binaries:
Bash:
ls /usr/bin/python*

Then set the alias in your .zsrhrc/.bashrc profile:
Bash:
alias python3=python3.9

Alternatively, you can use update-alternatives to choose the version you want...

create the alternatives:
Bash:
# sudo update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.9 1
# sudo update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.10 2
Then choose the version:
Bash:
# sudo update-alternatives --config python3
 
AdBlock Detected

We get it, advertisements are annoying!

However in order to keep our huge array of resources free of charge we need to generate income from ads so to use the site you will need to turn off your adblocker.

If you'd like to have an ad free experience you can become a Babiato Lover by donating as little as $5 per month. Click on the Donate menu tab for more info.

I've Disabled AdBlock