Re:Apple removes Python 2.7 in macOS 12.3 beta
by ArchOversight on Friday January 28, 2022 @12:12PM
(#30117466)
You can easily set your $PATH so that your preferred tooling is first in the search order.
[ Parent
| on HN ]
Re:Apple removes Python 2.7 in macOS 12.3 beta
by ninkendo on Friday January 28, 2022 @12:35PM
(#30117785)
There's a bunch of places that can still get tripped up:
- scripts with `#!/usr/bin/python` instead of `#!/usr/bin/env python`
- shell scripts which call /usr/bin/python directly instead of the one in your path
- shell scripts which intentionally set a prefix in $PATH to some vendor directory with a custom python, but the vendoring is incomplete and leaky and it implicitly loads packages from your system python anyway
plus a hojillion other things I'm not thinking of...
Re:Apple removes Python 2.7 in macOS 12.3 beta
by tsimionescu on Friday January 28, 2022 @04:59PM
(#30120982)
But scripts calling /usr/bin/python want to use the "system" / "bundled" Python - why would you want those to run with your version of Python???
Re:Apple removes Python 2.7 in macOS 12.3 beta
by kroltan on Friday January 28, 2022 @05:39PM
(#30121453)
Because in 120% of situations, that "want" is actually "I had no clue how *nix works and just pasted in the result of `which python` in my system".
Re:Apple removes Python 2.7 in macOS 12.3 beta
by tsimionescu on Friday January 28, 2022 @05:43PM
(#30121489)
Do you think the same is true of #!/bin/bash? Why not?