I have limited space on my server, and I am thinking to delete the cache of the PIP. I am not sure if its safe to delete or not.
ls ~/.cache/pip/
Contains following dir/files.
http selfcheck.json wheels
Version
$ pip -V
pip 7.1.2 from /usr/local/lib/python2.7/dist-packages/pip-7.1.2-py2.7.egg (python 2.7)
Please advise.
解决方案
According to pip's caching documentation from version 6 you can use the --no-cache-dir option.
But that didn't help me as I was using a wrapper (pinax starter projects) that runs pip in the background to install several packages. Since I kept getting an pip.exceptions.HashErrors ('hashes don't match the requirement file) and I didn't want to temper with its code I renamed the pip cache folder and tried running my wrapper again. Once I noticed there weren't issues I proceeded to delete the entire cache pip folder. I haven't had any problem after that. So I can assume it is entirely a safe operation to delete pip's cache folder.
These are the locations where you can find your pip cache:
Unix
~/.cache/pip and it respects the XDG_CACHE_HOME directory.
OS X
~/Library/Caches/pip.
Windows
\pip\Cache
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)