Do I have Python and if so do I need it?
I am running Sonoma 14.3.1
In Terminal when I type in: which python3
this comes up:
/usr/bin/python3
Does that mean this version of python is still on my macbook? Is it necessary? Thanks!
I am running Sonoma 14.3.1
In Terminal when I type in: which python3
this comes up:
/usr/bin/python3
Does that mean this version of python is still on my macbook? Is it necessary? Thanks!
HereNowBe wrote:
Does that mean this version of python is still on my macbook?
Actually no. It's a long, complicated story, as most things with Apple tend to be.
Is it necessary? Thanks!
Yes. It is part of the operating system and you can't remove it.
However, in spite of the name, this isn't actually Python. It is just a proxy app. If you try to run it, the operating system will first check to see if you actually have Python installed. If you do, then it runs Python as you would expect. If you don't have Python, it will ask if you want to download the Command Line tools so you can run Python. If this happens, you can just say no.
Note that there are several different command line tools that are actually proxies that work the same way. The most important one is probably the "git" tool, and perhaps "clang".
HereNowBe wrote:
Does that mean this version of python is still on my macbook?
Actually no. It's a long, complicated story, as most things with Apple tend to be.
Is it necessary? Thanks!
Yes. It is part of the operating system and you can't remove it.
However, in spite of the name, this isn't actually Python. It is just a proxy app. If you try to run it, the operating system will first check to see if you actually have Python installed. If you do, then it runs Python as you would expect. If you don't have Python, it will ask if you want to download the Command Line tools so you can run Python. If this happens, you can just say no.
Note that there are several different command line tools that are actually proxies that work the same way. The most important one is probably the "git" tool, and perhaps "clang".
Apple dropped the Python 2.7.16 distribution from macOS 12.3 and later. Python 3 has never been bundled with the operating system before, and not now with macOS 14.3.1.
The only way python3 gets into /usr/bin on Sonoma is by your installing Xcode 15, or separately, the command line tools for Xcode 15 — the latter also as a result of installing and running the homebrew package manager. It is a crippled Python3 distribution, and if you have never written a line of Python code, just pretend it is not there.
Well, you could invoke the python3 command, and see if Python is installed and functional.
Xcode has an older version of Python embedded.
Most other Python installs are performed manually, usually either using direct downloads from Python.org, or installed via Homebrew or such, or occasionally Munki or such.
I would strongly discourage efforts to modify or delete components installed by Apple with macOS, or similar efforts toward the components of installed Apple apps.
Whether you need to use Python for your own activities is your decision.
Thanks so much!
Much appreciated. Thank you for the guidance.
Do I have Python and if so do I need it?