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

Commands to manage the pip cache #5110

Closed
pfmoore opened this issue Mar 22, 2018 · 4 comments
Closed

Commands to manage the pip cache #5110

pfmoore opened this issue Mar 22, 2018 · 4 comments
Assignees
Labels
auto-locked Outdated issues that have been locked by automation

Comments

@pfmoore
Copy link
Member

pfmoore commented Mar 22, 2018

Creating this as a bit of a brain dump, and a reminder for consideration at some point.

The pip cache is basically an opaque area containing HTTP response data and built wheels. While it's not huge, on Windows it's in %LOCALAPPDATA% which is often on the root drive, which can be a limited-size SSD (I don't know where it's located on non-Windows systems, but I assume it would be similar).

Tools to manage and/or housekeep the cache would be useful. As a basic suggestion:

  1. Print the location (and maybe the size) of the cache.
  2. Clear the cache (with maybe options to just clear HTTP, or just clear wheels).
  3. Time-based housekeeping (delete anything older than a certain time).
  4. Python version based housekeeping of wheels (delete any wheels for CPython 3.5).

Much of this can be done with OS based tools or 3rd party Python code, so maybe a minimal solution would be to provide a pip info command that allowed querying pip for the cache location, and add a little bit of documentation confirming what's OK (e.g., that blindly deleting files or whole directories from the HTTP cache based on timestamp is safe).

@pfmoore pfmoore self-assigned this Mar 22, 2018
@pradyunsg
Copy link
Member

#4685 :)

@pfmoore
Copy link
Member Author

pfmoore commented Mar 23, 2018

@*&%$ I'm playing well this week, aren't I? Thanks.

@pfmoore pfmoore closed this as completed Mar 23, 2018
@pradyunsg
Copy link
Member

Hahah. You're welcome! :)

@lock
Copy link

lock bot commented Jun 2, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot added the auto-locked Outdated issues that have been locked by automation label Jun 2, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Jun 2, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
auto-locked Outdated issues that have been locked by automation
Projects
None yet
Development

No branches or pull requests

2 participants