From 8d1189f1762874c4c7be1ec6fd23114026cbff00 Mon Sep 17 00:00:00 2001 From: Miroslav Drbal Date: Sat, 9 May 2026 18:36:50 +0200 Subject: [PATCH] fix(reviewer): add cross-boundary dispatch tracing obligation When a patch introduces a new type that crosses a function/module boundary (event, message, RPC frame, enum variant, etc.), the reviewer must locate the dispatch point on the consuming side and confirm the new type is handled. This class of bug is invisible from the diff alone because the silent drop lives in untouched routing code. Motivated by a missed P2 in PR #987: a new open_url extension_ui_request was emitted by login() but RpcClient#handleLine had no case for it and silently dropped every frame, leaving callers with no auth URL and the command hanging until timeout. --- .../coding-agent/src/prompts/agents/reviewer.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/packages/coding-agent/src/prompts/agents/reviewer.md b/packages/coding-agent/src/prompts/agents/reviewer.md index 9b096f9f4..2ab3063f6 100644 --- a/packages/coding-agent/src/prompts/agents/reviewer.md +++ b/packages/coding-agent/src/prompts/agents/reviewer.md @@ -77,6 +77,21 @@ Report issue only when ALL conditions hold: - **Proportionate rigor**: Fix doesn't demand rigor absent elsewhere in codebase + +For every new type, variant, or value introduced by the patch that crosses a function or module boundary +(event, message, command, frame, enum variant, queue item, IPC payload): + +1. Locate the **dispatch point** — the switch, router, filter chain, handler registry, or loop body + that receives and routes values of that kind on the **consuming** side. +2. Confirm the new type has an explicit branch, or that the existing catch-all forwards it correctly. +3. If the new type falls through to a silent drop, no-op, or discard (e.g. an unmatched `if`/`switch` + that simply returns without processing), report it as a defect. + +The dispatch point is frequently **outside the diff**. You **MUST** read it before concluding +the producing side is correct. Tracing only the emitting code while skipping the consuming +routing logic is the single most common source of missed integration bugs in reviews. + + |Level|Criteria|Example| |---|---|---|