tmux parses OSC sequences itself, and the terminating BEL is absorbed as part of the string terminator rather than reaching the alert layer. Tested on tmux 3.7b with monitor-bell on and bell-action any, on an isolated server: a bare \a sets window_bell_flag to 1, while OSC 9, OSC 777, and OSC 99 all leave it at 0, whether terminated by BEL or by ST.

This is why terminal-native notification protocols are useless as a tmux state signal. They are the one genuinely vendor-neutral “I want attention” channel across agents and CLIs, but tmux either swallows them outright or, with allow-passthrough, forwards them to the outer terminal without recording anything queryable per pane.

Claude Code’s source handles the distinction deliberately: every OSC channel is wrapped for DCS passthrough except BEL, which stays raw precisely so tmux can trigger its bell-action (Claude Code Terminal Notification System). Setting preferredNotifChannel = "terminal_bell" is therefore load-bearing for any tmux widget keyed on window_bell_flag. An agent that notifies via OSC 777, as pi’s shipped notify.ts example does, stays invisible to it, which is one reason waiting state belongs in a hook-published pane option rather than in the bell.