zed-industries/zed · error

could not start HTTP client

Error message

could not start HTTP client

What it means

Fires in the edit prediction CLI's init when constructing the ReqwestClient (with proxy and User-Agent settings) fails, so the headless evaluation harness has no HTTP client for API calls or language-server downloads.

Source

Thrown at crates/edit_prediction_cli/src/headless.rs:58

    cx.set_global(settings_store);

    // Set User-Agent so we can download language servers from GitHub
    let user_agent = format!(
        "Zeta CLI/{} ({}; {})",
        app_version,
        std::env::consts::OS,
        std::env::consts::ARCH
    );
    let proxy_str = ProxySettings::get_global(cx).proxy.to_owned();
    let proxy_url = proxy_str
        .as_ref()
        .and_then(|input| input.parse().ok())
        .or_else(read_proxy_from_env);
    let http = {
        let _guard = Tokio::handle(cx).enter();

        ReqwestClient::proxy_and_user_agent(proxy_url, &user_agent)
            .expect("could not start HTTP client")
    };
    cx.set_http_client(Arc::new(http));

    let client = Client::production(cx);
    cx.set_http_client(client.http_client());

    let app_db = AppDatabase::new();
    cx.set_global(app_db);

    let git_binary_path = None;
    let fs = RealFs::new(git_binary_path, cx.background_executor().clone());

    let mut languages = LanguageRegistry::new(cx.background_executor().clone());
    languages.set_language_server_download_dir(paths::languages_dir().clone());
    let languages = Arc::new(languages);

    let user_store = cx.new(|cx| UserStore::new(client.clone(), cx));

View on GitHub (pinned to 9d272b0363)

Solutions

  1. Check that the configured proxy URL (settings or HTTP_PROXY env) parses correctly
  2. Unset an invalid proxy and retry
  3. Verify TLS/runtime initialization succeeded inside the tokio context
Defensive patterns

Strategy: retry

When it happens

Trigger: Thrown at crates/edit_prediction_cli/src/headless.rs:58 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of zed-industries/zed@9d272b0363 (2026-08-20). Data as JSON: /api/errors/32375e77aa36b459. Report an issue: GitHub.