-
Notifications
You must be signed in to change notification settings - Fork 168
feat: target-aware hook event diagnostics #541
Copy link
Copy link
Open
Labels
area/cliCLI command surface, flags, help text (cross-cutting).CLI command surface, flags, help text (cross-cutting).enhancementDeprecated: use type/feature. Kept for issue history; will be removed in milestone 0.10.0.Deprecated: use type/feature. Kept for issue history; will be removed in milestone 0.10.0.needs-triageDeprecated: use status/needs-triage. Kept for issue history; will be removed in milestone 0.10.0.Deprecated: use status/needs-triage. Kept for issue history; will be removed in milestone 0.10.0.status/acceptedDirection approved, safe to start work.Direction approved, safe to start work.status/triagedInitial agentic triage complete; pending maintainer ratification (silence = approval).Initial agentic triage complete; pending maintainer ratification (silence = approval).type/featureNew capability, new flag, new primitive.New capability, new flag, new primitive.
Milestone
Metadata
Metadata
Assignees
Labels
area/cliCLI command surface, flags, help text (cross-cutting).CLI command surface, flags, help text (cross-cutting).enhancementDeprecated: use type/feature. Kept for issue history; will be removed in milestone 0.10.0.Deprecated: use type/feature. Kept for issue history; will be removed in milestone 0.10.0.needs-triageDeprecated: use status/needs-triage. Kept for issue history; will be removed in milestone 0.10.0.Deprecated: use status/needs-triage. Kept for issue history; will be removed in milestone 0.10.0.status/acceptedDirection approved, safe to start work.Direction approved, safe to start work.status/triagedInitial agentic triage complete; pending maintainer ratification (silence = approval).Initial agentic triage complete; pending maintainer ratification (silence = approval).type/featureNew capability, new flag, new primitive.New capability, new flag, new primitive.
Type
Projects
Status
Todo
Summary
When APM deploys hooks for a package, it should log which hook event names were found and note if they may not be recognized by the target platform. Currently APM silently deploys all events regardless of target.
Background
The hooks specification has no unified standard — three implementations exist with divergent event names and schemas:
sessionStart,preToolUse,postToolUse,userPromptSubmittedSessionStart,PreToolUse,PostToolUse,UserPromptSubmitSessionStart,PreToolUse,PostToolUse,UserPromptSubmit,PermissionRequest,FileChangedAdditionally, each platform supports different events — Claude Code has 25+ events, while GH Agent has 8.
Proposed Behavior
When deploying hooks to a target (e.g.,
copilot,claude,cursor,codex):"Deployed 3 hook events: preToolUse, postToolUse, sessionStart")"Note: camelCase events detected — these are GitHub Copilot Agent format; VS Code expects PascalCase")Scope
logger.infoor diagnostics mechanism--strictmode that warns on unrecognized events per targetRelated
windowskey)command,bash,powershell,windows,linux,osx) are already handled as a superset; this issue addresses the event name dimension