Repository navigation
Description
Problem Description
When a stage plan fails at a gate, no log, comment or record says which claims the gate refused. Only the gate and code counts are logged (log_gate_returns in src/devops_cli/roadmap/round_log.py, #4846).
Case of 2026-11-13, release v0.129.0, item #1976:
stage gate returns: ... returns=3 result=refused gates=trace:10 codes=stage_problem_trace_path:10stage gate findings: ... return=3 in=8 gone=1 stuck=7 new=3roadmap job result: job=stage item=#1976 result=failed class=plan_defect plan_calls=4 gate_returns=3 verify_rounds=0 tokens=3795139 seconds=1734
The trace gate refused 10 claims of the form "The Feasibility section states that {path} was read, but the run did not read it", and 7 of them stayed through the returns. Nobody can tell from this evidence if the planner claimed reads that it did not make, or if the gate refused true reads (the false-positive forms of #4590). Stage is the job with the lowest success (1 of 4 in 6 hours), and plan_defect is its top failure class, so each such failure must be classifiable.
Expected vs Actual Behavior
Expected: for each refused reply, the log names each finding: its gate, its code and its subject (for example the path or the tool that the trace gate names), masked and cut to a fixed length. Then a person or the shepherd can classify a gate failure as a planner fault or a gate fault from Loki alone.
Actual: only counts are logged.
Proposed Solution
- Log one line for each finding of the last refused reply, or add the subjects to the existing line:
gate,code,subject(the path, tool or command that the problem names), passed throughmask_secretsand cut to 200 characters each, at most 20 findings for each reply. - Keep the counts line as it is, so the shepherd queries keep working.
- No plan text and no model text go into the log (telemetry privacy rule): only the subject that the gate names.
Acceptance Criteria
- A test proves that a refused reply with trace findings logs the path of each finding, and that a subject longer than 200 characters is cut.
- A test proves that a reply with a secret-like subject logs the masked value.
-
uv run devops ci fail-to-pass --base origin/mainshows the new tests fail on the base.
Existing Tool Considered
The standard logging module and mask_secrets (src/devops_cli/security/sanitizer.py) already in use. No new tool. Cost to build (estimate): 0.2 M tokens and 1 hour.
Related
#4590 (trace gate false positives), #4846 (the gate counts), #1976.
Activity
dan-petty commentedon Nov 13, 2026
Both work on the stage gate refusal log; #4846 sets the counts structure, the candidate adds per-finding subjects.fix(roadmap): the stage gate log names each refused finding
devops-cli-service commentedon Nov 13, 2026
Released in v0.130.0: https://github.com/dan-petty/devops-cli/releases/tag/v0.130.0
devops-cli-service commentedon Nov 13, 2026
Live since 2026-11-13 18:17 UTC