4 ms·
MacOS (Certified Unix OS) is bundled with multiple OpenSource projects since it's initial OS X release, just like many other *nix OSes. It's so easy to install
by JiNCMG 5y ago
MacOS (Certified Unix OS) is bundled with multiple OpenSource projects since it's initial OS X release, just like many other *nix OSes. It's so easy to install your own version and override it that this is not an issue. Simple response... use brew.
- fbanon 5y ago>It's so easy to install your own version and override it that this is not an issue. It's easy to override it? Really? Don't forget that macOS comes with bash, zsh, ksh, tcsh... You have to override it in each of those!
- ArchOversight 5y agoYou can easily set your $PATH so that your preferred tooling is first in the search order.
- deleted 5y ago[deleted]
- ninkendo 5y agoThere'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...
- eproxus 5y agoGUI apps also have their own special $PATH set via launchctl.
- tsimionescu 5y agoBut scripts calling /usr/bin/python want to use the "system" / "bundled" Python - why would you want those to run with your version of Python???
- kroltan 5y agoBecause 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".
- tsimionescu 5y agoDo you think the same is true of #!/bin/bash? Why not?
- rovr138 5y agomacOS* I don’t get your point. Are you agreeing?
- Barrin92 5y agoyou should absolutely avoid overriding the default python installation if you're on a distribution that ships python2 by default in particular, because that is a good way to kill a good chunk of your system.
- erik_seaberg 5y agoEveryone should depend on “python3” or “python2”, never just “python”. They aren’t really the same language. python3 can’t run python2 scripts, nor vice versa, so no matter what you expected there will be systems on which you won’t get it.
- kortex 5y agoPSA: don't use brew to manage your development python, unless you like having the carpet pulled out from under you by brew deciding to change 3.8 to 3.9 on you. Use brew to install pyenv (or bootstrap it from github). Use pyenv to manage python versions, and then use a virtualenv. Or conda, if that is your jam. https://github.com/pyenv/pyenv https://github.com/pyenv/pyenv
- wyclif 5y agoYes, this is what I do now and since moving to pyenv I haven't had any real issues. The only glitch was that I have to upgrade pyenv from 2.2.3 to 2.2.4 and it just tells me 2.2.4 is already installed when I'm running 2.2.3. I'm guessing that's a homebrew thing?
- Doctor_Fegg 5y agoDon’t use brew to manage your development anything. Carpet-pulling is pretty much intrinsic to its design. “hey I upgraded openssl for you and trashed the old one, hope you hadn’t built anything against it!”