zed-industries/zed · error · anyhow::Error

No kernel specs found

Error message

No kernel specs found

What it means

Post-parse guard in list_remote_kernelspecs(): the server's kernelspecs response deserialized fine but yielded an empty list, meaning the remote server exposes no kernels. Raised as an error instead of returning an empty spec list so callers fail loudly.

Source

Thrown at crates/repl/src/kernels/remote_kernels.rs:103

    let mut body = response.into_body();

    let mut body_bytes = Vec::new();
    body.read_to_end(&mut body_bytes).await?;

    let kernel_specs: KernelSpecsResponse = serde_json::from_slice(&body_bytes)?;

    let remote_kernelspecs = kernel_specs
        .kernelspecs
        .into_iter()
        .map(|(name, spec)| RemoteKernelSpecification {
            name,
            url: remote_server.base_url.clone(),
            token: remote_server.token.clone(),
            kernelspec: spec.spec,
        })
        .collect::<Vec<RemoteKernelSpecification>>();

    anyhow::ensure!(!remote_kernelspecs.is_empty(), "No kernel specs found");
    Ok(remote_kernelspecs)
}

impl PartialEq for RemoteKernelSpecification {
    fn eq(&self, other: &Self) -> bool {
        self.name == other.name && self.url == other.url
    }
}

impl Eq for RemoteKernelSpecification {}

pub struct RemoteRunningKernel {
    remote_server: RemoteServer,
    _receiving_task: Task<Result<()>>,
    _routing_task: Task<Result<()>>,
    http_client: Arc<dyn HttpClient>,
    pub working_directory: std::path::PathBuf,
    pub request_tx: mpsc::Sender<JupyterMessage>,

View on GitHub (pinned to f4178619ac)

Solutions

  1. Install at least one kernel on the remote server
  2. Verify the correct remote server/token is configured
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at crates/repl/src/kernels/remote_kernels.rs:103 when the library encounters an invalid state.

Common situations: See trigger scenarios.


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