-
Notifications
You must be signed in to change notification settings - Fork 3.1k
move_wheel_files fails on setuptools dependencies #4264
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
Comments
Um, well |
Hmm. The Distribution object that's created is a That explains why the issue only occurs when a pure sdist package is first installed (such as My first instinct is to see if we can adapt pip not to import setuptools and thus not monkeypatch the Indeed, when I apply this patch, the failure goes away:
I can imagine this change would cause failures in environments where setuptools is importable but not installed as pip sees it. To retain the existing behavior, one could I'd also be open to the possibility of removing the implicit monkeypatching of distutils, such that all setup scripts would would have to be updated to reference the setuptools objects directly or call the monkeypatching explicitly. There's a lot of unknowns and possibly intractable challenges in that scenario. What do you think about the patch above? Do late versions of pip need to detect and pass on an importable but not installed setuptools? Do you have any other ideas? |
Another less aggressive option would be for setuptools to expose a routine to unmonkeypatch distutils, and pip could call that after the import. Another option would be for pip to import the Distribution object before it has a chance to be monkeypatched and always use that. |
I don't think there is any reason they need to work if setuptools isn't "installed", at least not off the top of my head. |
… in-process. Fixes pypa#4264.
Is there an ETA on releasing a fix for this? This is heavily impacting our workflow. |
If you then try to use tox to run anything, it will
Rather annoying. Any chance of a release soon? |
This removes a workaround for issue [1] that has been closed. Certain packages would fail to downgrade due to this issue and were being removed from the requirements upper-constraints so that the downgrade would not happen. [1] pypa/pip#4264 Change-Id: I6bc421a3f283899a2403cab64cc75628946711bd
Uh oh!
There was an error while loading. Please reload this page.
Reported in pypa/setuptools#951, it appears that when upgrading or force-reinstalling setuptools dependencies, pip calls into pkg_resources to get package metadata, but since the package is currently uninstalled, the search for its metadata fails.
I haven't looked into the pip code, but I wanted to ask this project first: Can someone provide a brief explanation for what pip is doing here and if there's an adjustment that pip or pkg_resources could make to avoid the failure?
The text was updated successfully, but these errors were encountered: