zed-industries/zed · error · LoadError
Loading sessions are not supported by this agent.
Error message
Loading sessions are not supported by this agent.
What it means
load_session restores an existing conversation via ACP session/load, but only when the agent advertised loadSession in its initialize capabilities. When agent_capabilities.load_session is false, the call fails fast with LoadError::Other instead of sending an RPC the agent would reject or mishandle.
Source
Thrown at crates/agent_servers/src/acp.rs:1738
}
fn supports_session_additional_directories(&self) -> bool {
self.agent_capabilities
.session_capabilities
.additional_directories
.is_some()
}
fn load_session(
self: Rc<Self>,
session_id: acp::SessionId,
project: Entity<Project>,
work_dirs: PathList,
title: Option<SharedString>,
cx: &mut App,
) -> Task<Result<Entity<AcpThread>>> {
if !self.agent_capabilities.load_session {
return Task::ready(Err(anyhow!(LoadError::Other(
"Loading sessions is not supported by this agent.".into()
))));
}
let mcp_servers = mcp_servers_for_project(&project, cx);
self.open_or_create_session(
session_id,
project,
work_dirs,
title,
move |connection, session_id, directories| {
Box::pin(async move {
let response = connection
.send_request(
directories.into_load_session_request(session_id.clone(), mcp_servers),
)
.block_task()
.awaitView on GitHub (pinned to bc538def45)
Solutions
- Check agent_capabilities.load_session before offering or performing session load
- Start a new session instead of loading for agents without the capability
- Upgrade the agent to a build that advertises session load
Example fix
// before
let thread = connection.load_session(id.clone(), project, dirs, None, cx).await?;
// after — fall back to a new session when resume is unsupported
let thread = if connection.agent_capabilities.load_session {
connection.load_session(id, project, dirs, None, cx).await?
} else {
connection.open_session(project, dirs, cx).await?
}; Defensive patterns
Strategy: type-guard
Type guard
fn supports_session_load(connection: &AcpAgentConnection) -> bool {
connection.agent_capabilities.load_session
} Try / catch
Check agent_capabilities.load_session first; if the load fails with this error, degrade gracefully by starting a new session instead of resuming.
Prevention
- Read capabilities from the initialize handshake and let them drive resume UI
- Test third-party ACP agents for loadSession support before advertising history restore to users
When it happens
Trigger: load_session invoked on an ACP agent whose capabilities do not include load_session — stateless agents, older agent versions, or callers that skip the capability check before offering resume.
Common situations: Third-party ACP agents without conversation-resume support; UI that offers 'open previous thread' for every registered agent regardless of capability.
Related errors
- delete_session not supported
- failed to wait for agent server exit: {err}
- session was closed before load completed
- Working directory cannot be empty
- output token limit reached
AI-assisted analysis of zed-industries/zed@bc538def45 (2026-08-16).
Data as JSON: /api/errors/8da5c8b90bd5c551.
Report an issue: GitHub.