cosmetic: a corrupted blob's raw bytes are printed in every error, once per file under --skip-errors #424

Closed
opened 2026-11-11 01:01:47 +01:00 by clawbot · 2 comments
Collaborator

Found by the acceptance test (#418).

Steps to reproduce

  • Overwrite one stored blob at the destination with random bytes of the same size.
  • Run vaultik snapshot verify --deep ID, vaultik snapshot restore ID DIR, and vaultik --skip-errors snapshot restore ID DIR.

What happened

Each error ends with parsing age header: unexpected intro: "..." followed by the first bytes of the blob, escaped, about 1 KB per message. Deep verify and plain restore print it twice each (log record plus ERROR: line). Under --skip-errors the restore prints it for every file that needs the blob: in the test, 592 log lines of about 1.2 KB each, then a warning listing all 295 failed paths. The --json document of deep verify carries the same bytes in its error field.

What should happen

The error says that the blob is not a valid age stream and names the blob hash, without quoting its contents. Under --skip-errors, a blob that failed once is reported once, and the files that depend on it are counted, not listed one by one with the same cause.

Model: fable-5-1

Found by the acceptance test (https://git.eeqj.de/sneak/vaultik/issues/418). **Steps to reproduce** - Overwrite one stored blob at the destination with random bytes of the same size. - Run `vaultik snapshot verify --deep ID`, `vaultik snapshot restore ID DIR`, and `vaultik --skip-errors snapshot restore ID DIR`. **What happened** Each error ends with `parsing age header: unexpected intro: "..."` followed by the first bytes of the blob, escaped, about 1 KB per message. Deep verify and plain restore print it twice each (log record plus `ERROR:` line). Under `--skip-errors` the restore prints it for every file that needs the blob: in the test, 592 log lines of about 1.2 KB each, then a warning listing all 295 failed paths. The `--json` document of deep verify carries the same bytes in its `error` field. **What should happen** The error says that the blob is not a valid age stream and names the blob hash, without quoting its contents. Under `--skip-errors`, a blob that failed once is reported once, and the files that depend on it are counted, not listed one by one with the same cause. Model: fable-5-1
Author
Collaborator

Plan: an error about a blob that is not a valid age stream names the blob's hash and says it cannot be decrypted, without quoting any of its bytes. Under --skip-errors, a blob that failed once is reported once, with the number of files it affected, and is not downloaded again for each file.

Package: internal/vaultik (restore), and internal/blobgen if the bytes enter the error there.

For every unit from the acceptance test

  • One branch off current next, one PR with base next, labelled needs-review and assigned to clawbot. The title ends (closes #N).
  • Add nothing to docs/TODO.md. sneak ruled on 11 November that it is not a history document (#440).
  • README.md on next: change only a sentence the fix makes false. The rewritten README in #399 is with sneak and is updated after this merges.
  • A test that fails on current next shows the fix. Run make fmt and make check before the final push.

Model: opus-5-5

Plan: an error about a blob that is not a valid age stream names the blob's hash and says it cannot be decrypted, without quoting any of its bytes. Under `--skip-errors`, a blob that failed once is reported once, with the number of files it affected, and is not downloaded again for each file. Package: `internal/vaultik` (restore), and `internal/blobgen` if the bytes enter the error there. **For every unit from the acceptance test** - One branch off current `next`, one PR with base `next`, labelled `needs-review` and assigned to `clawbot`. The title ends `(closes #N)`. - Add nothing to `docs/TODO.md`. sneak ruled on 11 November that it is not a history document (https://git.eeqj.de/sneak/vaultik/issues/440). - `README.md` on `next`: change only a sentence the fix makes false. The rewritten README in https://git.eeqj.de/sneak/vaultik/pulls/399 is with sneak and is updated after this merges. - A test that fails on current `next` shows the fix. Run `make fmt` and `make check` before the final push. Model: opus-5-5
clawbot self-assigned this 2026-11-11 01:21:27 +01:00
Author
Collaborator

Built in #449: an age stream that cannot be opened now fails with "not a valid age stream" and no quoted bytes; under --skip-errors, restore reports a failed blob once and counts its files instead of listing them.

Model: opus-5-5

Built in https://git.eeqj.de/sneak/vaultik/pulls/449: an age stream that cannot be opened now fails with "not a valid age stream" and no quoted bytes; under `--skip-errors`, restore reports a failed blob once and counts its files instead of listing them. Model: opus-5-5
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: sneak/vaultik#424