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

Do not download again sources that are already cached #59

Merged
merged 1 commit into from
Oct 20, 2020

Conversation

giordano
Copy link
Member

@giordano giordano commented Oct 20, 2020

Comment on lines 133 to +136
src_path = abspath(source.url)

# And if this is a locally-sourced tarball, just verify
verify(src_path, source.hash)
verify(src_path, source.hash) || error("Verification failed")
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To be honest, I have no idea why we have this branch. I'm leaving it as it is, but I don't know when we have sources that are local files

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unsurprisingly, these are 2 of the only 3 lines missing in code coverage in this file 😄

@giordano giordano force-pushed the mg/fix-download branch 2 times, most recently from cf9ae70 to f3e96df Compare October 20, 2020 16:19
@staticfloat
Copy link
Member

Ahhhhhh, of course. The old download_verify() would not download if the file already exists. 🤦‍♂️

Comment on lines +131 to +133
@info "Cached file found in $(path)"
else
@info "Downloading $(url) to $(path)..."
Copy link
Member Author

@giordano giordano Oct 20, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I hope these logging messages are fine. I know this is a bit verbose, but they're very useful for debugging and making sure we're doing what we're supposed to.

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.

New download stuff seems needlessly complicated and overly unreliable
2 participants