Windows: Bug in Interpreter Path Handling
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 1.9k
- Forks
- 114
- PR merge metrics
- No merged PRs in 30d
Description
I am using shiv to create .pyz files for easy Python code execution on Windows. My usage is like this:
shiv --site-packages dist --compressed -p 'py -3.9' -o myapp.pyz -e myapp.main
For some reason, I am having issues with this now on Windows 11 with the newest python version / python launcher installed (Python Launcher for Windows Version 3.12.0):
C:\Users\Me\Downloads>myapp.pyz
Unable to create process using 'C:\Users\Me\Downloads\py -3.9 "C:\Users\Me\Downloads\myapp.pyz" ': The system cannot find the file specified.
Any help or direction with this would be greatly appreciated as I am not sure what to make of this. It seems like the path to the interpreter is prefixed with the current directory. Can I stop this from happening?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the shiv CLI handling of the -p 'py -3.9' interpreter value and reproduce the command on Windows 11. Trace how that value is combined with the generated myapp.pyz path; done when the interpreter is invoked without the current directory being prefixed and the .pyz executes successfully.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- cli
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100