When using a Python interpreter installed in a path that exceeds 127 characters installed scripts will have a shebang of the following form:
#!/bin/sh '''exec' /some-very-long-path-to-your-python-interpreter-that-exceeds-127-characters/foooooooooooooooooooooooooooooobar/bin/python3.12 "$0" "$@" ' '''
instead of the normal
#!/some-short-path/bin/python3.12
pathfix fails to fix the form for long paths and leaves it unchanged.
Thank you for the report. It took me a while to understand what is happening here. After many years of usage of this tool, we've never encountered an issue like this, but if you want to implement handling of those special shebangs, I'll review a PR.
Activity
frenzymadness commented on Feb 24, 2026
Thank you for the report. It took me a while to understand what is happening here. After many years of usage of this tool, we've never encountered an issue like this, but if you want to implement handling of those special shebangs, I'll review a PR.