tinyhumansai/openhuman · error

failed to build Seltz HTTP client

Error message

failed to build Seltz HTTP client

What it means

Panic payload on the Seltz search tool's client build in new(): the platform tls_client_builder() with http1_only and computed timeouts (max(1) seconds) failed at build(). Since every input is a constant or sanitized config value, this is a TLS/proxy environment failure raised at tool construction time.

Source

Thrown at src/openhuman/search/tools/seltz.rs:73

    timeout_secs: u64,
    http_client: reqwest::Client,
}

impl SeltzSearchTool {
    pub fn new(
        api_key: Option<String>,
        api_url: Option<String>,
        max_results: usize,
        timeout_secs: u64,
    ) -> Self {
        let timeout = timeout_secs.max(1);
        // Platform-appropriate TLS backend — see [`crate::openhuman::util::tls`].
        let http_client = crate::openhuman::util::tls::tls_client_builder()
            .http1_only()
            .timeout(Duration::from_secs(timeout))
            .connect_timeout(Duration::from_secs(10))
            .build()
            .expect("failed to build Seltz HTTP client");

        Self {
            api_key,
            api_url: api_url.unwrap_or_else(|| DEFAULT_API_URL.to_string()),
            max_results: max_results.clamp(1, 20),
            timeout_secs: timeout,
            http_client,
        }
    }

    fn render_results_plain(&self, docs: &[SeltzDocument], query: &str) -> String {
        if docs.is_empty() {
            return format!("No results found for: {}", query);
        }

        let mut lines = vec![format!("Search results for: {} (via Seltz)", query)];

        for (i, doc) in docs.iter().take(self.max_results).enumerate() {

View on GitHub (pinned to 7491200858)

Solutions

  1. Verify the TLS backend and proxy settings of the host environment
  2. Propagate a Result from new() so the tool registers as unavailable instead of panicking
  3. Log the underlying reqwest error before the panic for diagnosis
Defensive patterns

Strategy: try-catch

When it happens

Trigger: Thrown at src/openhuman/search/tools/seltz.rs:73 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of tinyhumansai/openhuman@7491200858 (2026-08-17). Data as JSON: /api/errors/dc7e3f1e8ed6299b. Report an issue: GitHub.