Skip to content

Handle spaces and long paths in Python shebangs - #39

Open
jezdez wants to merge 2 commits into
python:mainfrom
jezdez:fix-python-shebangs
Open

jezdez wants to merge 2 commits into
python:mainfrom
jezdez:fix-python-shebangs

Conversation

@jezdez

@jezdez jezdez commented Oct 22, 2026

Copy link
Copy Markdown

Builds on #37, which should merge first.

CPython's generated launchers fail when their interpreter path contains spaces or exceeds the shebang length limit. Use a short /bin/sh trampoline to execute the destination interpreter and forward the original arguments without relying on PATH.

Only the argument-free Python shebangs generated by CPython are rewritten.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant