Skip to content

Self-gate: assert hooks parity between .claude/settings.json and hooks/hooks.json #140

Description

@robercano-ghbot

Blocked by #137

Problem

Three hooks are hand-duplicated between reCode's repo-local .claude/settings.json (self-hosted sessions, $CLAUDE_PROJECT_DIR paths) and the shipped hooks/hooks.json (consumers, ${CLAUDE_PLUGIN_ROOT} paths). Nothing checks they stay in sync — which is exactly how the tool-mirror hook (#137) ended up reCode-only for weeks with an empty cockpit workers panel in every consumer.

Do

Add a check to self/checks.sh that normalizes both hook sets (strip the path-prefix difference, compare event+matcher+script triples) and fails on divergence, with an explicit documented allowlist for deliberately self-only hooks. Lands AFTER #137 so the gate is born green.

🤖 Generated with Claude Code

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestmodule:harnessOrchestrator machinery under .claudeplannedOwner-approved for the autonomous loop (assigned ONLY by the owner)priority:mediumNormal queue

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions