Skip to content

fix(storage): better error messages on object get and put#59

Merged
designcode merged 2 commits intomainfrom
storage/put-error-messages
Feb 5, 2026
Merged

fix(storage): better error messages on object get and put#59
designcode merged 2 commits intomainfrom
storage/put-error-messages

Conversation

@designcode
Copy link
Collaborator

@designcode designcode commented Feb 5, 2026

Note

Low Risk
Error-handling-only changes in storage get/put; low risk aside from potentially changing surfaced error text that callers may rely on.

Overview
Improves user-facing error messages for object downloads by mapping common S3/Tigris error codes (e.g., AccessDenied, NoSuchKey) to clearer messages and providing a consistent fallback in get.

Tightens put upload failure handling to ensure a predictable Error is returned with either the underlying message or a generic fallback.

Written by Cursor Bugbot for commit 37533fc. This will update automatically on new commits. Configure here.

@greptile-apps
Copy link

greptile-apps bot commented Feb 5, 2026

Greptile Overview

Greptile Summary

Improved error handling in object storage operations with better error messages for common failure scenarios.

  • get.ts: Added specific error messages for AccessDenied and NoSuchKey errors, with fallback to original SDK error message for other cases
  • put.ts: Simplified error handling to pass through SDK error messages instead of only handling AccessDenied
  • package.json: Updated semantic-release dependency to v25.0.3

The changes make error messages more informative for users, especially for common scenarios like permission issues and missing files.

Confidence Score: 5/5

  • This PR is safe to merge with no blocking issues
  • The changes are straightforward improvements to error handling that make error messages more helpful without introducing bugs or breaking changes. The logic is sound and the code is correctly typed.
  • No files require special attention

Important Files Changed

Filename Overview
packages/storage/src/lib/object/get.ts Improved error handling with specific messages for AccessDenied and NoSuchKey errors, falls back to original error message for other cases
packages/storage/src/lib/object/put.ts Simplified error handling to pass through SDK error messages instead of checking specific error codes

Copy link

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 files reviewed, no comments

Edit Code Review Agent Settings | Greptile

@designcode designcode force-pushed the storage/put-error-messages branch from 2103828 to ca2e941 Compare February 5, 2026 14:29
@designcode designcode force-pushed the storage/put-error-messages branch from ca2e941 to 37533fc Compare February 5, 2026 14:37
Copy link
Contributor

@Xe Xe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Send it! :shipit:

@designcode designcode merged commit e9545f1 into main Feb 5, 2026
2 checks passed
@designcode designcode deleted the storage/put-error-messages branch February 5, 2026 14:47
@github-actions
Copy link

github-actions bot commented Feb 5, 2026

🎉 This PR is included in version 2.12.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants