-
Notifications
You must be signed in to change notification settings - Fork 34
[windows-11-arm] Install native arm64 Python #85
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
For whoever reviews this issue, I just want to point out that the python.org release of Python for Windows ARM64 is experimental so that you can put it in this image, not so that you'll ignore it. We want regular users to ignore it for now, but tools and package developers should be testing and building with it. The worst thing that could happen is if a million school children start installing it on their new laptops and all the library developers are caught by surprise. That's why it's experimental. |
The whole If I want to use x86 Python I can use native x86 image... |
It depends on what you're doing. If Python is just part of your build process for a C++ app, then you probably don't care about the architecture, but you want one that's going to have precompiled wheels available. If you're actually doing a Python project, then yeah, you probably want a native ARM build by default. Which is why I agreed with you that it should be on there (I'm just preempting a disagreement that I've heard over the last few years of trying to grow adoption of the ARM64 builds). |
@zooba Actually, I'm using conan for building and this does cause issues. Because if the host is different than the build target it might use a different build routine (to build native binaries for tools required in building itself), this is the case with LLVM / DXC (DirectX Shader Compiler) and does actually add build time and might not always work. It'd be very nice if python was arm64 so that conan would know during build time that this is an arm64 system trying to build for arm64, so it doesn't have to do any duplicate work or build for the wrong target. |
Sure, I accept that this is a genuine issue (and again, I'm not arguing against putting ARM64 Python on these machines, but I'm arguing for it, which would help you). However, the underlying cause is that Conan (apparently, based on your description) needs some way to tell it what the target platform should be, so that it doesn't have to guess. If it knew (perhaps because you provided a setting) that the target was ARM64, it could select things properly and make sure that it builds the right thing. |
yes, I also provide it that setting, the problem is that there'll be a mismatch between the host and the build so it spends more time because it has to also build the native binaries alongside the target (because it has to run these binaries on the host to build for the target) |
ARM64 Python is available since Python 3.11, so add specs for 3.11-3.13 Use actions/setup-python to avoid using the host Python (3.9 currently on windows-2022) since the arm image doesn't have a native Python atm (see actions/partner-runner-images#85) and cibuildwheel warns that it will require 3.11 with v3, so might as well bump it for everything. Also adds one arm64 build to the default matrix setup, since the separate image makes it different enough to warant testing on PRs imo. Fixes python-cffi#109
ARM64 Python is available since Python 3.11, so add specs for 3.11-3.13 Use actions/setup-python to avoid using the host Python (3.9 currently on windows-2022) since the arm image doesn't have a native Python atm (see actions/partner-runner-images#85) and cibuildwheel warns that it will require 3.11 with v3, so might as well bump it for everything. Also adds one arm64 build to the default matrix setup, since the separate image makes it different enough to warrant testing on PRs imo. Fixes python-cffi#109
ARM64 Python is available since Python 3.11, so add specs for 3.11-3.13 Use actions/setup-python to avoid using the host Python (3.9 currently on windows-2022) since the arm image doesn't have a native Python atm (see actions/partner-runner-images#85) and cibuildwheel warns that it will require 3.11 with v3, so might as well bump it for everything. Also adds one arm64 build to the default matrix setup, since the separate image makes it different enough to warrant testing on PRs imo. Fixes python-cffi#109
I want to point out how important this is. If you run $ python -c "import sys; import platform; print(sys.platform); print(platform.machine())"
win32
AMD64 Meaning your code-path would likely not work as intended. But if you add |
This result is a bit concerning... it means WMI (which is the authoritative system for getting OS information) isn't working, and so Python is having to fall back on the We aren't seeing errors here in our (Python's) CI - could you run |
Or it means "python" is an old version. We wouldn't suggest trying to use Python 3.12 or earlier on ARM64 - there are builds, but not every fix has made it in. So 3.13 is roughly where it can reliably start from. |
You can see in the first posts, what versions of Python are available, this is output directly from the image. |
The first post doesn't tell me which one |
Fair, my point was that the newest available seems to be 3.12, which is below recommended by you 3.13.
|
Thanks. And yeah, unfortunately the reason for We definitely don't want Python developers relying on the default I believe |
Thank you all for your patience. We are adding python 3.11 through 3.14 arm native builds to the image in addition to updating the x64 version of python that is available on the image. We plan on making the new image available in the next couple weeks and will update the issue here once it's published. |
Type of issue
Describe the issue
Python installed in
windows-11-arm
is x86_64 and emulated.To Reproduce
Expected behavior
There should be ARM64 version available. For example
Desktop (please complete the following information):
windows-11-arm
The text was updated successfully, but these errors were encountered: