{"record":{"id":"a31748456cd0cc3b","repo":"tinyhumansai/openhuman","slug":"searxng-request-failed-err","errorCode":null,"errorMessage":"SearXNG request failed: {err}","messagePattern":"SearXNG request failed: (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/openhuman/search/tools/searxng.rs","lineNumber":183,"sourceCode":"        }\n\n        tracing::debug!(\n            query_len = query.chars().count(),\n            max_results,\n            categories = ?categories,\n            timeout_secs = self.timeout_secs,\n            \"[searxng] GET /search\"\n        );\n\n        let response = self\n            .http_client\n            .get(url.clone())\n            .timeout(Duration::from_secs(self.timeout_secs))\n            .send()\n            .await\n            .map_err(|err| {\n                tracing::warn!(error = %err, \"[searxng] request failed\");\n                anyhow::anyhow!(\"SearXNG request failed: {err}\")\n            })?;\n\n        let status = response.status();\n        if !status.is_success() {\n            let body = response.text().await.unwrap_or_default();\n            let detail = utf8_safe_prefix_at_byte_boundary(&body, 500);\n            tracing::warn!(status = %status, \"[searxng] non-2xx response: {detail}\");\n            anyhow::bail!(\"SearXNG returned {status}: {detail}\");\n        }\n\n        let raw: RawSearxngResponse = response.json().await.map_err(|err| {\n            tracing::warn!(error = %err, \"[searxng] failed to parse JSON response\");\n            anyhow::anyhow!(\"Failed to parse SearXNG response: {err}\")\n        })?;\n\n        let results = normalize_results(raw, max_results);\n        tracing::debug!(result_count = results.len(), \"[searxng] search complete\");\n","sourceCodeStart":165,"sourceCodeEnd":201,"githubUrl":"https://github.com/tinyhumansai/openhuman/blob/749120085864ce16e0f273c7b86fac7740b39c5b/src/openhuman/search/tools/searxng.rs#L165-L201","documentation":"Transport-failure mapping in SearxngTool::search: the reqwest GET /search call to the SearXNG instance failed before a response status could be read — instance down, DNS/connection failure, TLS problem, or the per-request timeout (self.timeout_secs) fired. The reqwest error is logged at warn and rewrapped; this is distinct from a non-2xx status, which is handled in the following block.","triggerScenarios":"Thrown at src/openhuman/search/tools/searxng.rs:183 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Verify the configured SearXNG base URL is correct and the instance is up (curl its /search endpoint).","Retry; transient network errors often resolve.","If timeouts recur, raise the timeout or check proxy/firewall paths to the instance."],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"749120085864ce16e0f273c7b86fac7740b39c5b","analyzedAt":"2026-08-17T21:21:45.363Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}