3 ms·
Written more Python than I'd like, and I still hate + avoid venvs. They're purely incidental complexity: it should be able to set up a project-local venv by th
by mattgreenrocks 4y ago
Written more Python than I'd like, and I still hate + avoid venvs.
They're purely incidental complexity: it should be able to set up a project-local venv by themselves without me having to micromanage anything. I don't care about activating/deactivating venvs. It should just work when I navigate to the project folder. It should let me tweak where packages are stored for the 1% of the time that I care.
- radicalbyte 4y agoIt always seems so backwards to me when I use Python... and kinda crazy to see in a "beginner" language.
- throwaway894345 4y agoI've always felt that it's weird that Python is considered a "beginner" language. Yeah, it uses "and" instead of "&&", but it took me a loooonnng time to figure out how to manage dependencies when I was starting out (and then figuring out how to deploy to targets, how to do reproducible builds, etc). Compared with Rust or Go which just do the right thing by default (personally I've always felt that the tooling is the way more important problem than language concepts which often feel like bike shedding to me).
- radicalbyte 4y agoI also despair that it's used as a beginner language. There are so many better options. I even include Java in that list. So why is it used? As it has a fantastic eco-system for applied statistics / machine learning / various math things. If you're teaching an introduction to programming then it's a very effective language. That and once people progress it's decent - much prefer the code written in Python by competent developers to that written in Java or even Go. It also sets people up to use more robust languages such as C# or (for those with a Math background) Haskell.
- bitcurious 4y ago>It should just work when I navigate to the project folder. You still need to do the setup when you create the project, but once you do you can use direnv[0] to activate/deactivate the venv[1]. I target GCP often, so I have direnv switch over to the correct project [3] also. [0] https://direnv.net/ https://direnv.net/ [1] https://stackabuse.com/managing-python-environments-with-direnv-and-pyenv/ https://stackabuse.com/managing-python-environments-with-dir... [2] https://stackoverflow.com/questions/56781493/gcloud-is-it-possible-to-change-the-default-project-based-on-the-current-folder https://stackoverflow.com/questions/56781493/gcloud-is-it-po...