简体   繁体   中英

Can I remove pipenv cache folder? How to safely do it

while using my pipenv virtual environment, I found a huge folder full of cache, I want to know:

  1. Can I delete it?
  2. If yes, how to delete it
  3. What consequences could have deleting it

Route: home/cache/pipenv

删除

While simply deleting the Cache subfolder works fine, using pipenv lock --clear deletes the cache for your current project only. If you properly want to get rid of all the somewhen collected data, use

pipenv --clear

instead. You'll see Clearing caches... and the cache folder disappears. According to the documentation it is usually in one of the following locations:

~/Library/Caches/pipenv (macOS)
%LOCALAPPDATA%\pipenv\pipenv\Cache (Windows)
~/.cache/pipenv (other operating systems)

Caches are meant to be temporary so you can always clear them. With pipenv you can call pipenv lock --clear , or maybe the dirtier way by just deleting the folder. Seems like a lot of people have this issue with bloated pipenv caches. The downside to clearing the cache is that it will take longer for pipenv to download or install packages because it cannot quickly search for previously used versions in the cache folder.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM