openai/codex · error · anyhow::Error
failed to initialize in-process app-server client: {err}
Error message
failed to initialize in-process app-server client: {err} What it means
Error "failed to initialize in-process app-server client: {err}" thrown in openai/codex.
Source
Thrown at codex-rs/exec/src/lib.rs:815
)
}
};
// When --yolo (dangerously_bypass_approvals_and_sandbox) is set, also skip the git repo check
// since the user is explicitly running in an externally sandboxed environment.
if !skip_git_repo_check
&& !dangerously_bypass_approvals_and_sandbox
&& get_git_repo_root(&default_cwd).is_none()
{
eprintln!("Not inside a trusted directory and --skip-git-repo-check was not specified.");
std::process::exit(1);
}
let mut request_ids = RequestIdSequencer::new();
let mut client = InProcessAppServerClient::start(in_process_start_args)
.await
.map_err(|err| {
anyhow::anyhow!("failed to initialize in-process app-server client: {err}")
})?;
// Resolve resume and fork through existing app-server thread lifecycle APIs.
let (primary_thread_id, fallback_session_configured) = if let Some(ExecCommand::Resume(args)) =
command.as_ref()
{
if let Some(thread_id) =
resolve_resume_thread_id(&client, &config, state_db.as_ref(), args).await?
{
let response: ThreadResumeResponse = send_request_with_response(
&client,
ClientRequest::ThreadResume {
request_id: request_ids.next(),
params: thread_resume_params_from_config(
&config,
thread_id,
resume_approvals_reviewer_override,
),View on GitHub (pinned to 339751715c)
Solutions
- Investigate the in-process app-server client initialization error.
When it happens
Trigger: Thrown at codex-rs/exec/src/lib.rs:815 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of openai/codex@339751715c (2026-08-25).
Data as JSON: /api/errors/d21c1ee20e084bdc.
Report an issue: GitHub.