zed-industries/zed · error

Git Clone isn't supported for project guests

Error message

Git Clone isn't supported for project guests

What it means

In GitStore::git_clone: the store is in the Remote state with an upstream collab client, i.e. the caller is a project guest. Cloning repositories is only supported on the host/local side, so the request is rejected for guests.

Source

Thrown at crates/project/src/git_store.rs:3153

        &self,
        repo: String,
        path: impl Into<Arc<std::path::Path>>,
        cx: &App,
    ) -> Task<Result<()>> {
        let path = path.into();
        match &self.state {
            GitStoreState::Local { fs, .. } => {
                let fs = fs.clone();
                cx.background_executor()
                    .spawn(async move { fs.git_clone(&path, &repo).await })
            }
            GitStoreState::Remote {
                upstream_client,
                upstream_project_id,
                ..
            } => {
                if upstream_client.is_via_collab() {
                    return Task::ready(Err(anyhow!(
                        "Git Clone isn't supported for project guests"
                    )));
                }
                let request = upstream_client.request(proto::GitClone {
                    project_id: *upstream_project_id,
                    abs_path: path.to_string_lossy().into_owned(),
                    remote_repo: repo,
                });

                cx.background_spawn(async move {
                    let result = request.await?;

                    match result.success {
                        true => Ok(()),
                        false => Err(anyhow!("Git Clone failed")),
                    }
                })
            }

View on GitHub (pinned to f4178619ac)

Solutions

  1. Ask the project host to perform the clone
  2. Clone the repository locally in your own Zed window instead
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at crates/project/src/git_store.rs:3153 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/ce496e21823f626d. Report an issue: GitHub.