-
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
Improve error message when egg-link does not match installed location #10594
Conversation
Now this needs a news file and some fixes to satisfy checkers. |
I think this is worth listing as a feature, not trivial. |
This comment has been minimized.
This comment has been minimized.
Hmm... @pdegroote would it be OK if I pick this PR up and make CI be happy with it? |
Yes please! This is my first attempt at contributing to pip, and still need to learn the flow. |
Include the locations of the mismatched locations in the message, to provide more context.
Co-authored-by: Pradyun Gedam <[email protected]> Co-authored-by: Tzu-ping Chung <[email protected]>
Sure, happy to help! Here's what I've done to update this PR:
One suggestion: Make a new branch (like
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hi @pdegroote. This PR looks good!
Would you like to rebase this PR, or do you prefer to give us the chance to do it?
Improve error message when a pip package cannot be reinstalled after an egg link to a development package persists, but the original folder has been deleted.
This may help in finding the location of the egg link that needs to be manually removed by a user to solve the problem. It appears it only occurs in very specific situations, and maybe even only before PEP517. I encountered the issue in my company on our build server, but it wasn't trivial to reproduce it locally (I took an older version of Python and legacy pip option just to be sure, and I also couldn't have a toml file in the main directory). The following workflow reproduces the issue (but I'm not 100% sure what are the required steps, maybe some of the steps below allow variations). I tested it only on Windows 10.
"C:\Program Files\Python\python.exe -m pip install --user --no-use-pep517 -e .
"C:\Program Files\Python\python.exe -m pip install --user --no-use-pep517 -e .
I get the following error message:
The problem is that it is not clear where the conflicting egg link is located, which is particularly difficult when working from build accounts where user directories may not be directly clear.
For a description of the issue, see #10476 ( #10476. )