feat(api): cancel analysis runs via loopback CLI - #378
Conversation
GAP-003A / issue #166: operators can cancel accepted and running runs through `tepp-analysis-runs cancel` without writing raw HTTP. Stdout stays metric-free; tepp.scientific_acceptance.v1 never appears. Stacked on collection CLI (#371). Does not duplicate GET-by-id, lifecycle POST, cancel HTTP, scientific-acceptance CLI, or collection list.
|
Important Draft PR not reviewedDraft PRs are not automatically reviewed by default.
To automatically review draft PRs, update your CodeRabbit configuration: reviews:
auto_review:
drafts: trueThanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Hour-21 exact-head review request. Current head @opencode-agent review |
|
Closing with replacement mapping to #174. The CLI is a client of the unauthenticated #361 destructive mutation and cannot make that boundary safe. Preserve its typed request/framing/stdout/refusal tests for the future authenticated Analysis Run operations CLI, but do not ship a credential-less loopback cancel command. |
Why
GAP-003A / issue #166 still required operators to write raw HTTP/1.1 after cancel HTTP. Operators cannot withdraw accepted or running runs from a client without guessing framing. Cancel CLI stdout stays metric-free.
tepp.scientific_acceptance.v1never appears.Live slices that this PR does not duplicate:
analysis_enginescientific-acceptance librarytepp-analysis-run)list(this PR stacks on that headf7d5e5a391eb2caa55bd5d337e90e719137b5041)What
Ninth GAP-003A slice stacked on #371 over collection GET
#368/ cancel HTTP#361/ protected main1bc02f580cf48e1d39da239f0e818453437c31c3:tepp-analysis-runs cancelclient ofPOST /v1/analysis-runs/{run_id}/cancelrun_id,run_state,idempotency_key,terminal_result: nulltepp.scientific_acceptance.v1never prints--run-id/--idempotency-keyNot an ADR 0014 scientific claim. Not persistence. Not GET-by-id. Not lifecycle POST. Not cancel HTTP. Not scientific-acceptance CLI. Not collection list.
Verification
cargo clippy -p tepp_api --all-targets -- -D warningscargo test -p tepp_api --libcargo test -p tepp_api --test analysis_run_cancel_cli_contractRUSTDOCFLAGS='-D warnings' cargo doc -p tepp_api --no-depspython3 scripts/validate_documentation.pypython3 scripts/check_docstrings.pyDo not merge without two independent APPROVE reviews on this exact head and current Checks. Author COMMENTED is not independent APPROVE.