Skip to content
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

The 'zipp>=0.4' distribution was not found #1985

Closed
Jaelen-Tyner opened this issue Oct 16, 2020 · 1 comment
Closed

The 'zipp>=0.4' distribution was not found #1985

Jaelen-Tyner opened this issue Oct 16, 2020 · 1 comment

Comments

@Jaelen-Tyner
Copy link

Issue
I have tried updated virtualenv using pip3 install virtualenv --upgrade and get the big error message below.
I am using a macbook pro.

Also, when trying to see which version of virtualenv, and when I run virtualenv --version, I get the following:

Traceback (most recent call last):
  File "/usr/local/bin/virtualenv", line 6, in <module>
    from pkg_resources import load_entry_point
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/pkg_resources/__init__.py", line 3241, in <module>
    @_call_aside
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/pkg_resources/__init__.py", line 3225, in _call_aside
    f(*args, **kwargs)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/pkg_resources/__init__.py", line 3254, in _initialize_master_working_set
    working_set = WorkingSet._build_master()
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/pkg_resources/__init__.py", line 585, in _build_master
    return cls._build_from_requirements(__requires__)
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/pkg_resources/__init__.py", line 598, in _build_from_requirements
    dists = ws.resolve(reqs, Environment())
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/pkg_resources/__init__.py", line 786, in resolve
    raise DistributionNotFound(req, requirers)
pkg_resources.DistributionNotFound: The 'zipp>=0.4' distribution was not found and is required by importlib-resources

What am i doing wrong?

@gaborbernat
Copy link
Contributor

I feel like this is because of an outdated pip installation, see #1704. However what you're typing does not add up. You're saying that you're installing virtualenv via pip3 install virtualenv --upgrade - so python 3, but then the virtualenv --version shows /System/Library/Frameworks/Python.framework/Versions/2.7/ so python 2. Use pipx instead of pip, installing packages into your operating systems global namespace is almost never a good idea https://virtualenv.pypa.io/en/latest/installation.html#via-pipx. Or create a virtual environment via (venv/or zipapp) and install virtualenv into that.

@pypa pypa locked and limited conversation to collaborators Jan 14, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants