fix(integration): clear residual greptile findings on the L3 gate#817
Conversation
Cross-checked the unaddressed greptile comments on the earlier integration PRs (#802-#810); most were already fixed or stale. Three genuine ones remained: - P1 (build_integration_review_pack): an R-OUTCOME-only deterministic reject is demoted to a healthy+quarantine slot, but grade["deterministic_reject"] was left True and serialized into agent_judge_summary.json. codex reads that and a "healthy slot with a deterministic reject" can spuriously push it to downgrade mergeable -> not mergeable. Clear the flag on demotion. + regression test. - codex_review deepseek-finding parser: replace the greedy `{.*}` DOTALL regex (which merges two JSON objects into one invalid blob) with raw_decode of the first complete object, tolerant of trailing prose. - integration_matrix: `git diff` runs with check=True but CalledProcessError bypassed the ScopeError fail-closed handler (uncaught traceback). Re-raise it as ScopeError so a failed/absent head_sha fails closed cleanly.
Greptile SummaryThis PR closes three genuine residual findings from earlier integration PRs: it clears
Confidence Score: 5/5All three changes are narrow, targeted fixes with no new surface area introduced; the deterministic_reject demotion fix is backed by a regression test. Each change addresses a well-scoped bug: the No files require special attention — all four changed files are straightforward and self-contained. Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[_classify_one] --> B{deterministic_reject?}
B -- No --> C[slot.status = healthy]
B -- Yes --> D{non_outcome rejects?}
D -- Yes --> E[slot.status = unhealthy]
D -- No R-OUTCOME only --> F[slot.status = healthy]
F --> G["slot.grade['deterministic_reject'] = False NEW"]
G --> H[Append R-OUTCOME quarantine message]
H --> I[Serialize to agent_judge_summary.json]
I --> J[codex_review reads summary]
J --> K{deterministic_reject?}
K -- False --> L[No spurious downgrade]
K -- True was bug --> M[Spurious not-mergeable downgrade]
%%{init: {'theme': 'base', 'themeVariables': {"darkMode": true, "background": "#0d1117", "primaryColor": "#21262d", "primaryTextColor": "#e6edf3", "primaryBorderColor": "#8b949e", "lineColor": "#8b949e", "textColor": "#e6edf3", "edgeLabelBackground": "#161b22", "actorBkg": "#21262d", "actorBorder": "#8b949e", "actorTextColor": "#e6edf3", "actorLineColor": "#8b949e", "signalColor": "#8b949e", "signalTextColor": "#e6edf3", "noteBkgColor": "#373320", "noteBorderColor": "#d4a72c", "noteTextColor": "#f0e6c0", "labelBoxBkgColor": "#21262d", "labelBoxBorderColor": "#8b949e", "labelTextColor": "#e6edf3", "loopTextColor": "#e6edf3", "activationBkgColor": "#30363d", "activationBorderColor": "#8b949e"}}}%%
flowchart TD
A[_classify_one] --> B{deterministic_reject?}
B -- No --> C[slot.status = healthy]
B -- Yes --> D{non_outcome rejects?}
D -- Yes --> E[slot.status = unhealthy]
D -- No R-OUTCOME only --> F[slot.status = healthy]
F --> G["slot.grade['deterministic_reject'] = False NEW"]
G --> H[Append R-OUTCOME quarantine message]
H --> I[Serialize to agent_judge_summary.json]
I --> J[codex_review reads summary]
J --> K{deterministic_reject?}
K -- False --> L[No spurious downgrade]
K -- True was bug --> M[Spurious not-mergeable downgrade]
Reviews (1): Last reviewed commit: "fix(integration): clear residual greptil..." | Re-trigger Greptile |
Cross-checked every greptile comment left unaddressed on the earlier integration PRs (#802–#810). Most were already fixed by later work or stale; this PR closes the genuine ones.
Triage of the 9 unaddressed comments
filter_matrixcatches import + per-cell exceptions (fail-open)endswith('/v1')){.*})[:8000]cut)has_cellsgreen-no-op guard_codex_envisolationFixes in this PR
deterministic_rejectleftTrueafter R-OUTCOME demotion. When an R-OUTCOME-only reject is demoted tohealthy+ quarantine, the grade still serializeddeterministic_reject: Trueintoagent_judge_summary.json. codex reads that, and a "healthy slot with a deterministic reject" can spuriously push it to downgrademergeable → not mergeable— directly undermining the gate calibration in fix(integration): calibrate L3 gate — slot matching, V-TAMPER false-positive, codex robustness #814. Now cleared on demotion. + regression test.json.JSONDecoder().raw_decodeof the first complete object (tolerant of trailing prose; a greedy{.*}merged two objects into one invalid blob, losing the finding).CalledProcessErrorfromgit diff --check=True→ re-raised asScopeErrorso a failed/absenthead_shafails closed cleanly instead of an uncaught traceback.Validation: 112 tests pass (incl. the new regression); ruff clean.