Repository navigation
feat: broaden hook + common-field coverage (v0.22.4) - #97
Conversation
New observation-only hook events (via the dispatcher — registry + hooks.json): - Setup (setup_type), CwdChanged (path, hashed), MessageDisplay (message_length only — content lives in the transcript), Elicitation (server/tool_name/ tool_input), ElicitationResult (server/tool_name; raw user_response omitted for privacy). Field-name corrections to match the current hook input schema — these events were previously capturing undefined: - StopFailure: error_type/error_message (was error/error_details) - TeammateIdle: agent_type - TaskCreated: task_metadata; TaskCompleted: completion_status - ConfigChange: config_source; WorktreeCreate: worktree_name/worktree_path - Notification: dropped nonexistent title; InstructionsLoaded: dropped memory_type Also: SessionStart now captures session_title. Coverage/field tests added. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KoEUHYQTz1Tx61FcteE979
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KoEUHYQTz1Tx61FcteE979
|
Warning Review limit reachedYou’ve reached a temporary PR review limit under our Fair Usage Limits Policy. Next review available in: 2 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (6)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
…k-only
MessageDisplay fires per streaming delta, so capture no content and log only
the final chunk:
- add turn_id to the central event fields (all events get turn-level correlation,
free — like prompt_id)
- MessageDisplay mapper returns { message_id } on final, else null
- runHook now treats a null mapper return as 'skip logging this occurrence'
(the hook still ran; nothing is written)
Result: one lightweight record per assistant message (turn_id + message_id, no
delta), instead of a content-bearing record per chunk.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01KoEUHYQTz1Tx61FcteE979
MessageDisplay fires per streaming delta (hundreds/turn = a node spawn each) and its turn_id/message_id have no documented, stable join to the transcript, so it's removed (registry + hooks.json + the runHook null-skip + central turn_id it required). Complete the common-input-fields coverage in the central event data: - re-add effort_level (the effort capture was lost in #96's rebase and never reached main) - add agent_id / agent_type centrally so subagent context is recorded on EVERY event fired inside a subagent (not just the Subagent* lifecycle events) All 9 documented common fields are now captured: session_id, hook_event_name, prompt_id, transcript_path, cwd, permission_mode, effort_level, agent_id, agent_type. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KoEUHYQTz1Tx61FcteE979
Maximize hook-event and common-input-field coverage against the current Claude Code hook schema.
New hook events (via the data-driven dispatcher)
Setupsetup_typeCwdChangedpath(HMAC-hashed)Elicitationserver,tool_name,tool_inputElicitationResultserver,tool_name(rawuser_responseomitted — user PII)Full common-input-field coverage (central
data)All 9 documented common fields are now captured on every event:
session_id,hook_event_name,prompt_id,transcript_path,cwd,permission_mode,effort_level,agent_id,agent_type.effort_level— the effort capture was lost during feat: capture prompt_id + reasoning-effort level (v0.22.3) #96's rebase and never reachedmain.agent_id/agent_typecentrally so subagent context is recorded on every event fired inside a subagent (not just theSubagent*lifecycle events).SessionStartalso now capturessession_title.Field-name corrections (were silently capturing
undefined)StopFailure(error_type/error_message),TeammateIdle(agent_type),TaskCreated(task_metadata),TaskCompleted(completion_status),ConfigChange(config_source),WorktreeCreate(worktree_name/worktree_path); dropped nonexistentNotification.title/InstructionsLoaded.memory_type.MessageDisplay — deliberately NOT captured
It fires per streaming
delta(hundreds of node-process spawns per turn), and itsturn_id/message_idhave no documented, stable join to the transcript (docs warn the JSONL format is internal/unstable). Turn-level correlation is already provided by the documented common fieldprompt_id; full message content lives in the uploaded transcript.Verification
node --test→ 57/57 pass;claude plugin validate✔.CwdChanged.pathhashed, all 9 common fields captured on one event.🤖 Generated with Claude Code