-
Notifications
You must be signed in to change notification settings - Fork 3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
System setuptools leaks into isolated build environment #11430
Comments
I explicitly state that I DO NOT AGREE with being forced to agree with the PSF Code of Conduct to submit this issue. I ticked the box just because I cannot continue otherwise. I hope this requirement for issue submission is an oversight. If not, please close this issue and ignore my report. PS: I already had this discussion within the setuptools project and added this clarification upon reporting an issue. Eventually, setuptools stop requiring people to agree to the CoC and changed it with an admonition remembering reporters that they are expected to follow the CoC. |
Hi, Thanks for the detailed report! Would you mind trying the same with pip 22.1.3? |
I don't see a pip 22.1.3 release on PyPI, nor a 22.1.3 tag in the git repository. I've tried 22.1.2, same issue as reported above. |
Thanks. I can reproduce with the system python on Ubuntu 20. Within a virtualenv this seems to be correct, which probably explains why it has not been detected before. |
Yep, if using virtualenv, everything looks OK. |
Ok, thanks. That's going to be... interesting to debug :/ |
There's an open issue for this somewhere already FWIW. |
It's the same class of problems as #6264 -- we're adding system paths in the virtual environment, with Debian/Ubuntu Python because of their patches (IIUC). |
@pradyunsg Note I'm running Fedora 36, though. They do add some patches related to user site-packages (the place where I have my pip installed), but I do not believe these patches is the source of this issue. |
Hmm... It might still be the same root cause though; wherein the isolation is adding a system path when it shouldn't. Can you share the output of |
And, does this failure also happen with non-editable installations? |
It's not an oversight. Making users explicitly opt in is an intentional choice. Regardless of what you say, you're expected to follow the PSF CoC while interacting in this project's online spaces (and setuptools'). If you violate the CoC in your interactions here at any point, we'll take action according to the CoC as well. If you have concerns around that, you're free to not interact with the project. :) |
Yes, I do have concerns.
Well, if that's your attitude, then I'm very sorry. @jaraco I wrongly assumed that all this matter was already sorted out. Now I realize your update applied only to setuptools, and not PyPA as a whole. Looks like any bug report that I make in good faith to any of the PyPA projects will require explaining my point over and over again, and have to swallow the usual "if you don't like it, you are free to go way". |
That's right - we're a loose-knit group with shared goals, but little standardized policy, which in most cases benefits the projects, but does mean that policies like these are largely uncoordinated. I'd prefer if other PyPA projects followed my lead, based on the discussion in that thread, but they're welcome to create the policies and associated friction as suits their maintenance style. |
For reference for those who don't know the thread being refereed to it's here: https://discuss.python.org/t/what-to-do-with-contributors-who-refuse-code-of-conduct/13287 And FYI pradyunsg, one of the Pip maintainers, already stated their opinion on keeping CoC agreement on the thread you are referring to: https://discuss.python.org/t/what-to-do-with-contributors-who-refuse-code-of-conduct/13287/12 Sorry for being off topic but I think this thread is confusing for anyone who doesn't have the context. |
Yep, I just tried (replacing "editable" with "wheel"), and the issue is still there, the old system setuptools is being used. |
Note: my |
Consolidating this into #6264. |
Description
My project uses a custom in-tree build backend that wraps
setuptools.build_meta
and its build-system hooks implementation. I'm trying to add support for editable installs. I'm running on a Fedora 36 box, and the system has setuptools 59 installed via the system package manager. Therefore, I request a higher setuptools version inpyproject.toml
. Looks likepip
actually installs the higher setuptools, but eventually the older one from the system is picked.Expected behavior
pip
should use the requested version of setuptools.pip version
22.2.2
Python version
3.10
OS
Fedora Linux 36
How to Reproduce
pyproject.toml
builder.py
Note the line
assert 0, f"{setuptools.__version__} {setuptools}"
inget_requires_for_build_editable()
!I need that line to easily show the root of the issue.
Output
Note the
AssertionError
line:I requested
"setuptools >= 64"
in my requirement, but the older system-wide setuptools is being used.The text was updated successfully, but these errors were encountered: