{"record":{"id":"56d874ac83c57c25","repo":"zed-industries/zed","slug":"settings-update-was-canceled","errorCode":null,"errorMessage":"Settings update was canceled","messagePattern":"Settings update was canceled","errorType":"exception","errorClass":"anyhow::Error","httpStatus":null,"severity":"error","filePath":"crates/settings_ui/src/pages/llm_providers_page.rs","lineNumber":1163,"sourceCode":"                            language_models\n                                .anthropic_compatible\n                                .get_or_insert_default()\n                                .insert(\n                                    Arc::from(provider_name.as_str()),\n                                    AnthropicCompatibleSettingsContent {\n                                        api_url: api_url.clone(),\n                                        available_models,\n                                        custom_headers: None,\n                                    },\n                                );\n                        }\n                    }\n                })\n            })?;\n\n            settings_update\n                .await\n                .map_err(|_| anyhow::anyhow!(\"Settings update was canceled\"))??;\n\n            let set_api_key = cx.update(|_window, cx| {\n                let provider = LanguageModelRegistry::read_global(cx)\n                    .provider(&provider_id)\n                    .ok_or_else(|| anyhow::anyhow!(\"Provider was not registered\"))?;\n                anyhow::Ok(provider.set_api_key(Some(api_key), cx))\n            })??;\n            set_api_key.await?;\n\n            cx.update(|window, cx| {\n                this.update(cx, |this, cx| {\n                    this.provider_configuration_views.remove(&provider_id);\n                    this.llm_provider_form = None;\n                    this.pop_sub_page(window, cx);\n                })\n            })??;\n\n            anyhow::Ok(())","sourceCodeStart":1145,"sourceCodeEnd":1181,"githubUrl":"https://github.com/zed-industries/zed/blob/5a9b9558db01a6b906cec2fb70a797affdc58cdd/crates/settings_ui/src/pages/llm_providers_page.rs#L1145-L1181","documentation":"Raised in save_llm_provider_form(): the settings update transaction was canceled before it could apply (e.g. the settings write future was dropped or the page changed), so the provider's new API URL and models were not persisted.","triggerScenarios":"Thrown at crates/settings_ui/src/pages/llm_providers_page.rs:1153 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Retry saving the provider form","Avoid closing the settings page while saving"],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"5a9b9558db01a6b906cec2fb70a797affdc58cdd","analyzedAt":"2026-08-20T19:29:52.058Z","contentChangedAt":"2026-08-20T19:29:52.058Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}