Re:The tragedy of running an old Node project
by fragmede on Wednesday November 20, 2024 @04:08AM
(#42192054)
> which means package resolution can't look first in a local subdir
Sure it can, it's just a matter of examining where it's being run from.
I wrote python-wool to load packages from a venv if it finds one.
Re:The tragedy of running an old Node project
by regularfry on Wednesday November 20, 2024 @07:14AM
(#42193196)
Yep. That comes under the category of "not default". Although now you've pointed it out I'll probably be using it.
There are a load of scripts with `#!/usr/bin/python` (or similar) in `/bin`, which means package resolution can't look first in a local subdir otherwise all bets are off. Again: your system will break depending on which directory you run bits of it from. The system-provided process would be loading dependencies that it was not tested against. In case this is unclear, you do not want that to happen. It would be bad. On my system I can see python scripts involved in driver management. I do not want them to do unexpected things. It would be bad.
Python package management is a mess in lots of ways, but this particular choice isn't one of them.