{"record":{"id":"aeaed57a55fcef4b","repo":"openai/codex","slug":"runtime-code-cell-runtime-cell-id-in-thread-thr","errorCode":null,"errorMessage":"runtime code cell {runtime_cell_id} in thread {thread_id} mapped to both {existing} and {code_cell_id}","messagePattern":"runtime code cell (.+?) in thread (.+?) mapped to both (.+?) and (.+?)","errorType":"exception","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"codex-rs/rollout-trace/src/reducer/code_cell.rs","lineNumber":583,"sourceCode":"        format!(\"code_cell:{model_visible_call_id}\")\n    }\n\n    /// Records the thread-local runtime cell id to reduced code-cell id mapping.\n    ///\n    /// Runtime ids can repeat across threads, so callers must provide the owning\n    /// thread id when creating or resolving this bridge.\n    pub(super) fn record_runtime_code_cell_id(\n        &mut self,\n        thread_id: &str,\n        runtime_cell_id: &str,\n        code_cell_id: &str,\n    ) -> Result<()> {\n        let key = runtime_code_cell_key(thread_id, runtime_cell_id);\n        if let Some(existing) = self.code_cell_ids_by_runtime.get(&key) {\n            if existing == code_cell_id {\n                return Ok(());\n            }\n            bail!(\n                \"runtime code cell {runtime_cell_id} in thread {thread_id} mapped to both \\\n                 {existing} and {code_cell_id}\"\n            );\n        }\n        self.code_cell_ids_by_runtime\n            .insert(key, code_cell_id.to_string());\n        Ok(())\n    }\n\n    /// Resolves a runtime cell id to the reduced code-cell id for the given thread.\n    pub(super) fn code_cell_id_for_runtime_cell_id(\n        &self,\n        thread_id: &str,\n        runtime_cell_id: &str,\n        event_name: &str,\n    ) -> Result<CodeCellId> {\n        self.code_cell_id_for_runtime_cell_id_if_known(thread_id, runtime_cell_id)\n            .with_context(|| {","sourceCodeStart":565,"sourceCodeEnd":601,"githubUrl":"https://github.com/openai/codex/blob/339751715c64496cb86246bfb3935f40e309dd3d/codex-rs/rollout-trace/src/reducer/code_cell.rs#L565-L601","documentation":"Error \"runtime code cell {runtime_cell_id} in thread {thread_id} mapped to both {existing} and {code_cell_id}\" thrown in openai/codex.","triggerScenarios":"Thrown at codex-rs/rollout-trace/src/reducer/code_cell.rs:583 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"339751715c64496cb86246bfb3935f40e309dd3d","analyzedAt":"2026-08-25T05:35:09.876Z","schemaVersion":2},"datasetVersion":"2026-08-25T06:17:31.827Z"}