[BUG] Screen flickers on every keystroke after resuming session with PostToolUse hooks

Resolved 💬 3 comments Opened Jan 17, 2026 by jensensics Closed Feb 27, 2026

Preflight Checklist

  • [x] I have searched existing issues and this hasn't been reported yet
  • [x] This is a single bug report (please file separate reports for different bugs)
  • [x] I am using the latest version of Claude Code

What's Wrong?

Screen flickers on every keystroke after resuming session with PostToolUse hooks

Environment

  • Claude Code version: 2.1.11
  • OS: macOS 15.7.1 (Build 24G231)
  • Terminal: Default macOS Terminal

Description

After using /exit to end a session and then resuming it with /resume (or claude --resume), the screen flickers on every keystroke typed in the input dialog. This makes the CLI unusable until a fresh session is started.

Steps to Reproduce

  1. Start Claude Code in a project with PostToolUse hooks configured:

``json
{
"hooks": {
"PostToolUse": [
{
"matcher": "Edit|Write",
"hooks": [
{
"type": "command",
"command": "$CLAUDE_PROJECT_DIR/.claude/hooks/detect-code-change.sh",
"timeout": 10
}
]
}
]
}
}
``

  1. Perform some operations that trigger the hooks (e.g., have Claude edit a file)
  1. Exit the session with /exit
  1. Resume the session with claude --resume or /resume
  1. Start typing a message - observe screen flickering on every keystroke

Expected Behavior

Typing in the input dialog should be smooth without any screen flickering.

Actual Behavior

  • Screen flickers/redraws on every single keystroke
  • The "Running PostToolUse hook…" messages appear in the replayed history
  • The CLI becomes very difficult to use due to the constant flickering

Investigation Done

  • Tested with hooks disabled: Flickering still occurs after resume, even when hooks are removed from settings.json
  • Checked for stale processes: No orphaned hook processes running
  • Cleaned stale IDE lock files: Found and removed 6 stale lock files in ~/.claude/ide/, but issue persists

Workaround

Start a fresh session instead of using /resume.

Additional Context

The issue appears to be related to session resume functionality rather than the hooks themselves, since disabling hooks does not fix the problem. The hooks only correlate with the issue because they were triggered during the original session.

What Should Happen?

Typing in the input dialog should be smooth without any screen flickering, and not every key stroke triggering a post tool use hook.

Error Messages/Logs

Steps to Reproduce

chatissueflicker.txt

github-issue-flicker.md

detect-code-change.sh

Claude Model

Opus

Is this a regression?

I don't know

Last Working Version

_No response_

Claude Code Version

2.1.11

Platform

Anthropic API

Operating System

macOS

Terminal/Shell

Terminal.app (macOS)

Additional Information

my post tool use hooks keep triggering, and this only happens when i resume the chat. new chats don't have this issue!

View original on GitHub ↗

This issue has 3 comments on GitHub. Read the full discussion on GitHub ↗