Python platform on M1 confusion

Viewed 3188

Apologies if this is a dumb question, but after having some problems with python packaging I ran platform.machine() on my M1 Mac, expecting the output to be arm64 as I had seen online but instead got x86_64 which is the Intel processor. I just don't understand how this could be the case on this machine, so any explanation would be super helpful.

1 Answers

What python are you using? If you are on < Python 3.9, which is most likely, then the python interpreter is made for an x86 Intel Processor, which was translated using Rosetta 2. Now, there is no problem with having an x86 Python Interpreter, actually, it's probably best to not use the newest versions of Python, as there might be some errors.

If you go to the official python.org website, you can see there are two different downloads: One for the ARM Macbooks and another for the Intel Macbooks. You may have installed the Intel Download for Python 3.9.2, which is why you are getting this output.

Related