You are not logged in.
I've noticed that Python-based applications (i.e., things called from shell that happen to be implemented in Python) are often packaged in such a way that they write into the global Python site-packages. For example:
- certbot
- ansible
- ansible-lint
... and I suspect many more.
Installing these in their own, isolated virtual environments (e.g., using pipx) seems like it would be better practice, assuring that conflicts with other requirements could be avoided.
Has this been discussed before?
Offline
Yup, many times.
Usually triggered by conflicts between pacman-maintained stuff & maintained-by-other-package-manager stuff .
The consensus is that archlinux packages are intended to be used systemwide and should use systemwide folders .
Isolated virtual environments are great for users and should be maintained by users .
https://wiki.archlinux.org/title/Python … management and https://wiki.archlinux.org/title/Python … guidelines should help to give more insight.
Last edited by Lone_Wolf (2023-01-27 11:26:28)
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Offline
Thx.
I suspect one day a conflict between different pacman-maintained packages will surface, but *shrug*.
Cheers,
Offline
How could pacman-maintained packages conflict? The path includes the package name.
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
If all dependencies are installed through pacman, they won't. Never mind -- this makes sense to me now. Still not a _huge_ fan of having pacman-managed Python packages installed into the system site_packages; it's difficult to distinguish them from packages that were installed by pip.
Offline
Unless you only use pip for user installed packages.
Offline
Sure -- but that's something people have to learn (and then implement with eg PIP_REQUIRE_VIRTUALENV=true). Until then, this is a bit of a footgun just lying around.
Offline
AFAIK, pip defaults to user installs now, unless you override it.
Offline
Nothing about those concerns are in any way specific to python.
If one installs *any* software as root / system-wide bypassing pacman they're prone to run into conflicts.
The concern should not be with packaged files being placed in the system-wide site-packages directory, but only unpackaged files being placed there.
Last edited by Trilby (2023-01-30 04:01:07)
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline