openai/codex · error · anyhow::Error

no .app bundle found at

Error message

no .app bundle found at {mount_point}

What it means

find_codex_app_in_mount: the mounted DMG contains neither a top-level Codex.app directory nor any *.app bundle entry, so no app could be located to install. The installer image is unexpected or corrupted.

Solutions

  1. Re-download the installer DMG from the official source
  2. Browse the mounted volume in Finder to inspect its contents
  3. Report it if the official DMG genuinely lacks an app bundle
Defensive patterns

Strategy: fallback

When it happens

Trigger: Thrown at codex-rs/cli/src/desktop_app/mac.rs:313 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/7ea702d1d8b8ed88. Report an issue: GitHub.

Appendix: source

Thrown at codex-rs/cli/src/desktop_app/mac.rs:313

    let direct = mount_point.join("Codex.app");
    if direct.is_dir() {
        return Ok(direct);
    }

    for entry in std::fs::read_dir(mount_point).with_context(|| {
        format!(
            "failed to read {mount_point}",
            mount_point = mount_point.display()
        )
    })? {
        let entry = entry.context("failed to read mount directory entry")?;
        let path = entry.path();
        if path.extension().is_some_and(|ext| ext == "app") && path.is_dir() {
            return Ok(path);
        }
    }

    anyhow::bail!(
        "no .app bundle found at {mount_point}",
        mount_point = mount_point.display()
    );
}

async fn copy_app_bundle(src_app: &Path, dest_app: &Path) -> anyhow::Result<()> {
    let status = Command::new("ditto")
        .arg(src_app)
        .arg(dest_app)
        .status()
        .await
        .context("failed to invoke `ditto`")?;

    if status.success() {
        return Ok(());
    }
    anyhow::bail!("ditto copy failed with {status}");
}

View on GitHub (pinned to 339751715c)