Repository navigation
feat(changes): --cursor-file keeps one cursor per workspace - #4
Merged
Merged
Conversation
An agent with several profiles (one spawn cron per workspace) passed the same cursor file for every workspace. Workspace B's run then read the timestamp A had just written and dropped B's changes older than that. Seen on the fleet's multi-org hosts (GC edc45a5d). The file is now a JSON object keyed by the workspace slot gc listen already uses (profile name, or key-<hash> for --token/GC_API_KEY). A bare timestamp from gc <= 0.2 is still read and upgraded on the next write. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01KWPUqhbu3go1zaJ82YpXoz
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
On multi-org agents, one workspace's worker run can lose another workspace's changes. The agent keeps a single changes cursor for all workspaces (on Ultron and Clawdia today). The run for workspace B reads the timestamp that A just wrote. Any comment in B older than that timestamp drops out of B's window. Christoph decided on GC edc45a5d: fix it in the CLI, not in the plugin.
https://groundcontrol.makerslab.ai/tasks/edc45a5d-654e-4c2b-86ba-b405927f05ea
What
gc changes --cursor-file <path>now stores one cursor per workspace:{"<slot>": "<server cursor>"}.gc listenalready uses: the profile name, orkey-<hash>for--token/GC_API_KEY. The key itself is never stored.workspaceSlot.--profile. Runs neither read nor overwrite another workspace's entry.catthe cursor file now get JSON. Nothing in the skills or the server guide does that.Tests
New e2e cases:
Existing cursor tests now read the workspace entry.
go vet,go test ./...andvalidate-skills.share green.Fleet follow-up
Plan 106 (switching from the plugin to the CLI): the spawn-cron prompts for multi-org tenants call
gc changes --profile <p> --cursor-file memory/gc-changes.json. Needs a release (0.3.0) first.🤖 Generated with Claude Code
https://claude.ai/code/session_01KWPUqhbu3go1zaJ82YpXoz