Repository navigation
Deliver queued GOA tasks to sessions on other hosts and sessions already done - #30
Merged
Merged
Conversation
…ady done Only a change of a session on GOA's own host gave a queued task. The app's word for another host's session (goa.worker) moved the board and stopped there, and the stall watch skipped any session that said it was done, so a task queued for another host's session never went in. Neither did one for a session whose turn ended before the task was queued, or one brought back by a restart with no state. Tasks now go one at a time, the next only once the one before stops running. What can't go in fails on the board and tells GOA, which a failed typing didn't do, and a task queued on a session later hibernated brings it back. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Owner
Author
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.
A task delegated to a busy session shows as queued, but often never reaches it.
Cause
MethodGOAWorker(daemon/rpc_goa.go:18) updated the board and stopped. Only a change on GOA's own host calledgoaDeliver(daemon/goa.go:204).queuedCanGo(daemon/goa_stall.go:117) requiredStateStale, so a session that saiddonewas skipped, on any host. So was a session with no state after a restart.daemon/goa_tasks.go,goaDeliver). A task whose session was gone or hibernated stayed queued for good.TestGOAQueuedTaskReachesAnotherHostfails without the fix:never: the first went in.Change
goaWorkerSeen), so its turn's end delivers.done, or to an agent with no state and a free prompt, once its screen has been still for 20 seconds with nothing running.No protocol change, so an older daemon on another host works as before.
Tests
On enowxlabs: the whole
daemonpackage passes, and the new tests pass 3 of 3 runs: another host, one at a time, already done, restart with a queued task, and what can't go in.TestHibernateByHandAndWakeandTestAlwaysAllowHibernateAndClosefail intermittently here, onmaintoo.Not run: a real Mac GOA with a real worker on another host, or a real update between queueing and delivery. The restart test uses a stand-in agent.
Touches no
go.mod,version/orcloud/, so merging doesn't deploy the cloud.🤖 Generated with Claude Code