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

Redirected download doesn't validate SHA of artifact #107

Closed
andsel opened this issue Jan 25, 2024 · 0 comments · Fixed by #106
Closed

Redirected download doesn't validate SHA of artifact #107

andsel opened this issue Jan 25, 2024 · 0 comments · Fixed by #106
Assignees

Comments

@andsel
Copy link
Contributor

andsel commented Jan 25, 2024

After #105 if an URL is redirected then the SHA validation breaks because try to compare with empty string.

% bundle exec rake vendor
Downloading https://github.com/collectd/collectd/archive/refs/tags/collectd-5.4.2.tar.gz
Follow redirect to: https://codeload.github.com/collectd/collectd/tar.gz/refs/tags/collectd-5.4.2
rake aborted!
SHA1 does not match (expected '69d00bf0589adc53c65e48ec18fe636b3efe2306' but got '')
/Users/andrea/.rvm/gems/jruby-9.4.2.0/gems/logstash-devutils-2.6.1-java/lib/logstash/devutils/rake/vendor.rake:20:in `fetch'
/Users/andrea/.rvm/gems/jruby-9.4.2.0/gems/logstash-devutils-2.6.1-java/lib/logstash/devutils/rake/vendor.rake:31:in `block in file_fetch'
org/jruby/ext/monitor/Monitor.java:82:in `synchronize'
/Users/andrea/.rvm/gems/jruby-9.4.2.0/gems/logstash-devutils-2.6.1-java/lib/logstash/devutils/rake/vendor.rake:36:in `file_fetch'
/Users/andrea/.rvm/gems/jruby-9.4.2.0/gems/logstash-devutils-2.6.1-java/lib/logstash/devutils/rake/vendor.rake:172:in `block in <main>'
/Users/andrea/.rvm/gems/jruby-9.4.2.0/gems/logstash-devutils-2.6.1-java/lib/logstash/devutils/rake/vendor.rake:171:in `block in <main>'
org/jruby/ext/monitor/Monitor.java:82:in `synchronize'
org/jruby/ext/monitor/Monitor.java:82:in `synchronize'
/Users/andrea/.rvm/gems/jruby-9.4.2.0/gems/rake-13.1.0/exe/rake:27:in `<main>'
/Users/andrea/.rvm/gems/jruby-9.4.2.0/bin/jruby_executable_hooks:22:in `<main>'
Tasks: TOP => vendor/collectd-5.4.2.tar.gz
(See full trace by running task with --trace)

The problem is

SHA1 does not match (expected '69d00bf0589adc53c65e48ec18fe636b3efe2306' but got '')
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 a pull request may close this issue.

1 participant