Closed
Description
Python scripts using #!/usr/local/bin/managed_python3
may fail to run as expected when called from a bash shell.
The following uses the "python_recommended_signed-3.12.1.80740.pkg" packaged release:
bash-3.2$ /usr/local/bin/managed_python3 -V
Python 3.12.1
bash-3.2$ cat test.py
#!/usr/local/bin/managed_python3
print("Hello, world!")
bash-3.2$ ./test.py
./test.py: line 2: syntax error near unexpected token `"Hello, world!"'
./test.py: line 2: `print("Hello, world!")'
I'm guessing this same issue occurs with the 3.11 package as well.
(Same script works fine when called from a zsh shell:)
bash-3.2$ zsh
% ./test.py
Hello, world!
Metadata
Metadata
Assignees
Labels
No labels