codex - 💡(How to fix) Fix Hook execution audit logs clutter session terminal output [1 comments, 2 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
openai/codex#17321Fetched 2026-04-11 06:17:48
View on GitHub
Comments
1
Participants
2
Timeline
6
Reactions
0
Timeline (top)
labeled ×4closed ×1commented ×1
RAW_BUFFERClick to expand / collapse

What version of Codex CLI is running?

1.109.4

What subscription do you have?

plus

Which model were you using?

gpt-5.4

What platform is your computer?

Darwin 25.3.0 arm64 arm

What terminal emulator and version are you using (if applicable)?

Vibeyard/iTerm

What issue are you seeing?

When hooks are configured (e.g., SessionStart and UserPromptSubmit), their execution logs are printed directly into the session terminal output, cluttering the conversation with noise. Each hook invocation produces multiple lines like:

» Running SessionStart hook » Running SessionStart hook » Running SessionStart hook SessionStart hook (completed) SessionStart hook (completed) SessionStart hook (completed) » Running UserPromptSubmit hook » Running UserPromptSubmit hook » Running UserPromptSubmit hook UserPromptSubmit hook (completed) UserPromptSubmit hook (completed) UserPromptSubmit hook (completed)

This appears before every response, even for a simple prompt like "hey". The hook audit log lines are repeated multiple times (3x each in my case, matching the number of configured hooks) and are interleaved with the actual conversation output.

What steps can reproduce the bug?

  1. Setup hook.
  2. Start a session.
  3. Submit a prompt, e.g. "hey"

What is the expected behavior?

Hook execution logs should either be suppressed from the terminal output entirely, shown in a debug/verbose mode only, or at minimum deduplicated and visually separated from the conversation.

Additional information

No response

extent analysis

TL;DR

The issue can be mitigated by configuring the logging settings to suppress or deduplicate hook execution logs in the terminal output.

Guidance

  • Review the Codex CLI documentation to see if there are any logging configuration options that can be used to suppress or deduplicate hook execution logs.
  • Check if there are any environment variables or command-line flags that can be used to control the logging behavior of the Codex CLI.
  • Consider using a debug or verbose mode to see if it provides more control over the logging output.
  • If possible, try to configure the hooks to log their output to a separate file or stream to keep the conversation output clean.

Example

No code snippet is provided as the issue does not imply a specific code-based solution.

Notes

The solution may depend on the specific version of the Codex CLI and the configuration options available. The issue may be resolved in a future version of the Codex CLI.

Recommendation

Apply workaround: Configure the logging settings to suppress or deduplicate hook execution logs, as the current behavior is cluttering the conversation output and there is no clear indication that an upgrade to a fixed version is available.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING