Merge bitcoin/bitcoin#22442: util: improves error messages on get_previous_releases script

179a051704 util: improves error messages on get_previous_releases script (Nelson Galdeman)

Pull request description:

  When previous releases are fetched and the specified version wasn't added to the checksum list we used to get a "Checksum did not match" which isn't true (https://github.com/bitcoin-core/bitcoincore.org/issues/753#issuecomment-879546719).

  If the specified version number is not on the list, it now logs cannot do the comparison instead.

ACKs for top commit:
  practicalswift:
    cr ACK 179a051704
  theStack:
    tACK 179a051704, tested on Debian bullseye/sid

Tree-SHA512: 2a07ce75232f853fd311c43581f8faf12d423668946ae6ad784feece5b4d0edd57fc018ba1f0c5a73bfaccb326e0df9a643580d16bf427c1ec3ff34a9cdbc80c
pull/22549/head
MarcoFalke 3 years ago
commit 8bc4a11409
No known key found for this signature in database
GPG Key ID: CE2B75697E69A548

@ -112,7 +112,11 @@ def download_binary(tag, args) -> int:
tarballHash = hasher.hexdigest()
if tarballHash not in SHA256_SUMS or SHA256_SUMS[tarballHash] != tarball:
print("Checksum did not match")
if tarball in SHA256_SUMS.values():
print("Checksum did not match")
return 1
print("Checksum for given version doesn't exist")
return 1
print("Checksum matched")

Loading…
Cancel
Save