No module named pkg_resources

后端 未结 30 2444
一向
一向 2020-11-22 07:22

I\'m deploying a Django app to a dev server and am hitting this error when I run pip install -r requirements.txt:

Traceback (most recent call la         


        
相关标签:
30条回答
  • 2020-11-22 08:12

    None of the posted answers worked for me, so I reinstalled pip and it worked!

    sudo apt-get install python-setuptools python-dev build-essential 
    
    sudo easy_install pip 
    
    pip install --upgrade setuptools
    

    (reference: http://www.saltycrane.com/blog/2010/02/how-install-pip-ubuntu/)

    0 讨论(0)
  • 2020-11-22 08:13

    On Opensuse 42.1 the following fixed this issue:

    zypper in python-Pygments
    
    0 讨论(0)
  • 2020-11-22 08:14
    sudo apt-get install --reinstall python-pkg-resources
    

    fixed it for me in Debian. Seems like uninstalling some .deb packages (twisted set in my case) has broken the path python uses to find packages

    0 讨论(0)
  • 2020-11-22 08:14

    I have seen this error while trying to install rhodecode to a virtualenv on ubuntu 13.10. For me the solution was to run

    pip install --upgrade setuptools
    pip install --upgrade distribute 
    

    before I run easy_install rhodecode.

    0 讨论(0)
  • 2020-11-22 08:14

    On windows, I installed pip downloaded from www.lfd.uci.edu/~gohlke/pythonlibs/ then encontered this problem.

    So I should have installed setuptools(easy_install) first.

    0 讨论(0)
  • 2020-11-22 08:14

    I experienced that error in my Google App Engine environment. And pip install -t lib setuptools fixed the issue.

    0 讨论(0)
提交回复
热议问题