You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've updated to v0.3.20, and created a .codex/hooks.json in the project:
{ "hooks": { "PreToolUse": [ { "matcher": "Bash", "hooks": [ { "type": "command", "command": "[ -f graphify-out/graph.json ] && echo '{"hookSpecificOutput":{"hookEventName":"PreToolUse","permissionDecision":"allow","systemMessage":"graphify: Knowledge graph exists. Read graphify-out/GRAPH_REPORT.md for god nodes and community structure before searching raw files."}}' || true" } ] } ] } }
error:
`• Running PreToolUse hook
PreToolUse hook (failed)
error: hook returned invalid pre-tool-use JSON output`
Fixed in v0.3.21. The root cause was that systemMessage was nested inside hookSpecificOutput, but the codex-cli schema uses additionalProperties: false on that object — so any unknown field fails validation. It now lives at the top level where the schema expects it.
Upgrade and re-run the install to get the fixed hook:
Activity
Fix Codex hook JSON schema (#138) and use #!/bin/sh for Windows git h…
safishamsi commentedon Apr 9, 2026
Fixed in v0.3.21. The root cause was that
systemMessagewas nested insidehookSpecificOutput, but the codex-cli schema usesadditionalProperties: falseon that object — so any unknown field fails validation. It now lives at the top level where the schema expects it.Upgrade and re-run the install to get the fixed hook:
Fix Codex hook JSON schema (#138) and use #!/bin/sh for Windows git h…
Fix Codex hook JSON schema (Graphify-Labs#138) and use #!/bin/sh for …