Commit Graph
1 Commits
Author SHA1 Message Date
sneak 89862b9e32 Map s3 not-found to storage.ErrNotFound in Get and Stat (closes #129)
check / check (pull_request) Successful in 2m47s
S3Storer.Get and Stat returned the raw AWS SDK error for a missing
object, so errors.Is(err, storage.ErrNotFound) was false on the s3
backend while the file and rclone backends honored the Storer contract.
Callers that branch on ErrNotFound behaved differently per backend.

Both now wrap ErrNotFound when the SDK reports a missing object,
leaving every other error intact. The not-found detection is a small
exported s3.IsNotFound helper, also used by HeadObject so the two share
one definition. A test asserts a missing key maps to ErrNotFound on the
s3 backend; it fails without the mapping.

model: claude-opus-4-8
2026-09-21 18:57:04 +00:00