Repository navigation
fix(cli): Match SDK variadic flags and streaming targets to the runtime - #1607
Merged
Merged
Conversation
Two gaps between what the library SDK accepts and what commands get:
- Stricli always hands variadic flags to a handler as arrays, but the
SDK forwards caller flags unchanged. An untyped caller passing
`{ field: "title" }` to explore crashed with `e.find is not a
function` (CLI-28C, CLI-2B4). applyFlagDefaults now wraps scalar
values for variadic flags in an array.
- The AsyncIterable overload for streaming commands (`log list --follow`,
`dashboard view --refresh`) did not accept trailing positionals, so
`sdk.log.list({ follow: "5" }, "org/project")` failed to type-check
even though the runtime accepts it.
Ported from getsentry/cli#1218, getsentry/cli#1293, getsentry/cli#1294,
and getsentry/cli#1655.
Co-Authored-By: BYK <burak.kaya@sentry.io>
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
This was referenced Oct 22, 2026
BYK
approved these changes
Oct 23, 2026
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Two places where what the library SDK accepts doesn't match what commands actually get:
{ field: "title" }toexplorecrashed withe.find is not a function(CLI-28C, CLI-2B4). fix(sdk): type variadic flags as arrays cli#1648 fixed the generated types.applyFlagDefaultsnow also wraps scalar values in an array at runtime, so plain JS callers work.AsyncIterableoverload forlog list --followanddashboard view --refreshdidn't accept trailing positionals, sosdk.log.list({ follow: "5" }, "org/project")failed to type-check even though the runtime accepts it.This replaces three getsentry/cli PRs that patched
exploredirectly. #1293'sparse: (v: string[]) => vwas wrong because Stricli callsparseonce per value. #1218 and #1294 coerced the arrays insideexplore. The variadic fix here is at the SDK boundary, which is the only path that can pass a scalar.Ported from getsentry/cli#1218, getsentry/cli#1293, getsentry/cli#1294, and the SDK part of getsentry/cli#1655. All are being closed with the repo archive.
via BYK.
--
View Junior Session in Sentry