fix: prevent pi command widening loops

This commit is contained in:
2026-04-30 02:34:22 +03:00
parent bd02308811
commit a81587d9a7
21 changed files with 32 additions and 6 deletions
@@ -11,7 +11,7 @@ Discover relevant Angular and React code for: {goal}
Treat `ClientApp/` as the Angular reference and `src/` as the React implementation. Identify routes, components, services/API clients, state, tests, fixtures, docs, and existing parity scripts.
Tool policy: do not call `glob` or any unavailable abstract discovery tool. Use bash discovery only: `rg --files`, `rg -n`, `find`, `sed`, `nl`, and `git grep`. If a tool returns `Tool <name> not found`, stop using it immediately; if the same tool error repeats twice, stop the task and report the blocker. Do not repeat failed tool calls or shell commands. If a command exits non-zero with no useful output, do not retry it unchanged; inspect source/tests or change the hypothesis first. If a focused test fails, use the failure location to inspect and fix code/tests; do not repeatedly grep test output for unrelated terms. After two failed verification attempts without a code or test change, stop and report the blocker. Do not continue after five consecutive calls that add no new information.
Tool policy: do not call `glob` or any unavailable abstract discovery tool. Use bash discovery only: `rg --files`, `rg -n`, `find`, `sed`, `nl`, and `git grep`. If a tool returns `Tool <name> not found`, stop using it immediately; if the same tool error repeats twice, stop the task and report the blocker. Do not repeat failed tool calls or shell commands. If a command exits non-zero with no useful output, do not retry it unchanged; inspect source/tests or change the hypothesis first. If a focused test fails, use the failure location to inspect and fix code/tests; do not repeatedly grep test output for unrelated terms. After two failed verification attempts without a code or test change, stop and report the blocker. Do not continue after five consecutive calls that add no new information. Treat semantically equivalent commands as repeats even when numeric limits or filters change; do not widen `sed`, `head`, `tail`, or `git diff | grep` ranges step by step.
## analyze-parity
role: parity