{"record":{"id":"add473a99d2a0d75","repo":"Kuberwastaken/claurst","slug":"remote-settings-unexpected-status","errorCode":null,"errorMessage":"Remote settings: unexpected status {}","messagePattern":"Remote settings: unexpected status (.+?)","errorType":"http","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src-rust/crates/core/src/remote_settings.rs","lineNumber":224,"sourceCode":"        let resp = req.send().await?;\r\n        let status = resp.status().as_u16();\r\n\r\n        match status {\r\n            304 => {\r\n                debug!(\"Remote settings: 304 Not Modified — cache still valid\");\r\n                return Ok(None);\r\n            }\r\n            204 | 404 => {\r\n                debug!(\"Remote settings: {} — no settings configured\", status);\r\n                return Ok(Some(Value::Object(Default::default())));\r\n            }\r\n            200 => {}\r\n            401 | 403 => {\r\n                // Auth errors are terminal — no point retrying\r\n                anyhow::bail!(\"Remote settings: not authorized ({})\", status);\r\n            }\r\n            other => {\r\n                anyhow::bail!(\"Remote settings: unexpected status {}\", other);\r\n            }\r\n        }\r\n\r\n        let body: Value = resp.json().await?;\r\n\r\n        // Try to parse as the expected response shape, but be permissive —\r\n        // accept raw settings object if the wrapper is missing.\r\n        let (settings, _checksum) = if let Ok(parsed) =\r\n            serde_json::from_value::<RemoteSettingsResponse>(body.clone())\r\n        {\r\n            (parsed.settings, parsed.checksum)\r\n        } else if body.is_object() {\r\n            (body, None)\r\n        } else {\r\n            anyhow::bail!(\"Remote settings: unexpected response shape\");\r\n        };\r\n\r\n        Ok(Some(settings))\r","sourceCodeStart":206,"sourceCodeEnd":242,"githubUrl":"https://github.com/Kuberwastaken/claurst/blob/b0637c97ec34144387cbf2f74f65df6d16a6cef1/src-rust/crates/core/src/remote_settings.rs#L206-L242","documentation":"The remote-settings endpoint returned a status outside the handled set (304/204/404/200/401/403) — the formatted code is the unclassified status, typically a 5xx or proxy error. The fetch aborts so the retry wrapper can decide whether to try again.","triggerScenarios":"Thrown at src-rust/crates/core/src/remote_settings.rs:224 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Let the retry wrapper re-fetch; transient 5xx responses usually clear","Check the settings API base URL and network path if the status persists","Cached settings remain in use until a fetch succeeds"],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"b0637c97ec34144387cbf2f74f65df6d16a6cef1","analyzedAt":"2026-09-10T00:24:58.650Z","contentChangedAt":"2026-09-10T00:24:58.650Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}