question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Name canonicalization issue in pip uninstall

See original GitHub issue

Environment

  • pip version: 20.1
  • Python version: 3
  • OS: Linux (probably irrelevant)

Description

pip uninstall should canonicalize names when determining if they are installed.

How to Reproduce

$ pip install zope-interface  # notice the dash
$ pip list
...
zope.interface  # notice the dot
$ pip uninstall zope-interface  # same name as in pip install
WARNING: Skipping zope-interface as it is not installed.

Expected result

In the example above, pip should have uninstalled zope.interface.

This is easily worked around when used manually, but is more annoying when the uninstall command is invoked by tools working with canonical names.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
sbidoulcommented, Jul 26, 2020

Ah, perfect. Thanks for investigating this @atugushev.

1reaction
McSinyxcommented, Jul 26, 2020

Please have my apologies: you are correct, I was testing on an venv and it uses pip’s latest release instead of the editable version. I can confirm that the problem is solved as of current master.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Bypass confirmation prompt for pip uninstall - Stack Overflow
I tried activating my virtualenv and then pip install --upgrade -r requirements. txt and that does seem to install the dependencies, even those ......
Read more >
Canonicalise all the things! - piwheels
So we deleted duplicates and renamed everything else using the canonical name pattern.
Read more >
14.04 - Pip uninstall leads to Owned by OS - Ask Ubuntu
You'll need to run sudo apt-get remove pip pip3 or, if you want to purge system configurations, sudo apt-get purge pip pip3 (if...
Read more >
Requirements for Python's pip - Karol Kuczmarski
... name for the package distribution. This is what makes it possible to refer to it later via pip, if only to remove...
Read more >
pip & virtualenv — Friendly 101 0.1 documentation
To solve this problem, the author of pip also created virtualenv. ... The name of my virtual environment was the ever-so creative hello...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found