-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Provide a better error message when uninstalling packages without dis…
…t-info/RECORD Fixes pypa#8954
- Loading branch information
Showing
3 changed files
with
74 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
When pip is asked to uninstall a project without the dist-info/RECORD file | ||
it will no longer traceback with FileNotFoundError, | ||
but it will provide a better error message instead, such as:: | ||
|
||
ERROR: Cannot uninstall foobar 0.1, RECORD file not found. You might be able to recover from this via: 'pip install --force-reinstall --no-deps foobar==0.1'. | ||
|
||
When dist-info/INSTALLER is present and contains some useful information, the info is included in the error message instead:: | ||
|
||
ERROR: Cannot uninstall foobar 0.1, RECORD file not found. Hint: The package was installed by rpm. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters