python / python/cpython

Windows Python 3.12.7 64-bit (AMD64) fails to run on on Windows 11 ARM

Open
#125,872 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

type-bug
Dominant language
Python
Stars
77.2k
Forks
35.9k
PR merge metrics
PR metrics pending

Description

Bug report

Bug description:

Installing (AMD) 64-bit Python on Windows 11 ARM is not a problem, however on running python.exe this dialog pops up:


python.exe - Bad Image

C:\Users\Brecht Machiels\AppData\Local\Programs\Python\Python312\VCRUNTIME140.dll is either not designed to run on Windows or it contains an error. Try installing the program again using the original installation media or contact your system administrator or the software vendor for support. Error status 0xc000007b.

OK

Running py -V:3.12 returns no output, but exists with a 127 return code.

Renaming vcruntime140.dll and vcruntime140_1.dll that sit alongside python.exe fixes the issue.

The 32-bit version of Python 3.12.7 does not suffer from this issue.

For completeness: I'm running Windows 11 ARM on an M1 MacBook using UTM.

CPython versions tested on:

3.12

Operating systems tested on:

Windows

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the failure on Windows 11 ARM with the Python 3.12.7 AMD64 installer and compare it with the working 32-bit version. Check the bundled vcruntime140.dll and vcruntime140_1.dll behavior, including the reported DLL-renaming workaround; done means python.exe launches and py -V:3.12 reports the installed version without that workaround.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.