[codex] Support remote exec cwd in TUI startup (#17142)

When running with remote executor the cwd is the remote path. Today we
check for existence of a local directory on startup and attempt to load
config from it.

For remote executors don't do that.
This commit is contained in:
pakrym-oai
2026-04-08 13:09:28 -07:00
committed by GitHub
parent f383cc980d
commit e4d6702b87
11 changed files with 128 additions and 21 deletions

View File

@@ -811,12 +811,12 @@ impl Config {
/// applied yet, which risks failing to enforce required constraints.
pub async fn load_config_as_toml_with_cli_overrides(
codex_home: &Path,
cwd: &AbsolutePathBuf,
cwd: Option<&AbsolutePathBuf>,
cli_overrides: Vec<(String, TomlValue)>,
) -> std::io::Result<ConfigToml> {
let config_layer_stack = load_config_layers_state(
codex_home,
Some(cwd.clone()),
cwd.cloned(),
&cli_overrides,
LoaderOverrides::default(),
CloudRequirementsLoader::default(),