{"record":{"id":"b8efdb3385274a3e","repo":"openai/codex","slug":"a-different-workload-identity-configuration-is-alr","errorCode":null,"errorMessage":"a different workload identity configuration is already active in this process","messagePattern":"a different workload identity configuration is already active in this process","errorType":"exception","errorClass":"WorkloadIdentitySessionError","httpStatus":null,"severity":"error","filePath":"codex-rs/login/src/auth/workload_identity.rs","lineNumber":115,"sourceCode":"        )?;\n        WorkloadIdentityExchange::new(config, self.token_url, self.http_client_factory)\n    }\n}\n\n#[derive(Clone, PartialEq, Eq)]\nstruct WorkloadIdentityFingerprint {\n    assertion_file: PathBuf,\n    environment: WorkloadIdentityEnvironment,\n    federation_rule_id: String,\n    token_url: String,\n    workload_identity_context: Option<String>,\n}\n\n#[derive(Debug, Error)]\npub(super) enum WorkloadIdentitySessionError {\n    #[error(transparent)]\n    Exchange(#[from] WorkloadIdentityError),\n    #[error(\"a different workload identity configuration is already active in this process\")]\n    ConflictingConfiguration,\n    #[error(\"the workload identity process-session registry is unavailable\")]\n    RegistryUnavailable,\n    #[error(\"{0}\")]\n    InvalidConfiguration(String),\n}\n\n/// Returns whether workload identity was selected through process configuration.\n///\n/// Either marker selects workload identity. Partial configuration then fails validation rather\n/// than falling back to another credential source.\npub fn is_workload_identity_selected() -> bool {\n    ProcessEnvironment::read().has_marker()\n}\n\nfn resolve_config(\n    chatgpt_base_url: &str,\n    environment: ProcessEnvironment,","sourceCodeStart":97,"sourceCodeEnd":133,"githubUrl":"https://github.com/openai/codex/blob/339751715c64496cb86246bfb3935f40e309dd3d/codex-rs/login/src/auth/workload_identity.rs#L97-L133","documentation":"WorkloadIdentitySessionError::ConflictingConfiguration: a process-global slot already holds a workload identity session whose fingerprint (assertion file, environment, federation rule, token URL, context) differs from the one being started. Only one configuration can be active per process, so the second, different session is refused.","triggerScenarios":"Thrown at codex-rs/login/src/auth/workload_identity.rs:115 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Reuse the already-active workload identity session instead of initializing a second, different one","Ensure all components in the process derive from the same workload identity config values","Restart the process if the configuration genuinely must change mid-run"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"339751715c64496cb86246bfb3935f40e309dd3d","analyzedAt":"2026-08-25T05:35:09.876Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}