fix(plugin): stop bundled hooks from auto-capturing on every tool call (0.14.4)#31
Merged
Merged
Conversation
…l (0.14.4) The 0.14.0 redesign made realtime auto-capture opt-in, but only in the settings.json hooks written by install-hooks. The plugin's own bundled plugin/hooks/hooks.json still wired PostToolUse -> task-journal ingest-hook (asyncRewake + rewakeSummary "Task Journal backlog forming"), plus PreCompact and Stop capture. So merely enabling the plugin re-armed exactly what the redesign removed: every tool call enqueued a pending/ chunk, nothing drained it (the claude -p backend is gone by design), the queue grew unbounded, and past the overflow threshold the asyncRewake signal fired on every PostToolUse -> "Task Journal backlog forming" surfaced dozens of times in a row. Empty the bundled hooks file. The enabled plugin is now quiet by default; resume + nudge + MCP tools come from install-hooks. Realtime capture remains available explicitly via install-hooks --auto-capture. The CLI asyncRewake / pending machinery is untouched (now dormant unless TJ_ASYNC_REWAKE=1 is set). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
A user saw "Task Journal backlog forming" printed ~30 times in a row in a project, and a live hook reminder reported a 44-entry pending queue, classifier behind.
Root cause
The 0.14.0 redesign moved realtime auto-capture to opt-in — but only in the
settings.jsonhooks written byinstall-hooks. The plugin's own bundledplugin/hooks/hooks.jsonwas never updated and still wired:PostToolUse → TJ_ASYNC_REWAKE=1 task-journal ingest-hookwithasyncRewake: true+rewakeSummary: "Task Journal backlog forming"PreCompact+Stop→ingest-hookSo enabling the plugin re-armed exactly what the redesign removed. With no classifier backend (the
claude -pdrainer is gone by design), every tool call enqueued apending/chunk that never drained; once the queue crossedPENDING_OVERFLOW_THRESHOLDthe asyncRewake signalexit(2)'d on every PostToolUse (main.rs:2251) → the repeated "backlog forming" lines.Fix
Empty the bundled
plugin/hooks/hooks.json. The enabled plugin is now quiet by default — resume + nudge + MCP tools come frominstall-hooks(settings.json), unchanged. Realtime capture stays available, explicitly, viainstall-hooks --auto-capture.The CLI asyncRewake / pending code is untouched (dormant unless
TJ_ASYNC_REWAKE=1); its 3 tests still pass. No Rust changed.Recovery for an existing backed-up queue:
task-journal pending-gc --days 0.Tests
asyncrewake_*(3) still green — CLI behaviour unchanged.fmtclean; build green.🤖 Generated with Claude Code