Debian Codegraph @

changelog/0.18.1_2025-09-21/issue-5467

raw
1 Bugfix: Improve handling of download retries in `check` command
2
3 In very rare cases, the `check` command could unnecessarily report repository
4 damage if the backend returned incomplete, corrupted data on the first download
5 try which is afterwards resolved by a download retry.
6
7 This could result in an error output like the following:
8
9 ```
10 Load(<data/34567890ab>, 33918928, 0) returned error, retrying after 871.35598ms: readFull: unexpected EOF
11 Load(<data/34567890ab>, 33918928, 0) operation successful after 1 retries
12 check successful on second attempt, original error pack 34567890ab[...] contains 6 errors: [blob 12345678[...]: decrypting blob <data/12345678> from 34567890 failed: ciphertext verification failed ...]
13 [...]
14 Fatal: repository contains errors
15 ```
16
17 This fix only applies to a very specific case where the log shows
18 `operation successful after 1 retries` followed by a
19 `check successful on second attempt, original error` that only reports
20 `ciphertext verification failed` errors in the pack file. If any other errors
21 are reported in the pack file, then the repository still has to be considered
22 as damaged.
23
24 Now, only the check result of the last download retry is reported as intended.
25
26 https://github.com/restic/restic/issues/5467
27 https://github.com/restic/restic/pull/5495