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

Add checkpointing and a "max packages to download" flag to CLI #58

Merged
merged 7 commits into from
Feb 27, 2023

Conversation

ericdill
Copy link

The current flow of conda-mirror is:

  1. download all the packages that are slated to be downloaded
  2. validate the newly downloaded packages (md5, sha256, size, etc.)
  3. then move them to the target local directory
  4. update repodata.json

By checkpointing, I mean do steps 2, 3, 4 every N packages. In this case, I've hardcoded it to 25 (but that could easily be another configurable flag). The advantage of doing this is that it means that the mirror process can be interrupted pretty much at any point and you'll only lose, at most, 25 new packages that have been downloaded. As opposed to how this thing currently works where if the script is interrupted at any point then all of the packages will be deleted and you'll have to download them again.

I also added a --max-packages flag which can be useful for debugging

@xhochy xhochy merged commit 73cc3cd into conda-incubator:master Feb 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants