CLI reference: sparkwing runs

CLI reference: sparkwing runs

Every sparkwing runs command, flag, and argument, generated from the CLI's own command registry. All command groups are indexed in cli-reference.md.

sparkwing runsSection anchor link

Inspect and control pipeline runs

SubcommandsSection anchor link

  • annotations -- Read or append persistent job + step annotations
  • approvals -- List approval gates (pending and history)
  • cancel -- Request cancellation of in-flight runs
  • grep -- Search run log text
  • list -- List recent pipeline runs
  • logs -- Print a run's logs
  • prune -- Delete finished runs older than a threshold, or by id
  • retry -- Trigger fresh runs copying pipeline + args from old ones
  • stats -- Report run counts, success rate, and duration percentiles
  • status -- Read one run's status, attempts, notices and selected view

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.

sparkwing runs annotationsSection anchor link

Read or append persistent job + step annotations

SubcommandsSection anchor link

  • add -- Append an annotation to a job or step
  • list -- List annotations on a run

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.

sparkwing runs annotations addSection anchor link

Append an annotation to a job or step

Plain emits run/job[/step]. JSON retains the controller replay result.

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.
--run RUN_IDRun ID or per-team run number. (required)
--job JOBJob within the selected run.
--step STEP_IDStep within the selected job.
--message TEXTText of the info-level annotation to attach to the job, or to the step named by --step. (required)
--profile NAMEController connection profile from your config. Optional profiles use the saved default, then local; --profile= selects local.

sparkwing runs annotations listSection anchor link

List annotations on a run

JSON emits job_id, optional step_id, level, message and source location per annotation. Plain emits one message per line, with line breaks replaced by spaces.

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.
--run RUN_IDRun ID or per-team run number. (required)
--job JOBJob within the selected run.
--step STEP_IDStep within the selected job.
--stepsAlso list annotations recorded on the run's steps, not only those on its jobs; --step implies this.
--profile NAMEController connection profile from your config. Optional profiles use the saved default, then local; --profile= selects local.

sparkwing runs approvalsSection anchor link

List approval gates (pending and history)

SubcommandsSection anchor link

  • approve -- Approve a pending approval-gate job
  • deny -- Deny a pending approval-gate job
  • list -- List pending approvals (or one run's history)

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.

sparkwing runs approvals approveSection anchor link

Approve a pending approval-gate job

The controller derives the approver from authentication. Plain emits run/job. JSON includes the approval and replay result.

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.
--run IDRun ID or per-team run number. (required)
--job JOBJob within the selected run. (required)
--comment STRComment recorded with the approval.
--profile NAMEController connection profile from your config. Optional profiles use the saved default, then local; --profile= selects local.

sparkwing runs approvals denySection anchor link

Deny a pending approval-gate job

The controller derives the approver from authentication. Plain emits run/job. JSON includes the approval and replay result.

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.
--run IDRun ID or per-team run number. (required)
--job JOBJob within the selected run. (required)
--comment STRComment recorded with the denial.
--profile NAMEController connection profile from your config. Optional profiles use the saved default, then local; --profile= selects local.

sparkwing runs approvals listSection anchor link

List pending approvals (or one run's history)

Without --run, list pending approvals. With --run, include resolved history. Plain emits run/job.

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.
--run RUN_IDRun ID or per-team run number.
--profile NAMEController connection profile from your config. Optional profiles use the saved default, then local; --profile= selects local.

sparkwing runs cancelSection anchor link

Request cancellation of in-flight runs

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.
--run RUN_IDRun ID or per-team run number. (required)
--profile NAMEController connection profile from your config. Optional profiles use the saved default, then local; --profile= selects local.

sparkwing runs grepSection anchor link

Search run log text

Search controller logs across matching runs. Filters apply before the run page limit. --max-matches limits matches per log subject, with zero meaning uncapped.

JSON emits matching records and a page record with next_cursor and truncated. Quiet JSON emits run_id records and sends continuation metadata to stderr. Plain emits matching lines, or run IDs with --quiet.

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.
--job JOBJob within the selected run.
--grep PATTERNShow only log lines matching this text.
--since DURATIONSearch only runs that started within this lookback, such as 24h, 7d or 2w; 0 sets no bound, and the later of --since and --started-after wins.
--profile NAMEController connection profile from your config. Optional profiles use the saved default, then local; --profile= selects local.
--pipeline NAMEPipeline name.
--status STATUSSearch only runs whose status matches exactly; prefix with ! to exclude a status.
--branch BRANCHSearch only runs on this exact branch name; several names match any of them, and a ! prefix excludes a branch. Repeatable; comma-separated values are accepted.
--sha PREFIXSearch only runs whose commit SHA starts with this prefix, ignoring case; prefix with ! to exclude.
--started-after DATESearch only runs that started at or after this time: today, yesterday, a lookback such as 7d, YYYY-MM-DD, YYYY-MM-DD HH:MM:SS or RFC 3339, in local time.
--started-before DATESearch only runs that started at or before this time, in the same formats as --started-after.
--limit NMaximum number of records to print, at least one. Continue with --cursor when more exist.
--max-matches NMost matching lines returned from each job or owner log, 5 by default; zero removes the cap.
-q, --quietPrint each matching run ID once instead of the matching lines.
--cursor CURSORContinue from next_cursor using the same filters.

sparkwing runs listSection anchor link

List recent pipeline runs

Read runs through the selected controller. Filters apply before pagination. Runs are ordered by descending team number. --since accepts days and weeks, such as 7d or 2w.

JSON emits compact run records and a page record with next_cursor and truncated. Quiet JSON emits id records and sends continuation metadata to stderr. Plain emits run IDs.

--by-pipeline totals every matching page and retains the newest --sparkline statuses. --group-by run|job|step requires --status failed and groups the selected page.

--wait blocks until a matching run appears. --follow reads every newer matching run between polls. Grouped follow output describes each new batch. Interrupted or timed-out waits exit 3. A refused read (not found, unauthenticated or forbidden) exits 4, which retrying cannot change.

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.
--pipeline NAMEPipeline name.
--status STATUSList only runs whose status matches exactly; prefix with ! to exclude a status.
--branch BRANCHList only runs on this exact branch name; several names match any of them, and a ! prefix excludes a branch. Repeatable; comma-separated values are accepted.
--sha PREFIXList only runs whose commit SHA starts with this prefix, ignoring case; prefix with ! to exclude.
--error SUBSTRList only runs whose recorded failure text, from run failures, job details and attempt failure reasons, contains this text, ignoring case.
--search QUERYText to match against record names and summaries; log text is not searched.
--since DURATIONList only runs that started within this lookback, such as 24h, 7d or 2w; 0 sets no bound, and the later of --since and --started-after wins.
--started-after DATEList only runs that started at or after this time: today, yesterday, a lookback such as 7d, YYYY-MM-DD, YYYY-MM-DD HH:MM:SS or RFC 3339, in local time.
--started-before DATEList only runs that started at or before this time, in the same formats as --started-after.
--finished-after DATEList only runs that finished at or after this time, in the same formats as --started-after; unfinished runs are left out.
--finished-before DATEList only runs that finished at or before this time, in the same formats as --started-after; unfinished runs are left out.
--limit NMaximum number of records to print, at least one. Continue with --cursor when more exist.
--cursor CURSORContinue from next_cursor using the same filters.
-q, --quietPrint only run IDs, or only pipeline names or group keys with --by-pipeline or --group-by.
--by-pipelinePrint one row per pipeline with run and failure totals, the last run and recent statuses, read across every matching page.
--sparkline NNumber of recent statuses kept for each pipeline with --by-pipeline, 30 by default.
--style STYLECharacters used to draw the recent-status sparkline in pretty --by-pipeline output, ascii by default.
--repo OWNER/NAMERepository identity as owner/name. Naming a repository grants no access. Repeatable; comma-separated values are accepted.
--root-onlyList only top-level runs, leaving out runs started by another run.
--group-by KEYGroup the failed runs on this page by run, job or step, with counts and a sample error; requires --status failed and cannot be used with --by-pipeline.
--waitPoll every 2 seconds until at least one matching run exists, exiting 3 if --wait-timeout passes first.
--wait-timeout DURATIONHow long --wait polls before giving up, as a Go duration such as 30s or 5m, 2m by default; ignored without --wait.
-f, --followKeep streaming until the observed work finishes.
--profile NAMEController connection profile from your config. Optional profiles use the saved default, then local; --profile= selects local.

sparkwing runs logsSection anchor link

Print a run's logs

Read job-attempt and trigger, plan or eval logs through the controller. --job selects a job. --tree includes descendants. --events-only and --no-events select lifecycle events or output.

Every read consumes all available pages. Without --follow, a snapshot with pending final log segments reports logs incomplete and exits 3. --follow waits for new records until final log segments are complete. An interrupted observation exits 3. A run that does not exist or that the credential cannot read exits 4; stop polling on 4.

JSON emits tagged log records. Plain emits log lines. Use --grep without --run to search across runs with the same filters and pagination as runs grep.

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.
--run RUN_IDRun ID or per-team run number.
--job JOBJob within the selected run.
--tail NPrint only the last N lines of each job or owner log; by default every line is printed.
--head NPrint only the first N lines of each job or owner log; cannot be combined with --tail.
--lines A:BPrint only lines A through B, inclusive and counted from 1, of each job or owner log.
--grep PATTERNShow only log lines matching this text.
--since DURATIONWith --run, print only lines and events within this lookback, such as 10m or 2d, keeping lines without a timestamp; with --grep and no --run, search only runs that started within it.
--treeAlso include logs from the runs this run started, and from the runs those started.
--events-onlyPrint only lifecycle events, leaving out log output.
--no-eventsPrint only log output, leaving out lifecycle events.
-f, --followKeep streaming until the observed work finishes.
--profile NAMEController connection profile from your config. Optional profiles use the saved default, then local; --profile= selects local.
--pipeline NAMEPipeline name.
--status STATUSWhen searching with --grep and no --run, search only runs whose status matches exactly; prefix with ! to exclude a status.
--branch BRANCHWhen searching with --grep and no --run, search only runs on this exact branch name; a ! prefix excludes a branch. Repeatable; comma-separated values are accepted.
--sha PREFIXWhen searching with --grep and no --run, search only runs whose commit SHA starts with this prefix, ignoring case.
--started-after DATEWhen searching with --grep and no --run, search only runs that started at or after this time: today, yesterday, a lookback such as 7d, YYYY-MM-DD or RFC 3339.
--started-before DATEWhen searching with --grep and no --run, search only runs that started at or before this time, in the same formats as --started-after.
--limit NMaximum number of records to print, at least one. Continue with --cursor when more exist.
--max-matches NWhen searching with --grep and no --run, the most matching lines returned from each log, 5 by default; zero removes the cap.
-q, --quietWhen searching with --grep and no --run, print each matching run ID once instead of the matching lines.
--cursor CURSORContinue from next_cursor using the same filters.

sparkwing runs pruneSection anchor link

Delete finished runs older than a threshold, or by id

Select --run, including --run - for IDs on stdin, or --older-than. Age selection reads every page and includes only terminal runs started before the cutoff. A failed selection deletes nothing.

--dry-run prints the selected IDs without deleting. The controller enforces retention pins. JSON reports the selected run and any structured failure. Plain emits acknowledged run IDs.

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.
--older-than DURATIONDelete every finished run that started longer ago than this, such as 72h, 30d or 4w; cannot be combined with --run.
--run RUN_IDRun ID or per-team run number.
--dry-runShow what would change without changing anything.
--profile NAMEController connection profile from your config. Optional profiles use the saved default, then local; --profile= selects local.

sparkwing runs retrySection anchor link

Trigger fresh runs copying pipeline + args from old ones

Select --failed to reuse successful jobs or --all-jobs to execute the sealed plan again. Retry preserves the source request, plan, source trust and actor. The controller records the retrier separately.

Repeat --run or use --run - for newline-separated IDs on stdin. JSON emits one safe receipt or structured failure per source run. Plain emits new run IDs. Local and remote retries use the same controller API.

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.
--run RUN_IDRun ID or per-team run number. Repeatable; comma-separated values are accepted. (required)
--failedStart a new run that reuses the source run's successful jobs and runs the rest again.
--all-jobsStart a new run that runs every job of the source run's plan again.
--profile NAMEController connection profile from your config. Optional profiles use the saved default, then local; --profile= selects local.

sparkwing runs statsSection anchor link

Report run counts, success rate, and duration percentiles

Read every matching root-run page through the selected controller. --since accepts days and weeks. JSON emits pipeline counts, success percentage, mean duration and nearest-rank P50 and P95. Plain emits pipeline names.

--sizing reads controller measurements, job rows, source, drift, memo exclusions and demand floors. --reset selects one --pipeline or --all-pipelines --yes and preserves resource pins. --since applies to run statistics only.

Sizing reset requires an authorized controller route. Until that contract exists the adapter returns policy_missing without changing state.

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.
--pipeline NAMEPipeline name.
--since DURATIONCount only top-level runs that started within this lookback, such as 7d or 2w; by default every run counts.
--sizingShow the controller's learned resource sizing for each job instead of run statistics.
--resetClear learned sizing for --pipeline or --all-pipelines while keeping resource pins; the controller has no route for this yet, so it fails with policy_missing and changes nothing.
--all-pipelinesApply --reset to every pipeline; requires --reset and --yes.
--yesConfirm a destructive change without prompting.
--profile NAMEController connection profile from your config. Optional profiles use the saved default, then local; --profile= selects local.

sparkwing runs statusSection anchor link

Read one run's status, attempts, notices and selected view

Read the same public run detail through a controller profile or the local controller. Numeric run selectors are per-team numbers.

Views: summary, timeline, receipt, errors, tree. Summary includes recorded failing steps and errors for failed jobs. --steps includes all recorded steps. Receipts retain the controller's hashes and settled cost.

--follow streams observations until the run ends. Exit 0 means success or a completed dry run, 1 means a failed or cancelled run, 2 means invalid usage, 3 means the observation is incomplete and may be retried, and 4 means the run does not exist or the credential cannot read it, so polling again will not help. --exit-zero suppresses terminal failure only.

Cloud awards awaiting activation show "Waiting for dedicated Cloud capacity" with elapsed time. Missing shared pool configuration for the requested hardware class ends the unit as cloud_capacity_unconfigured, releases its credit hold, and gives support@sparkwing.dev a run reference. A closed Cloud budget breaker ends a unit that needs a fresh node as cloud_capacity_unavailable the same way. JSON preserves run details and notices: one document per observation, so --follow and the errors view (one record per failed job) are NDJSON. The exit code carries the outcome, and no error document follows the observation. Plain summary prints the run status, every job's status and outcome, and failure details. Errors prints failed job IDs, tree prints run IDs, and receipt prints the receipt hash. --steps adds recorded steps to summary and tree output.

FlagsSection anchor link

FlagDescription
-o, --output FORMATPretty on a terminal; JSON when piped; explicit format wins. Values: pretty, json, plain.
-C, --checkout PATHResolve the project from this local checkout path.
-h, --helpShow command help without executing.
--help-allInclude uncommon flags in command help.
--run RUN_IDRun ID or per-team run number. (required)
-f, --followKeep streaming until the observed work finishes.
--stepsInclude every recorded step in summary and tree output, not only the failing steps summary shows by default.
--exit-zeroExit 0 when the run ended failed or cancelled; invalid usage and incomplete observations still exit nonzero.
--view VIEWWhich view of the run to print, summary by default.
--width NWidth in characters of the timeline view's bars, 60 by default.
--timeout DURATIONWith --follow, stop after this Go duration, such as 30m, and exit 3 if the run has not ended; refused without --follow.
--poll DURATIONTime between checks of the run with --follow, as a Go duration, 3s by default.
--profile NAMEController connection profile from your config. Optional profiles use the saved default, then local; --profile= selects local.