Kind of. Python definitely has more legacy cruft, but also has an npm equivalent PEP 582 with a working example, pdm. I don't see how JS is better unless you include web browsers as distribution. It's mostly people thinking bare `pip install` is a reasonable way to add various applications to your system that complain about python packaging.
I'm not saying Python packaging doesn't suck, it definitely does. But so does JS and the mess that the npm ecosystem is makes working with it it much more painful.
> Python definitely has more legacy cruft, but also has an npm equivalent PEP 582 with a working example, pdm
That's part of the problem. Python has lots of things that cover lots of things, but nothing does everything.
> It's mostly people thinking bare `pip install` is a reasonable way to add various applications to your system that complain about python packaging.
It is reasonable in JS, and I think it should be. Having to worry about virtual environments is a pain, and having to learn new tools to avoid that is a pain too.
> I'm not saying Python packaging doesn't suck, it definitely does. But so does JS and the mess that the npm ecosystem is makes working with it it much more painful.
I don't think that's a good point. The JS ecosystem adapted quickly to TypeScript, while Python is lagging behind. Most of the new JS features are reasonable, and the backwards compatibility is top-notch. Meanwhile, Python is spending brain power on pattern matching and :=. JS is missing something like Django, but on the other hand Python has no React equivalent. All of that without mentioning speed or the fact that JS has multiple implementations that works very well with almost all the ecosystem.
It's not. Even if npm install -g happened to work for you, it's insane to rely on it. These language package managers have a purpose in isolated environments but are incapable of building reliable, modifiable and updatable systems on their own. It's a good thing pip fails quickly so people don't attempt this.