fix(cli): fix plan explain to accept decision_id argument #6618

Merged
HAL9000 merged 3 commits from fix/issue-6325-plan-explain-decision-id into master 2026-05-31 19:26:47 +00:00

3 Commits

Author SHA1 Message Date
HAL9000 4d04b2e4ad test(tdd): restore tdd_plan_explain_plan_id regression tests for fixed behaviour
CI / lint (pull_request) Successful in 48s
CI / quality (pull_request) Successful in 47s
CI / typecheck (pull_request) Successful in 1m8s
CI / build (pull_request) Successful in 30s
CI / push-validation (pull_request) Successful in 19s
CI / security (pull_request) Successful in 1m22s
CI / helm (pull_request) Successful in 28s
CI / unit_tests (pull_request) Successful in 5m58s
CI / docker (pull_request) Successful in 1m38s
CI / coverage (pull_request) Successful in 13m36s
CI / integration_tests (pull_request) Successful in 22m10s
CI / status-check (pull_request) Successful in 3s
The TDD regression files for bug #968 were incorrectly deleted instead of
updated to assert the spec-compliant fixed behaviour from issue #6325.
Per CONTRIBUTING.md the regression guard must be kept and updated — not
removed — once the bug is fixed.

Restore and update all three files to assert the new expected behaviour:
- plan explain rejects a non-decision-id argument with rc=1
- error output contains "not found"
- decision data fields are absent from output

Also pair the orphaned robot/helper_tdd_plan_explain_plan_id.py with a
restored robot test file and update it to verify rc=1 rejection behaviour.

ISSUES CLOSED: #6325
2026-05-31 15:00:33 -04:00
HAL9000 a117445f6d fix(cli): fix lint and unit test failures in plan explain error path
- Shorten error message in explain_decision_cmd to fit 88-char limit (E501)
- Add `from None` to raise typer.Exit(1) inside except block (B904)
- Fix step definition mock to raise DecisionNotFoundError instead of
  returning None, so the exception handler fires and output contains
  "not found" as the scenario asserts

ISSUES CLOSED: #6325
2026-05-31 15:00:33 -04:00
HAL9000 c16d90058d fix(cli): only accept decision_id in plan explain (Closes #6325) 2026-05-31 15:00:33 -04:00