Skip to content

armgit / herdr

Public Imported from GitHub
0

the runtime your coding agents live on

fix: detect codex interrupt status headers

Ogulcan Celik27a028aeae0b
diff --git a/docs/next/CHANGELOG.md b/docs/next/CHANGELOG.md
index 3c5f21405..ddf9cc6bc 100644
--- a/docs/next/CHANGELOG.md
+++ b/docs/next/CHANGELOG.md
@@ -3,6 +3,7 @@
## Unreleased
### Fixed
+- Codex panes now stay marked working when the live status header uses reasoning-summary text such as `Investigating code output` instead of the literal `Working` label. (#501)
- Native pane URL clicks now use Cmd-click on macOS and Ctrl-click on other platforms.
- Windows beta installs now default to the preview channel, persist `channel = "preview"` during install, reject switching to stable until stable Windows builds exist, and update through the Windows installer without probing unsupported live-handoff/session status paths.
- Pane output now renders flag emoji and other multi-codepoint grapheme clusters as complete symbols instead of blank cells. (#243)
diff --git a/src/detect/agents/codex.rs b/src/detect/agents/codex.rs
index 9870bca67..a53d93580 100644
--- a/src/detect/agents/codex.rs
+++ b/src/detect/agents/codex.rs
@@ -152,6 +152,7 @@ fn codex_working_status_line(line: &str) -> bool {
trimmed.starts_with('•')
&& (trimmed.contains("Working (")
|| trimmed.contains("Waiting for background terminal (")
+ || lower.contains(" • esc to interrupt")
|| lower.contains("reviewing approval request (")
|| (lower.contains("reviewing ") && lower.contains(" approval requests ("))
|| trimmed.contains("Booting MCP server:"))
diff --git a/src/detect/mod.rs b/src/detect/mod.rs
index 0c7ad9436..1e3a2288b 100644
--- a/src/detect/mod.rs
+++ b/src/detect/mod.rs
@@ -1566,6 +1566,18 @@ mod tests {
assert!(!detection.visible_idle);
}
+ #[test]
+ fn codex_generic_interrupt_status_above_current_prompt_stays_working() {
+ let detection = detect_agent(
+ Some(Agent::Codex),
+ "• I need to inspect more code first.\n\n• Investigating code output (44s • esc to interrupt)\n\n\n› Summarize recent commits\n\n gpt-5.5 high · ~/Codes/herdr",
+ );
+
+ assert_eq!(detection.state, AgentState::Working);
+ assert!(detection.visible_working);
+ assert!(!detection.visible_idle);
+ }
+
#[test]
fn codex_background_terminal_status_above_current_prompt_stays_working() {
let detection = detect_agent(