[Bug 1225660] New: python311-pip package installs in /usr/lib by default
https://bugzilla.suse.com/show_bug.cgi?id=1225660 Bug ID: 1225660 Summary: python311-pip package installs in /usr/lib by default Classification: openSUSE Product: openSUSE Tumbleweed Version: Current Hardware: Other OS: Other Status: NEW Severity: Normal Priority: P5 - None Component: Python Assignee: python-maintainers@suse.com Reporter: daniel.garcia@suse.com QA Contact: qa-bugs@suse.de Target Milestone: --- Found By: --- Blocker: --- In tumbleweed installing a package with pip3 as root installs in the system path /usr/lib. It should install in /usr/local/lib instead. Possibly related to this patch: https://build.opensuse.org/projects/devel:languages:python:Factory/packages/... -- You are receiving this mail because: You are on the CC list for the bug.
https://bugzilla.suse.com/show_bug.cgi?id=1225660
Matej Cepl
https://bugzilla.suse.com/show_bug.cgi?id=1225660
Daniel Garcia
https://bugzilla.suse.com/show_bug.cgi?id=1225660
https://bugzilla.suse.com/show_bug.cgi?id=1225660#c1
Daniel Garcia
https://bugzilla.suse.com/show_bug.cgi?id=1225660
https://bugzilla.suse.com/show_bug.cgi?id=1225660#c2
--- Comment #2 from Daniel Garcia
I've been working in an initial implementation of this with two patches, one for the python interpreter and another one for the python-pip
Maybe it's easier to do it just in the pip code, using the "prefix" argument: # pip installations by default to local if prefix is None and scheme_name == "posix_prefix" and "RPM_BUILD_ROOT" not in os.environ: prefix = "/usr/local" https://build.opensuse.org/projects/home:dgarcia:usr-local/packages/python-p... -- You are receiving this mail because: You are on the CC list for the bug.
https://bugzilla.suse.com/show_bug.cgi?id=1225660
https://bugzilla.suse.com/show_bug.cgi?id=1225660#c3
--- Comment #3 from Matej Cepl
I've been working in an initial implementation of this with two patches, one for the python interpreter and another one for the python-pip:
* python311: https://build.opensuse.org/projects/home:dgarcia:usr-local/packages/ python311/files/bsc1225660-add-local-posix-path-scheme.patch?expand=1
Is this supposed to replace https://build.opensuse.org/projects/home:dgarcia:usr-local/packages/python31... or is it building on the top of it? -- You are receiving this mail because: You are on the CC list for the bug.
https://bugzilla.suse.com/show_bug.cgi?id=1225660
https://bugzilla.suse.com/show_bug.cgi?id=1225660#c4
--- Comment #4 from Daniel Garcia
(In reply to Daniel Garcia from comment #1)
I've been working in an initial implementation of this with two patches, one for the python interpreter and another one for the python-pip:
* python311: https://build.opensuse.org/projects/home:dgarcia:usr-local/packages/ python311/files/bsc1225660-add-local-posix-path-scheme.patch?expand=1
Is this supposed to replace https://build.opensuse.org/projects/home:dgarcia:usr-local/packages/ python311/files/F00251-change-user-install-location.patch?expand=1 or is it building on the top of it?
It's on top of it. This is just for the "pip" installation. The F00251 is for packages installed using distutils directly. We don't have this patch in python312 because distutils was removed from cpython now, and now the way to install packages is using pip, so I think that patching pip could be enough. Maybe it could be also good to patch _distutils in the python-setuptools package. -- You are receiving this mail because: You are on the CC list for the bug.
https://bugzilla.suse.com/show_bug.cgi?id=1225660
https://bugzilla.suse.com/show_bug.cgi?id=1225660#c5
--- Comment #5 from Daniel Garcia
https://bugzilla.suse.com/show_bug.cgi?id=1225660
https://bugzilla.suse.com/show_bug.cgi?id=1225660#c6
--- Comment #6 from Daniel Garcia
participants (1)
-
bugzilla_noreply@suse.com