fix(storage): drop cross-bucket options from move#99
Conversation
The server does not support cross-bucket move, so `MoveOptions` no longer accepts `srcBucket` / `destBucket`. Cross-bucket flows should use `copy` followed by `remove`. Assisted-by: Claude Opus 4.7 via Claude Code
Greptile SummaryThis PR removes the non-functional
Confidence Score: 4/5The logic change is correct and minimal — cross-bucket fields are cleanly stripped before reaching The code change itself is straightforward and correct:
Important Files Changed
Reviews (1): Last reviewed commit: "fix(storage): drop cross-bucket options ..." | Re-trigger Greptile |
Summary
MoveOptionsno longer acceptssrcBucket/destBucket. Cross-bucket flows should usecopyfollowed byremove.movenow states the constraint and points at thecopy+removeworkaround.@tigrisdata/storage.Test plan
pnpm --filter @tigrisdata/storage exec tsc --noEmit— cleanpnpm test— copy/move integration tests passbiome check— clean (pre-commit hook)🤖 Generated with Claude Code
Note
Medium Risk
This is a user-facing API change:
moveno longer acceptssrcBucket/destBucket, which will break callers relying on cross-bucket moves. Runtime behavior should be safer (aligned with server constraints), but downstream TypeScript compile errors are expected until updated.Overview
moveis now explicitly limited to same-bucket renames:MoveOptionsno longer inheritsCopyOptionsand only acceptsconfig, removingsrcBucket/destBucketsupport.The implementation forwards only
configintocopyOrMove, and a changeset documents the breaking behavior change and recommendscopy+removefor cross-bucket moves.Reviewed by Cursor Bugbot for commit 5238daf. Bugbot is set up for automated code reviews on this repo. Configure here.