Skip to content

Conversation

@threepointone
Copy link
Collaborator

This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated.

Releases

@cloudflare/sandbox@0.0.1

Patch Changes

@github-actions github-actions bot force-pushed the changeset-release/main branch from 1bd7a29 to 4de4cff Compare June 23, 2025 11:39
@threepointone threepointone merged commit db09b4d into main Jun 23, 2025
ghostwriternr added a commit to ghostwriternr/sandbox-sdk that referenced this pull request Nov 5, 2025
Address all minor issues identified in code review:

Issue cloudflare#1: Add bucket mounting methods to ISandbox interface
- Moved BucketProvider, BucketCredentials, MountBucketOptions from SDK to shared types
- Added mountBucket() and unmountBucket() to ISandbox interface
- Updated SDK imports to use shared types
- bucket-mount/types.ts now re-exports from shared for backward compatibility

Issue cloudflare#2: Fix bucket name regex for 3-character names
- Changed regex from /^[a-z0-9][a-z0-9.-]{1,61}[a-z0-9]$/
  to /^[a-z0-9]([a-z0-9.-]{0,61}[a-z0-9])?$/
- Previous regex was too greedy and failed on 3-char bucket names
- New regex properly handles 3-63 character bucket names per S3 spec

Issue cloudflare#4: Add duplicate mount path validation
- Check if mountPath already exists in activeMounts before mounting
- Throw InvalidMountConfigError with helpful message if duplicate detected
- Prevents confusing state where same path is mounted twice

All changes maintain backward compatibility and follow existing patterns.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant