Skip to content

fix(cli): reject multiple list tag filters - #314

Open
AyobamiH wants to merge 6 commits into
vercel:mainfrom
AyobamiH:fix/list-single-tag-runtime-validation
Open

AyobamiH wants to merge 6 commits into
vercel:mainfrom
AyobamiH:fix/list-single-tag-runtime-validation

Conversation

@AyobamiH

Copy link
Copy Markdown

Summary

Reject multiple distinct --tag filters in the Sandbox CLI before making the API request.

The Sandbox API currently supports filtering by a single tag. While #312 adds type-level protection for SDK consumers, CLI input is runtime data and can still contain multiple tags.

This adds CLI-side validation so users receive an immediate, actionable error instead of an API error.

Changes

  • Reject more than one distinct --tag filter in sandbox list
  • Preserve the existing single-tag behaviour
  • Avoid making an API request when the input is invalid
  • Add regression coverage for valid and invalid tag filtering
  • Add a patch changeset for the CLI package

Testing

Added command-level tests verifying:

  • a single --tag is forwarded to sandboxClient.list()
  • multiple distinct --tag values produce an error
  • sandboxClient.list() is not called when multiple tags are supplied

Follow-up to the runtime validation concern raised in #312.

@vercel

vercel Bot commented Aug 24, 2026

Copy link
Copy Markdown
Contributor

@AyobamiH is attempting to deploy a commit to the Vercel Team on Vercel.

A member of the Team first needs to authorize it.

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