From 5b0d9df1d0de3986af96b6871796b94b54c32783 Mon Sep 17 00:00:00 2001 From: Abhinav Date: Tue, 28 Apr 2026 17:08:12 -0700 Subject: [PATCH] Increase plugin hook env test timeout (#20100) # Why `plugin_hook_sources_run_with_plugin_env_and_plugin_source` can still fail on Windows after the earlier file-based assertion cleanup because the hook process itself occasionally exceeds the old 5s timeout under CI load. When that happens, the hook run ends as `Failed` before the test can inspect its structured output. The Windows Bazel failure showed the hook run itself failing after nearly 8 seconds: ```text ---- engine::tests::plugin_hook_sources_run_with_plugin_env_and_plugin_source stdout ---- thread 'engine::tests::plugin_hook_sources_run_with_plugin_env_and_plugin_source' panicked at hooks/src\engine\mod_tests.rs:428:5: assertion failed: `(left == right)` Diff < left / right > : Completed ... test result: FAILED. 78 passed; 1 failed; 0 ignored; 0 measured; 0 filtered out; finished in 7.96s ``` # What - raise the flaky plugin hook env test timeout from 5s to 10s so it matches the other executed hook tests in this module # Validation - `cargo test -p codex-hooks` --- codex-rs/hooks/src/engine/mod_tests.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/codex-rs/hooks/src/engine/mod_tests.rs b/codex-rs/hooks/src/engine/mod_tests.rs index 06ec3b251..886ed2255 100644 --- a/codex-rs/hooks/src/engine/mod_tests.rs +++ b/codex-rs/hooks/src/engine/mod_tests.rs @@ -373,7 +373,7 @@ print(json.dumps({ matcher: Some("Bash".to_string()), hooks: vec![HookHandlerConfig::Command { command: format!("python3 {}", script_path.display()), - timeout_sec: Some(5), + timeout_sec: Some(10), r#async: false, status_message: None, }],