Fall back to manual approval when Guardian times out

This commit is contained in:
Katia Bazzi
2026-06-10 17:01:57 -07:00
parent 72667f4f41
commit 2eff458cd9
17 changed files with 500 additions and 27 deletions
+8 -1
View File
@@ -231,6 +231,7 @@ pub struct TestCodexBuilder {
user_shell_override: Option<Shell>,
exec_server_url: Option<String>,
extensions: Arc<ExtensionRegistry<Config>>,
session_source: SessionSource,
}
impl TestCodexBuilder {
@@ -320,6 +321,11 @@ impl TestCodexBuilder {
self
}
pub fn with_session_source(mut self, session_source: SessionSource) -> Self {
self.session_source = session_source;
self
}
pub fn with_windows_cmd_shell(self) -> Self {
if cfg!(windows) {
self.with_user_shell(get_shell_by_model_provided_path(&PathBuf::from("cmd.exe")))
@@ -511,7 +517,7 @@ impl TestCodexBuilder {
let thread_manager = ThreadManager::new(
&config,
codex_core::test_support::auth_manager_from_auth(auth.clone()),
SessionSource::Exec,
self.session_source.clone(),
Arc::clone(&environment_manager),
Arc::clone(&self.extensions),
/*analytics_events_client*/ None,
@@ -1084,6 +1090,7 @@ pub fn test_codex() -> TestCodexBuilder {
user_shell_override: None,
exec_server_url: None,
extensions: empty_extension_registry(),
session_source: SessionSource::Exec,
}
}