BigPizzaV3/CodexPlusPlus · error · anyhow::Error

session import task failed: {error}

Error message

session import task failed: {error}

What it means

Wrapped failure thrown by LauncherDataService::import_session_file when the spawn_blocking task performing the session import fails at the task level (JoinError), formatted as "session import task failed: {error}". Indicates the blocking wrapper died; the import's own validation/import errors are returned by the inner call, not this wrapper.

Source

Thrown at apps/codex-plus-launcher/src/main.rs:783

        .with_codex_home(codex_plus_core::codex_sqlite::default_codex_home_dir())
    }

    async fn export_session_file(&self, session: SessionRef) -> anyhow::Result<Value> {
        let home = codex_plus_core::codex_sqlite::default_codex_home_dir();
        tokio::task::spawn_blocking(move || {
            codex_plus_core::session_share::export_rollout(&home, &session.session_id)
        })
        .await
        .map_err(|error| anyhow::anyhow!("session export task failed: {error}"))?
    }

    async fn import_session_file(&self, payload: Value) -> anyhow::Result<Value> {
        let home = codex_plus_core::codex_sqlite::default_codex_home_dir();
        tokio::task::spawn_blocking(move || {
            codex_plus_core::session_share::import_rollout(&home, &payload)
        })
        .await
        .map_err(|error| anyhow::anyhow!("session import task failed: {error}"))?
    }
}

struct LauncherRuntimeService {
    debug_port: Mutex<u16>,
    websocket_url: Mutex<Option<String>>,
    user_scripts: UserScriptManager,
}

impl LauncherRuntimeService {
    fn new(debug_port: u16, user_scripts: UserScriptManager) -> Self {
        Self {
            debug_port: Mutex::new(debug_port),
            websocket_url: Mutex::new(None),
            user_scripts,
        }
    }

View on GitHub (pinned to f2074595a2)

Solutions

  1. 查看导入任务的 panic 堆栈
  2. 确认 payload 是合法的导出文件内容
  3. 重试导入
  4. 修复导入逻辑中对畸形 payload 的防御性校验
Defensive patterns

Strategy: retry

When it happens

Trigger: Thrown at apps/codex-plus-launcher/src/main.rs:783 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of BigPizzaV3/CodexPlusPlus@f2074595a2 (2026-08-23). Data as JSON: /api/errors/0440d3c3fb6b338a. Report an issue: GitHub.