Repository navigation
Add the offline cross-runtime collaboration harness - #201
Merged
Merged
Conversation
hsliuustc0106
commented
Oct 17, 2026
hsliuustc0106
left a comment
Contributor
Author
There was a problem hiding this comment.
Looks good for the offline slice: scope stays in dev/interop/, fail-closed contract, and CI is green. Two non-blocking nits inline; keep draft until #198 / real-runtime gaps are tracked, not claimed.
| } | ||
| const current = this.task(task.id) | ||
| this.checkEvent(current, event) | ||
| this.runtime.submit(current.sessionId, event.turnId, contentOf(event)) |
Contributor
Author
There was a problem hiding this comment.
Nit: bare catch also swallows unexpected requireValue failures after a successful submit. Prefer treating only known transport/recovery errors as uncertain and rethrowing the rest.
| for (const key of Object.keys(budget)) requireValue(Number.isSafeInteger(budget[key]) && budget[key] > 0 && budget[key] <= DEFAULTS[key], 'invalid budget') | ||
| return this.journal.transaction(state => { | ||
| requireValue(!get(state.tasks, id) && Object.keys(state.tasks).length < 64, 'duplicate task or journal full') | ||
| requireValue(Object.values(state.tasks).filter(t => !TERMINAL.has(t.status) && t.status !== 'result-ready').length < 2, 'concurrency limit') |
Contributor
Author
There was a problem hiding this comment.
Nit: concurrency ignores result-ready, so many unfinished accepts won’t block new enrolls. Fine if intentional — worth one README line.
hsliuustc0106
marked this pull request as ready for review
October 17, 2026 15:55
Refs #200. Restrict uncertain recovery to explicit transport or reconciliation errors; retain cancellation races as stopped outcomes and clarify result-ready execution slots.
This was referenced Oct 17, 2026
This was referenced Oct 17, 2026
Closed
Birfy
pushed a commit
to Birfy/FlyBot
that referenced
this pull request
Oct 18, 2026
…sions (ThinkFlowLab#317) Fixes ThinkFlowLab#316. Refs ThinkFlowLab#198 (first P0 box: align this issue, the pilot doc and the offline scope). Docs-only. `docs/interop/opencode-pilot.md` now states the settled decisions (decision comment on ThinkFlowLab#198, 2026-10-18) instead of contradicting them: phase 1 is single-owner same-room on the fixture task (edit + run tests, no network; human approval for outbound network/credentials/budget top-up/final acceptance), A2A stays non-required, and the OpenCode process is a FlyBot-driver-owned supervised child rather than an operator-started server. `docs/interop/room-participants.md` records the same phase-1 decisions and replaces the operator-controlled binding with the supervised-child responsibility. The DM/offline experiment's own constraints (Bot Social same-owner rejection, distinct synthetic owners) are kept and clearly scoped to the cross-home path; slices updated (slice 1 merged as ThinkFlowLab#201, slice 2 marked cross-home, slice 4 re-scoped single-owner). The v1 codec/journal/budget/projection contract is untouched. What I ran at tip `ecb6e04`: full `TZ=UTC npm run verify` — all suites green except the 3 known macOS-only `room-collaboration.test.js` failures caused by the tmpdir-symlink bug fixed in ThinkFlowLab#315 (this branch intentionally does not carry that code change; CI runs Linux and is unaffected). What I did not run: smoke test and bench (no code change).
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.
Fixes #200. Refs #198 and the design in #199.
Add a development-only offline collaboration harness with distinct synthetic owners, independent delivery/execution approvals, dedicated task sessions, clarification and explicit simulated requester acceptance. The versioned codec, durable inbox/turn journal, scripted runtime and fake clock cover isolation, conflicting/duplicate/out-of-order events, revocation, recovery, cancellation and persisted budgets. Same-owner friendship stays forbidden; no shipped runtime or authorization path is added.
Recover only explicit
RuntimeRecoveryErrortransport/evidence failures asuncertain; assertion, storage and programming errors propagate. Cancellation races record a stopped outcome without reviving work. Document thatresult-readytasks intentionally free their execution slot while remaining within the 64-task journal bound.Verification at
b05157a01997d3c608b6cc13ca29a3166508f4dc:DSH_HARNESS=/workspace/FlyBot/core/dev/harness npm run verify: pass, 1,054 tests (32 interop tests), 0 failed/skipped.For external review of this tip; #198, real-runtime work and team-mode gates remain open.