Skip to content

Add hook_report_level config to suppress routine hook chatter #17105

Closed as duplicate

Description

@xsyetopz

Problem

Codex hook notifications currently surface routine, non-actionable output like:

  • “Running PreToolUse hook”
  • “PreToolUse hook (completed)”
  • “hook context: …” (from hook additionalContext)

This creates noise even when there are no warnings/errors/stops/blocks.

Proposed change

Add a config knob to control hook reporting without disabling hook execution:

hook_report_level = "off" | "error" | "warn" | "all"

  • warn (default): suppress HookStarted; drop context entries; suppress empty “completed” hook blocks
  • error: only show hook completions when status is failed/blocked/stopped (and only error/stop/feedback entries)
  • all: legacy behavior
  • off: emit nothing user-facing

Implementation (prototyped on a fork)

Fork branch: xsyetopz:fix/hook-report-level
Commit: a8133b308

Notes:

  • This only filters user-facing hook started/completed notifications.
  • It does not change whether hooks run, nor whether hook-provided additional context is injected into the model prompt.

Meta

This issue was opened with OpenAI Codex while working in a fork.
Any subsequent responses / iteration will be posted directly by the fork maintainer (@xsyetopz).

Activity

  1. added
    enhancementNew feature or request
    CLIIssues related to the Codex CLI
    hooksIssues related to event hooks
    on Apr 8, 2026
  2. github-actions commented on Apr 8, 2026

    @github-actions
    Contributor
  3. xsyetopz commented on Apr 8, 2026

    @xsyetopz
    Author

    Potential duplicates detected. Please review them and close your issue if it is a duplicate.

    Powered by Codex Action

    Issue #15497 does not seem to provide specific config values to alter per user's own needs.
    Issues #16993 && #16743 were closed as duplicates of #15497 && #16417 respectively.

  4. oxysoft commented on May 8, 2026

    @oxysoft

    Indexed this hook ticket in the umbrella tracker: #21753

    Goal: collect the scattered Codex hook requests and bugs into one parity matrix for Full Claude Code Hook Parity (29+), while preserving this issue as the detailed thread for its specific behavior.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    CLIIssues related to the Codex CLIenhancementNew feature or requesthooksIssues related to event hooks

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions