How to get pip to work behind a proxy server

I am trying to use python package manager pip to install a package and it’s dependencies from the internet. However I am behind a proxy in my college and have already set the http_proxy environment variable. But when I try to install a package like this: I get this error in the log file: I even tried … Read more

How to upgrade all Python packages with pip

There isn’t a built-in flag yet, but you can use Note: there are infinite potential variations for this. I’m trying to keep this answer short and simple, but please do suggest variations in the comments! In older version of pip, you can use this instead: The grep is to skip editable (“-e”) package definitions, as suggested by @jawache. … Read more

No module named pkg_resources

July 2018 Update Most people should now use pip install setuptools (possibly with sudo). Some may need to (re)install the python-setuptools package via their package manager (apt-get install, yum install, etc.). This issue can be highly dependent on your OS and dev environment. See the legacy/other answers below if the above isn’t working for you. Explanation This error message is caused … Read more

Could not find a version that satisfies the requirement

This approach (having all dependencies in a directory and not downloading from an index) only works when the directory contains all packages. The directory should therefore contain all dependencies but also all packages that those dependencies depend on (e.g., six, pytz etc). You should therefore manually include these in requirements.txt (so that the first step downloads them explicitly) or you … Read more

Removing pip’s cache?

If using pip 6.0 or newer, try adding the –no-cache-dir option (source). If using pip older than pip 6.0, upgrade it with pip install -U pip.

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)