mirror of
https://github.com/Jeuners/ECC.git
synced 2026-09-09 15:02:30 +02:00
The SessionStart hook injects the most recent *-session.tmp as additionalContext labelled only with 'Previous session summary:'. After a /compact boundary, the model frequently re-executes stale slash-skill invocations it finds inside that summary, re-running ARGUMENTS-bearing skills (e.g. /fw-task-new, /fw-raise-pr) with the last ARGUMENTS they saw. Observed on claude-opus-4-7 with ECC v1.9.0 on a firmware project: after compaction resume, the model spontaneously re-enters the prior skill with stale ARGUMENTS, duplicating GitHub issues, Notion tasks, and branches for work that is already merged. ECC cannot fix Claude Code's skill-state replay across compactions, but it can stop amplifying it. Wrap the injected summary in an explicit HISTORICAL REFERENCE ONLY preamble with a STALE-BY-DEFAULT contract and delimit the block with BEGIN/END markers so the model treats everything inside as frozen reference material. Tests: update the two hooks.test.js cases that asserted on the old 'Previous session summary' literal to assert on the new guard preamble, the STALE-BY-DEFAULT contract, and both delimiters. 219/219 tests pass locally. Tracked at: #1534 |
||
|---|---|---|
| .. | ||
| auto-tmux-dev.test.js | ||
| bash-hook-dispatcher.test.js | ||
| block-no-verify.test.js | ||
| check-hook-enabled.test.js | ||
| config-protection.test.js | ||
| cost-tracker.test.js | ||
| design-quality-check.test.js | ||
| detect-project-worktree.test.js | ||
| doc-file-warning.test.js | ||
| evaluate-session.test.js | ||
| gateguard-fact-force.test.js | ||
| governance-capture.test.js | ||
| hook-flags.test.js | ||
| hooks.test.js | ||
| mcp-health-check.test.js | ||
| observe-subdirectory-detection.test.js | ||
| observer-memory.test.js | ||
| post-bash-hooks.test.js | ||
| pre-bash-commit-quality.test.js | ||
| pre-bash-dev-server-block.test.js | ||
| pre-bash-reminders.test.js | ||
| quality-gate.test.js | ||
| session-activity-tracker.test.js | ||
| stop-format-typecheck.test.js | ||
| suggest-compact.test.js | ||