r/learnpython • • 11m ago

updating Python on macOS

How do you update Python on macOS? I looked it up and from what I can tell, there is no simple command you can enter into the terminal to update it, and you have to instead go to the website https://www.python.org/downloads/ and download and install it manually to update which is inconvenient. There's also the question of removing the old versions you have no intention of using anymore.

I am aware of Homebrew and I do have it for other things I've installed, but I want to try to only use it to download things to my MacBook that I otherwise couldn't. Python can easily be downloaded for mac separately and I want to keep it that way if possible. Is there no update command for the mac terminal to simply update Python?

1 Upvotes

3 comments sorted by

•

u/Classic_Mammoth_9379 7m ago edited 4m ago

Why are you setting arbitrary constraints for yourself? 

This is easy on most Linux distributions by using a package manager like yum or apt. 

The most popular package manager on macOS is homebrew and you’ve already got it installed. “brew upgrade python”.