Skip to content

Agent: create a computer's default workspace when a controller connects - #1665

Merged
AnthonyRonning merged 1 commit into
masterfrom
codex-remotews-maple
Nov 20, 2026
Merged

AnthonyRonning merged 1 commit into
masterfrom
codex-remotews-maple

Conversation

@AnthonyRonning

@AnthonyRonning AnthonyRonning commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor

Problem

On a computer that has never opened the desktop app (a headless Linux host run as a service, for example), a paired controller cannot use that computer's default Maple Workspace. The first task sent there fails with:

/home/<user>/Documents/Maple/Workspace: No such file or directory (os error 2)

Picking another folder in the remote folder browser works. A computer whose desktop has run does not show this, because its own launch already created the folder.

Cause

navigation_bootstrap tells every client, local or remote, that its project is gui_project_root: the saved folder, or else the built-in workspace, which may not exist yet. The runtime start is what creates it.

LocalBackend::start_runtime only took that path for a request that was present and named no folder, which is what this computer's desktop sends. A controller's start arrives as TaskBootstrap, and the host dispatches it as start_runtime(account, null). With no request at all, the start fell through to the working-directory fallback meant for acp, and the workspace was never created.

Workspace creation moved into the GUI start path in #1516; the remote start has sent no request since #1170.

Fix

Any start that names no folder is a GUI start, with or without a request. Only GUIs start a runtime through LocalBackend::start_runtime: this computer's desktop and paired controllers. A controller connecting now does what the computer's own desktop does at launch, including creating the workspace when that is the folder it starts in.

Nothing changes on the wire and no capability is added. Only the execution computer needs the fix; a controller on any version benefits.

Testing

  • New test a_start_that_names_no_folder_is_a_gui_start_with_or_without_a_request: a start with no request, the desktop's request and a start that names its folder. It cannot create the real Documents/Maple/Workspace, so it shows a start with no request reaches the workspace-creating path, not the folder appearing on disk.
  • just ci in apps/maple-agent passed, and the pre-commit hook passed on the commit.
  • Not yet checked live across two computers. The ci:package label is on so the packages from this PR can be used for that check: a headless Linux host that has never run the desktop, driven from a paired macOS controller.

🤖 Generated with Claude Code


Autofix with [code]smith
Open in [code]smith · Need help on this PR? Tag @codesmith-bot with what you need.

A paired controller's runtime start reaches the host with no request.
start_runtime only chose the saved folder or the built-in workspace, and
created the workspace, when a request was present without a folder. A
controller therefore got the working-directory fallback meant for acp,
while navigation still named the workspace as its project. On a computer
that had never opened the desktop app, the first task sent to the
workspace failed with "No such file or directory".

Any start that names no folder is now a GUI start, with or without a
request, so the folder navigation names is on disk once a controller
has connected.

Co-Authored-By: Claude <noreply@anthropic.com>
@AnthonyRonning AnthonyRonning added the ci:package Build unsigned packages on this PR label Nov 20, 2026
@AnthonyRonning
AnthonyRonning merged commit 9a8e9b0 into master Nov 20, 2026
23 checks passed
@AnthonyRonning
AnthonyRonning deleted the codex-remotews-maple branch November 20, 2026 04:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci:package Build unsigned packages on this PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant