News for hackers. Stuff that matters.
Re:Conda: A Package Management Disaster? by wakawaka28 on Thursday December 19, 2024 @11:52PM (#42468381)
Beginners in Python typically don't need venvs. They can just install a few libraries (or no libraries even) to get started. If you truly need venvs then you're either past the initial learning phase or you're learning how to run Python apps instead of learning Python itself.

For some libraries, it is not acceptable to stash the dependencies for every single toy app you use. I don't know how much space TensorFlow or PyQt use but I'm guessing most people don't want to install those in many venvs.

Re:Conda: A Package Management Disaster? by throwawaymaths on Friday December 20, 2024 @12:05AM (#42468426)
i remember reading somewhere (on twitter iirc) an amateur sex survey statistician who decided she needed to use python to analyze her dataset, being guided toward setting up venvs pretty early on by her programmer friends and getting extremely frustrated.
Re:Conda: A Package Management Disaster? by jazzyjackson on Friday December 20, 2024 @01:24AM (#42468765)
Was it aella? I don't know of any other sex survey statisticians so I'm assuming you mean aella. She has a pretty funny thread here but no mention of venvs: (non-musk-link https://xcancel.com/Aella_Girl/status/1522633160483385345)

  Every google for help I do is useless. Each page is full of terms I don't understand at *all*. They're like "Oh solving that error is simple, just take the library and shove it into the jenga package loader so you can execute the lab function with a pasta variation".
She probably would have been better off being pointed towards jupyter, but that's neither here nor there
Re:Conda: A Package Management Disaster? by wakawaka28 on Friday December 20, 2024 @02:49PM (#42474331)
Good grief there seems to be no getting away from that woman. One of my ex girlfriends was fascinated by her but to me she is quite boring. If she wasn't fairly attractive, nobody would care about her banal ramblings.
Re:Conda: A Package Management Disaster? by michaelmrose on Friday December 20, 2024 @02:15PM (#42473967)
Intelligent systems simply cache and re-use versions and do stash deps for every toy project without consuming space.

Also installing everything with pip is a great way to enjoy unexplainable breakage when a Doesn't work with v1 and b doesn't work with v2.

It also leads to breaking Linux systems where a large part of the system is python code. Especially where user upgrades system python for no reason.

Re:Conda: A Package Management Disaster? by wakawaka28 on Friday December 20, 2024 @02:45PM (#42474281)
If you install a package in a fresh environment then it does actually get installed. It can be inherited from the global environment but I don't think disparate venvs that separately install a package actually share the package files. If they did, then a command executed in one tree could destroy the files in another tree. I have not done an investigation to look into this today but I think I'm right about this.
Re:Conda: A Package Management Disaster? by michaelmrose on Friday December 20, 2024 @08:10PM (#42476699)
In better designed systems than python they do. To share them with python you need something with dedup. Eg BTRFS ZFS
Re:Conda: A Package Management Disaster? by wakawaka28 on Saturday December 21, 2024 @03:08PM (#42481924)
Python's venv design is not obviously unintelligent. It must work on all sorts of filesystems, which limits how many copies can be stored and how they can be associated. More advanced filesystems can support saving space explicitly for software that exploits them, and implicitly for everyone, but there is a cost to everything.