GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
GeezerVison is showing github.com — hold-work: a marker guards a held or stopped copy's home in the CLI; tests and docs (#368) by scuttletoby · Pull Request #398 · scuttletoby/t3code Conversation
|
| Finding | Done |
|---|---|
| Security 1 (major, from before this PR) / state 3: a normal boot of a marked copy ran Connect under the shared id | Every boot of a marked home holds Connect and agent activity (above). Unit rows for a marker, an empty one and a dangling symlink. The boot test now boots the marked copy normally (no tunnel DELETE), then again unmarked (one DELETE). |
| State 1 / security 2: a failed marker write was not tested (M7 survived) | Unit row: a read-only home makes the held layer fail with PermissionDenied, before CloudLink is built and with no marker. |
State 2 / security 6: publish and t3 up --no-connect not tested where called (M9 survived) |
Rows for t3 connect publish and t3 up --no-connect on a marked home. |
| State 4 / security 5: a dangling symlink was "there" for the held boot but "absent" for the CLI | One shared check: when exists says no, a readLink that succeeds still counts. Unit rows for the CLI and the boot. |
| State 5 / security 4: copies held-booted by an older build have no marker | Docs now name them, beside never-held copies. |
| State 6: "nothing changed" | Docs and the refusal message say nothing is sent and the link and sign-in stay as they were. The CLI may still create the home's folders and signing key, as any command there does. |
State 7 / security nit: capacity lines swapped |
Undone. |
Security 3: refuse --hold-work without an explicit home |
Not in this PR (separate issue, as asked). |
Also merged origin/main three times (merge commits, no force push). The second and third merges each had a conflict in the seam list only; the third (step 2) is resolved as described above.
| Case | What happens | Test |
|---|---|---|
| Copy started held twice | The second start keeps the first marker as it is (exclusive create; AlreadyExists is fine) |
unit: "a second held start keeps the marker…" |
| Held start cannot write the marker | The held boot fails before CloudLink is built, so it does not run unmarked | unit: "a held boot that cannot write its marker fails…" |
| Held start stopped half-way, marker written | The marker is written before CloudLink is built and stays, so the CLI refuses and later boots hold | unit: "marks its home before CloudLink is built" |
| Held start stopped half-way, file created but empty | Still marked: anything at the path counts | unit: empty-marker rows (CLI and boot) |
| Held start stopped before the marker | Nothing that touches Connect ran yet. The home is as copied: see "never booted held" | (ordering test above) |
| Marked copy booted normally | Work runs. Connect and agent activity are held, and the marker is unchanged | unit rows + boot test (no tunnel DELETE, no /v1/ request) |
| Marked copy booted normally twice | Each boot reads the marker as it starts and holds the same way. Nothing writes or removes it, so the second boot sees what the first did | unit: a normal boot leaves the marker byte for byte; marked-boot rows |
| Marked copy's normal boot killed while booting | The hold is decided when the layers build, before any tunnel step. A kill earlier than that leaves nothing started; the marker stays | ordering: the marker is read as the CloudLink layer builds; tunnel steps run later |
| Marker added while a normal server runs | That server keeps Connect until it stops, and its stop releases the tunnel. The marker counts from its next start. The CLI refuses at once. Only a hand-made marker can do this: a held boot of the same home cannot start while it runs (server ownership) | docs |
| Marker deleted | The next boot runs Connect normally | boot test (third boot: one tunnel DELETE) |
| Dangling symlink at the marker path | Marked for the CLI and the server, as for the held boot | unit (CLI and boot) |
| Copy never booted held, or held-booted only by an older build (#313) | Not protected: no marker, so nothing tells it from the live home. The docs say never to run those commands against it or start it normally, and to delete the copy instead. Its first held boot on this build marks it | unit: "a home linked before markers" is let through; boot test: no marker before the held boot |
| Empty home (folder missing) | Let through, as upstream | unit |
| Marker unreadable (mode 000) or a directory | Marked | unit |
| Marker cannot be checked (home not searchable) | Refused (fails closed) | unit |
Held server of an older build running (runtime file workHeld, no marker) |
Refused, as in #313 | unit |
4b2b3447); CI shard 5 failed on the same 4 unit rows.holdWorkConnect.test.ts + connect.holdWork.test.ts 26/26, and server.holdWork.test.ts passes. Server typecheck clean.publish skips requireConnectAllowed: the publish row fails.disconnectCloud refusal removed: unlink, logout and up --no-connect fail.requireConnectAllowed, exclusive create, ordering, normal boot writing the marker, running-held check) are unchanged and still red.73be7b2d, ✓ src/holdWork.boot.test.ts.89594dfc, reverted by 47d466cc) made only the spawned server ignore the marker. Shard 5 then failed exactly at holdWork.boot.test.ts:842: expected [ { method: 'DELETE', path: '/v1/client/environment-links/<id>/tunnel' } ] to deeply equal []. The tests-only commit could not show this, because CI stops the shard after the unit failures.connect.test.ts + up.connect.test.ts: 4 rows fail on this PC on head and on base alike. These are "status asks a running server to check reachability", "asks a running server to stop its tunnel", and the two "a failed restart after --connect…" rows. They come from the host (managed policy, loopback), not from this PR. CI runs them.LD_LIBRARY_PATH, which the boot test's bare child environment drops./v1/ request from that boot.serve --hold-work copies and marked homes, the t3 connect/t3 up commands, and the fork seam pins.Fixes #368
🤖 Generated with Claude Code
Sorry, something went wrong.
There was an error while loading. Please reload this page.
…368) A held boot writes hold-work-copy.json in the copy's home before the real CloudLink is built (exclusive create: a marker already there stays). The CLI refuses connect login, link, unlink, logout, publish (turning it on) and t3 up turning Connect on or off while the marker exists, running or not, and still while the home's server runs held. Only deleting the marker clears it, and the refusal names it. - cli/connect.holdWork.test.ts runs the real commands on temp homes with a recording fetch: each is refused before any request or file change, and the same unlink on an unmarked home sends the relay delete. - The boot test checks the marker after the held and normal boots, and that stopping the normal boot sent the tunnel release itself. - docs: the marker, the policy-off unlink at start-up, the held-hooks waker and the relay client ledger clean-up. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
…am lines Co-Authored-By: Claude Opus 5.5 <[email protected]>
21d266a to
992749c
Compare
|
lens: state verdict: SAFE (head 992749c) Correctness + state lens (security is the other lens). Read-only: issue #368, the PR body, Findings
State question
Order of operations: Boot test (item 5): the assertion is specific (exactly one Mutations (each restored; tests:
|
| # | Mutation | Result |
|---|---|---|
| M1 | refusal call removed from disconnectCloud |
red (unlink, logout) |
| M2 | line removed from requireConnectAllowed |
red (link, login, up) |
| M3 | check error counts as absent | red ("cannot be checked") |
| M4 | wx → w (overwrite) |
red (second held start) |
| M5 | marker layer provided after CloudLink | red (ordering) |
| M6 | normal boot writes the marker | red |
| M7 | marker write failure swallowed | survives (finding 1) |
| M8 | running-held check removed | red |
| M9 | publish call to requireConnectAllowed removed |
survives (finding 2) |
At head, connect.holdWork.test.ts + holdWorkConnect.test.ts: 19/19.
connect.test.ts + up.connect.test.ts: 4 failures, the same 4 on base (origin/main). On this PC they come from the host: the machine-wide policy turns Connect off, and the 2 running-server rows fail too.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
lens: security verdict: SAFE (head 992749c) Security + live-safety lens (another reviewer does state). No blocker. This PR only adds refusals: nothing that reached the relay before reaches it more often now. Merge is fine. The one big gap (finding 1) was already there before this PR; I suggest a follow-up issue for it. Checked and fine
Findings
Mutations (each one restored afterwards; run on
Tests at head: State question: Run twice: the marker is kept (M7 tests this). Stopped half-way: an empty marker still refuses, and a stop before the marker is written happens before anything touches Connect (M6). Old state: a copy made before this PR, or one held on an older build, has no marker and is unprotected until its next held boot (finding 4). An empty or missing home is let through, as upstream does. 🤖 Generated with Claude Code |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ite failure, publish, up --no-connect, dangling symlink Tests only, ahead of the fix (#368 fix round): they fail on this commit. - A normal boot of a home with hold-work-copy.txt (a file, an empty one or a dangling symlink) must hold CloudLink and agent activity as a held boot does. - The boot test boots the marked copy normally (no tunnel DELETE, no relay request), then again with the marker deleted (one tunnel DELETE). It points the managed policy at a missing file so the host's policy does not apply. - A held boot that cannot write its marker fails before CloudLink is built. - t3 connect publish and t3 up --no-connect are refused on a marked home. - The CLI refuses on a dangling symlink at the marker path. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ker check for CLI and server A copy booted held once is marked (hold-work-copy.txt). A later normal boot of it used to register and, on stop, release the tunnel under the live server's environment id. HoldWorkConnect.layer and agentActivityLayer now hold when the boot is held or the home is marked, read once as the layers build. The CLI and the server share one marker check, which also counts a dangling symlink (the held boot's exclusive create keeps one) and a check that fails. Docs: a marked copy started normally, copies held-booted by builds before the marker, and what a refused command may still create. Seams: undo the unrelated reorder of the two capacity entries. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Shows that holdWork.boot.test.ts fails without the marker hold at boot. Only the spawned server (T3CODE_POSTHOG_HOST set) skips the marker, so the unit tests in the same CI shard still pass and the shard runs the boot test. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…fore its log lines Co-Authored-By: Claude Opus 5.5 <[email protected]>
Seam list conflict: main now pins the #313 lines of cli/connect.ts; this branch keeps its own pins for the current lines and takes main's cloud/CloudLink.ts entry. Co-Authored-By: Claude Opus 5.5 <[email protected]>
The probe (89594df) made shard 5 fail at holdWork.boot.test.ts:842: the marked copy's normal boot sent DELETE /v1/client/environment-links/<id>/tunnel. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
lens: sec verdict: SAFE (head 47d466c) Round 2, security + live-safety lens (state/correctness is the other lens). The head has not moved. Read-only: the round-1 lens comments, issue #368, the PR body, Round-1 findings: fixed?
(1) Can a marked home still reach Connect?No path found.
(2) Can the marker land in the live home?
(3) Ordering, and unmarked homes
Findings
Mutations (each restored with
|
| # | Mutation | Result |
|---|---|---|
| M1 | dangling symlink not counted (readLink → false) |
red (2: CLI + boot) |
| M2 | check error counts as absent | red (1) |
| M3 | normal boot ignores the marker | red (3) |
| M4 | agent activity ignores the hold | red (4) |
| M5 | requireConnectAllowed refusal removed |
red (4: link, login, publish, up) |
| M6 | disconnectCloud refusal removed |
red (3: unlink, logout, up-off) |
| M7 | every marker-write error swallowed | red (1) |
| M8 | held unlink passes through to the real CloudLink |
red (4) |
| M9 | held releaseManagedTunnelOnShutdown passes through |
red (4) |
| M10 | marker never refuses in the CLI | red (13) |
| M11 | wx → w (overwrite) |
red (1) |
All 11 are red, and the tree was clean afterwards.
At head: holdWorkConnect, connect.holdWork and server.holdWork: 32/32.
connect.test.ts + up.connect.test.ts: 7/11. The same 4 rows fail on origin/main:
The cause is this PC's host (loopback and policy), not the PR.
holdWork.boot.test.ts cannot run here (loopback). CI at this head: green, in 79 s.
| Case | Result |
|---|---|
| Run twice | The marker is kept (M11). A second normal boot reads the same marker. |
| Stopped half-way | An empty marker still holds and refuses. A stop before the marker is written happens before CloudLink is built. |
| Old state | A copy made before this PR, a copy held only on an older build, or a userdata-only copy (finding 2) has no marker and is unprotected. This is documented except for the userdata-only case. |
| Empty or missing home | Let through, as upstream. |
| Live home marked by hand | Fails safe: Connect is held, nothing is sent, and the file is named (finding 1). |
🤖 Generated with Claude Code
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
lens: state verdict: SAFE (head 47d466c) Round 2, state + correctness lens. Another lens covers live safety and security. Read-only. I read both round-1 lenses, the PR body, #368, #409, I found no blocker and no major. Every round-1 finding is fixed. One minor on the merge path: the seam list (finding 1). Round-1 findings: checked
Findings
State question
One source (2): Boot test (3):
Docs (4): they match the code (refused commands, what each counts as a marker, the policy exception, the copies with no marker, "Still runs"), apart from nit 2. MutationsEach was restored afterwards, with
(My first try at MC was a broken mutation that counted every home as marked. I redid it; the row above is the correct one.) Tests (local)
🤖 Generated with Claude Code |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
- From upstream, an announced line the head's file already has (upstream added it) is refused before fork-follow pushes, naming the list-only fix: pushed, main's stale-list test would fail every pull request. - On a pull request only "added" lines may go: an announced line in main's file is upstream's. - A line in both "added" and "announced" is a malformed list (step 2 moves a line, never copies it). - A pull request's run refuses a line only an expired announcement allows, dated by main's commit; it warns when an announcement it adds would be refused within 3 days. - After a rebase a rising count is the operator's step only, without the author hint. - forkFiles no longer names MarkdownFileLink.logic.test.ts, which upstream has from nightly 4736 on. - Docs: #398's worked example (holdWorkConnect* forkFiles, keep the old lines until #398 merges), pending files, re-run dates, "//" keys. Co-Authored-By: Claude Opus 5.5 <[email protected]>
…erator messages (#409, #432) (#436) * fork seams: upstream's fork-title scenario test is not a fork file (#432) From upstream nightly v0.1.10-nightly.20261114.4695 on, upstream has scripts/scenarios/fork-title-regenerates-from-inherited-history.e2e.ts. Its name is fork-like, so the seam check after fork-follow's rebase refused it (a pull request's run would take it for a fork file) and the next follow stopped. Exclude it with a "!" entry in forkFiles. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fork seams: announce a new seam line, then add it (#409); list guards (#432) A pull request is judged by main's list, so a new seam line had no green path. Step 1, a list-only change, announces the lines in the file's entry ("announced": {"since": day, "added": [lines]}); the seam check allows them like "added" ones. Step 2 adds the lines and moves them to "added". The seam-check tests (on the tree they test) refuse an announced line already in its file beyond the listed copies, so step 2 must drop the flag and a line upstream has cannot be announced. From upstream, fork-follow refuses an announcement more than 14 days older than the head's commit date (or dated ahead): announcements cannot pile up. A pull request's run has no dates, so the fix is green. #432: - "files" and "pending" keys must be plain repository paths (no empty part, absolute path, "..", ".", pathspec magic, backslash or control character); once merged, such a key crashed every later run. - A pull request's own list with a duplicate key is refused. - Keys are printed JSON-escaped and every printed line has its control characters escaped, so a list or a line cannot forge a workflow command in the log. - After a rebase, a count or ceiling that rises tells the operator what to do (rebase by hand, raise it in the rebased series), not a pull request author. - fork-follow's seam refusal says the series was left as it is. - The real list is parsed inside the tests, so a parse mutation fails the tests that pin it instead of the file's load. - Docs: a count is not a set of lines; a pull request can swap one gone upstream line for another in a pending file with a "lost" entry. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fork seams: fix round 1 on the announce-then-add path (#409) - From upstream, an announced line the head's file already has (upstream added it) is refused before fork-follow pushes, naming the list-only fix: pushed, main's stale-list test would fail every pull request. - On a pull request only "added" lines may go: an announced line in main's file is upstream's. - A line in both "added" and "announced" is a malformed list (step 2 moves a line, never copies it). - A pull request's run refuses a line only an expired announcement allows, dated by main's commit; it warns when an announcement it adds would be refused within 3 days. - After a rebase a rising count is the operator's step only, without the author hint. - forkFiles no longer names MarkdownFileLink.logic.test.ts, which upstream has from nightly 4736 on. - Docs: #398's worked example (holdWorkConnect* forkFiles, keep the old lines until #398 merges), pending files, re-run dates, "//" keys. Co-Authored-By: Claude Opus 5.5 <[email protected]> --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
List only. Announces #398's two new cli/connect.ts lines (main's three old lines stay listed until #398 drops them), adds RemoteDelegation.ts with #412's ten lines announced, and adds apps/server/src/cloud/holdWorkConnect* to forkFiles. Co-authored-by: Claude Opus 5.5 <[email protected]>
Resolve .github/fork-seams.json for apps/server/src/cli/connect.ts: main's announced lines are this branch's added lines, main's three old refuseCliUnlinkWhileHeld lines are gone from the file, and the announced block is dropped. RemoteDelegation.ts is main's as is. Co-Authored-By: Claude Opus 5.5 <[email protected]>
There was an error while loading. Please reload this page.
…erator messages (#409, #432) (#436) * fork seams: upstream's fork-title scenario test is not a fork file (#432) From upstream nightly v0.1.10-nightly.20261114.4695 on, upstream has scripts/scenarios/fork-title-regenerates-from-inherited-history.e2e.ts. Its name is fork-like, so the seam check after fork-follow's rebase refused it (a pull request's run would take it for a fork file) and the next follow stopped. Exclude it with a "!" entry in forkFiles. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fork seams: announce a new seam line, then add it (#409); list guards (#432) A pull request is judged by main's list, so a new seam line had no green path. Step 1, a list-only change, announces the lines in the file's entry ("announced": {"since": day, "added": [lines]}); the seam check allows them like "added" ones. Step 2 adds the lines and moves them to "added". The seam-check tests (on the tree they test) refuse an announced line already in its file beyond the listed copies, so step 2 must drop the flag and a line upstream has cannot be announced. From upstream, fork-follow refuses an announcement more than 14 days older than the head's commit date (or dated ahead): announcements cannot pile up. A pull request's run has no dates, so the fix is green. #432: - "files" and "pending" keys must be plain repository paths (no empty part, absolute path, "..", ".", pathspec magic, backslash or control character); once merged, such a key crashed every later run. - A pull request's own list with a duplicate key is refused. - Keys are printed JSON-escaped and every printed line has its control characters escaped, so a list or a line cannot forge a workflow command in the log. - After a rebase, a count or ceiling that rises tells the operator what to do (rebase by hand, raise it in the rebased series), not a pull request author. - fork-follow's seam refusal says the series was left as it is. - The real list is parsed inside the tests, so a parse mutation fails the tests that pin it instead of the file's load. - Docs: a count is not a set of lines; a pull request can swap one gone upstream line for another in a pending file with a "lost" entry. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fork seams: fix round 1 on the announce-then-add path (#409) - From upstream, an announced line the head's file already has (upstream added it) is refused before fork-follow pushes, naming the list-only fix: pushed, main's stale-list test would fail every pull request. - On a pull request only "added" lines may go: an announced line in main's file is upstream's. - A line in both "added" and "announced" is a malformed list (step 2 moves a line, never copies it). - A pull request's run refuses a line only an expired announcement allows, dated by main's commit; it warns when an announcement it adds would be refused within 3 days. - After a rebase a rising count is the operator's step only, without the author hint. - forkFiles no longer names MarkdownFileLink.logic.test.ts, which upstream has from nightly 4736 on. - Docs: #398's worked example (holdWorkConnect* forkFiles, keep the old lines until #398 merges), pending files, re-run dates, "//" keys. Co-Authored-By: Claude Opus 5.5 <[email protected]> --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
List only. Announces #398's two new cli/connect.ts lines (main's three old lines stay listed until #398 drops them), adds RemoteDelegation.ts with #412's ten lines announced, and adds apps/server/src/cloud/holdWorkConnect* to forkFiles. Co-authored-by: Claude Opus 5.5 <[email protected]>
…tests and docs (#368) (#398) * hold-work: a marker guards a held or stopped copy's home in the CLI (#368) A held boot writes hold-work-copy.json in the copy's home before the real CloudLink is built (exclusive create: a marker already there stays). The CLI refuses connect login, link, unlink, logout, publish (turning it on) and t3 up turning Connect on or off while the marker exists, running or not, and still while the home's server runs held. Only deleting the marker clears it, and the refusal names it. - cli/connect.holdWork.test.ts runs the real commands on temp homes with a recording fetch: each is refused before any request or file change, and the same unlink on an unmarked home sends the relay delete. - The boot test checks the marker after the held and normal boots, and that stopping the normal boot sent the tunnel release itself. - docs: the marker, the policy-off unlink at start-up, the held-hooks waker and the relay client ledger clean-up. Co-Authored-By: Claude Opus 5.5 <[email protected]> * hold-work: plain text marker (hold-work-copy.txt); test types Co-Authored-By: Claude Opus 5.5 <[email protected]> * fork seams: hold-work files are the fork's own; pin the connect.ts seam lines Co-Authored-By: Claude Opus 5.5 <[email protected]> * test(hold-work): a marked copy's normal boot holds Connect; marker write failure, publish, up --no-connect, dangling symlink Tests only, ahead of the fix (#368 fix round): they fail on this commit. - A normal boot of a home with hold-work-copy.txt (a file, an empty one or a dangling symlink) must hold CloudLink and agent activity as a held boot does. - The boot test boots the marked copy normally (no tunnel DELETE, no relay request), then again with the marker deleted (one tunnel DELETE). It points the managed policy at a missing file so the host's policy does not apply. - A held boot that cannot write its marker fails before CloudLink is built. - t3 connect publish and t3 up --no-connect are refused on a marked home. - The CLI refuses on a dangling symlink at the marker path. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fix(hold-work): every boot of a marked copy holds T3 Connect; one marker check for CLI and server A copy booted held once is marked (hold-work-copy.txt). A later normal boot of it used to register and, on stop, release the tunnel under the live server's environment id. HoldWorkConnect.layer and agentActivityLayer now hold when the boot is held or the home is marked, read once as the layers build. The CLI and the server share one marker check, which also counts a dangling symlink (the held boot's exclusive create keeps one) and a check that fails. Docs: a marked copy started normally, copies held-booted by builds before the marker, and what a refused command may still create. Seams: undo the unrelated reorder of the two capacity entries. Co-Authored-By: Claude Opus 5.5 <[email protected]> * probe (reverted next): the boot test's server ignores hold-work-copy.txt Shows that holdWork.boot.test.ts fails without the marker hold at boot. Only the spawned server (T3CODE_POSTHOG_HOST set) skips the marker, so the unit tests in the same CI shard still pass and the shard runs the boot test. Co-Authored-By: Claude Opus 5.5 <[email protected]> * test(hold-work): boot test checks the marked copy's tunnel release before its log lines Co-Authored-By: Claude Opus 5.5 <[email protected]> * Revert the probe: the boot test's server reads hold-work-copy.txt again The probe (89594df) made shard 5 fail at holdWork.boot.test.ts:842: the marked copy's normal boot sent DELETE /v1/client/environment-links/<id>/tunnel. Co-Authored-By: Claude Opus 5.5 <[email protected]> --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
…erator messages (#409, #432) (#436) * fork seams: upstream's fork-title scenario test is not a fork file (#432) From upstream nightly v0.1.10-nightly.20261114.4695 on, upstream has scripts/scenarios/fork-title-regenerates-from-inherited-history.e2e.ts. Its name is fork-like, so the seam check after fork-follow's rebase refused it (a pull request's run would take it for a fork file) and the next follow stopped. Exclude it with a "!" entry in forkFiles. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fork seams: announce a new seam line, then add it (#409); list guards (#432) A pull request is judged by main's list, so a new seam line had no green path. Step 1, a list-only change, announces the lines in the file's entry ("announced": {"since": day, "added": [lines]}); the seam check allows them like "added" ones. Step 2 adds the lines and moves them to "added". The seam-check tests (on the tree they test) refuse an announced line already in its file beyond the listed copies, so step 2 must drop the flag and a line upstream has cannot be announced. From upstream, fork-follow refuses an announcement more than 14 days older than the head's commit date (or dated ahead): announcements cannot pile up. A pull request's run has no dates, so the fix is green. #432: - "files" and "pending" keys must be plain repository paths (no empty part, absolute path, "..", ".", pathspec magic, backslash or control character); once merged, such a key crashed every later run. - A pull request's own list with a duplicate key is refused. - Keys are printed JSON-escaped and every printed line has its control characters escaped, so a list or a line cannot forge a workflow command in the log. - After a rebase, a count or ceiling that rises tells the operator what to do (rebase by hand, raise it in the rebased series), not a pull request author. - fork-follow's seam refusal says the series was left as it is. - The real list is parsed inside the tests, so a parse mutation fails the tests that pin it instead of the file's load. - Docs: a count is not a set of lines; a pull request can swap one gone upstream line for another in a pending file with a "lost" entry. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fork seams: fix round 1 on the announce-then-add path (#409) - From upstream, an announced line the head's file already has (upstream added it) is refused before fork-follow pushes, naming the list-only fix: pushed, main's stale-list test would fail every pull request. - On a pull request only "added" lines may go: an announced line in main's file is upstream's. - A line in both "added" and "announced" is a malformed list (step 2 moves a line, never copies it). - A pull request's run refuses a line only an expired announcement allows, dated by main's commit; it warns when an announcement it adds would be refused within 3 days. - After a rebase a rising count is the operator's step only, without the author hint. - forkFiles no longer names MarkdownFileLink.logic.test.ts, which upstream has from nightly 4736 on. - Docs: #398's worked example (holdWorkConnect* forkFiles, keep the old lines until #398 merges), pending files, re-run dates, "//" keys. Co-Authored-By: Claude Opus 5.5 <[email protected]> --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
List only. Announces #398's two new cli/connect.ts lines (main's three old lines stay listed until #398 drops them), adds RemoteDelegation.ts with #412's ten lines announced, and adds apps/server/src/cloud/holdWorkConnect* to forkFiles. Co-authored-by: Claude Opus 5.5 <[email protected]>
…tests and docs (#368) (#398) * hold-work: a marker guards a held or stopped copy's home in the CLI (#368) A held boot writes hold-work-copy.json in the copy's home before the real CloudLink is built (exclusive create: a marker already there stays). The CLI refuses connect login, link, unlink, logout, publish (turning it on) and t3 up turning Connect on or off while the marker exists, running or not, and still while the home's server runs held. Only deleting the marker clears it, and the refusal names it. - cli/connect.holdWork.test.ts runs the real commands on temp homes with a recording fetch: each is refused before any request or file change, and the same unlink on an unmarked home sends the relay delete. - The boot test checks the marker after the held and normal boots, and that stopping the normal boot sent the tunnel release itself. - docs: the marker, the policy-off unlink at start-up, the held-hooks waker and the relay client ledger clean-up. Co-Authored-By: Claude Opus 5.5 <[email protected]> * hold-work: plain text marker (hold-work-copy.txt); test types Co-Authored-By: Claude Opus 5.5 <[email protected]> * fork seams: hold-work files are the fork's own; pin the connect.ts seam lines Co-Authored-By: Claude Opus 5.5 <[email protected]> * test(hold-work): a marked copy's normal boot holds Connect; marker write failure, publish, up --no-connect, dangling symlink Tests only, ahead of the fix (#368 fix round): they fail on this commit. - A normal boot of a home with hold-work-copy.txt (a file, an empty one or a dangling symlink) must hold CloudLink and agent activity as a held boot does. - The boot test boots the marked copy normally (no tunnel DELETE, no relay request), then again with the marker deleted (one tunnel DELETE). It points the managed policy at a missing file so the host's policy does not apply. - A held boot that cannot write its marker fails before CloudLink is built. - t3 connect publish and t3 up --no-connect are refused on a marked home. - The CLI refuses on a dangling symlink at the marker path. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fix(hold-work): every boot of a marked copy holds T3 Connect; one marker check for CLI and server A copy booted held once is marked (hold-work-copy.txt). A later normal boot of it used to register and, on stop, release the tunnel under the live server's environment id. HoldWorkConnect.layer and agentActivityLayer now hold when the boot is held or the home is marked, read once as the layers build. The CLI and the server share one marker check, which also counts a dangling symlink (the held boot's exclusive create keeps one) and a check that fails. Docs: a marked copy started normally, copies held-booted by builds before the marker, and what a refused command may still create. Seams: undo the unrelated reorder of the two capacity entries. Co-Authored-By: Claude Opus 5.5 <[email protected]> * probe (reverted next): the boot test's server ignores hold-work-copy.txt Shows that holdWork.boot.test.ts fails without the marker hold at boot. Only the spawned server (T3CODE_POSTHOG_HOST set) skips the marker, so the unit tests in the same CI shard still pass and the shard runs the boot test. Co-Authored-By: Claude Opus 5.5 <[email protected]> * test(hold-work): boot test checks the marked copy's tunnel release before its log lines Co-Authored-By: Claude Opus 5.5 <[email protected]> * Revert the probe: the boot test's server reads hold-work-copy.txt again The probe (89594df) made shard 5 fail at holdWork.boot.test.ts:842: the marked copy's normal boot sent DELETE /v1/client/environment-links/<id>/tunnel. Co-Authored-By: Claude Opus 5.5 <[email protected]> --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
…#410) (#576) A sync that drops both ForkLayers.layerRuntimeServices and ForkLayers.layerRoutes from server.ts still type-checks and boots, so the usage pacing gate, the slot gate and automatic updates could go silently. - forkLayers.ts: the /mcp requirement read of the usage pacer and slot gate now runs in one span, ForkLayers.mcpGatesPresent. - holdWork.boot.test.ts: each of the three boots must show that span, HeadlessUsageRefresher.make and cloud.auto_update.make. The held boot must also log the held-boot warning. - The child's environment keeps LD_LIBRARY_PATH, DYLD_LIBRARY_PATH, DYLD_FALLBACK_LIBRARY_PATH, SystemRoot and windir from this process and nothing else of it. A new unit test checks that. The managed-policy path was already pointed at a missing file (#398). Fixes #410 Co-authored-by: Claude Opus 5.5 <[email protected]>
…erator messages (#409, #432) (#436) * fork seams: upstream's fork-title scenario test is not a fork file (#432) From upstream nightly v0.1.10-nightly.20261114.4695 on, upstream has scripts/scenarios/fork-title-regenerates-from-inherited-history.e2e.ts. Its name is fork-like, so the seam check after fork-follow's rebase refused it (a pull request's run would take it for a fork file) and the next follow stopped. Exclude it with a "!" entry in forkFiles. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fork seams: announce a new seam line, then add it (#409); list guards (#432) A pull request is judged by main's list, so a new seam line had no green path. Step 1, a list-only change, announces the lines in the file's entry ("announced": {"since": day, "added": [lines]}); the seam check allows them like "added" ones. Step 2 adds the lines and moves them to "added". The seam-check tests (on the tree they test) refuse an announced line already in its file beyond the listed copies, so step 2 must drop the flag and a line upstream has cannot be announced. From upstream, fork-follow refuses an announcement more than 14 days older than the head's commit date (or dated ahead): announcements cannot pile up. A pull request's run has no dates, so the fix is green. #432: - "files" and "pending" keys must be plain repository paths (no empty part, absolute path, "..", ".", pathspec magic, backslash or control character); once merged, such a key crashed every later run. - A pull request's own list with a duplicate key is refused. - Keys are printed JSON-escaped and every printed line has its control characters escaped, so a list or a line cannot forge a workflow command in the log. - After a rebase, a count or ceiling that rises tells the operator what to do (rebase by hand, raise it in the rebased series), not a pull request author. - fork-follow's seam refusal says the series was left as it is. - The real list is parsed inside the tests, so a parse mutation fails the tests that pin it instead of the file's load. - Docs: a count is not a set of lines; a pull request can swap one gone upstream line for another in a pending file with a "lost" entry. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fork seams: fix round 1 on the announce-then-add path (#409) - From upstream, an announced line the head's file already has (upstream added it) is refused before fork-follow pushes, naming the list-only fix: pushed, main's stale-list test would fail every pull request. - On a pull request only "added" lines may go: an announced line in main's file is upstream's. - A line in both "added" and "announced" is a malformed list (step 2 moves a line, never copies it). - A pull request's run refuses a line only an expired announcement allows, dated by main's commit; it warns when an announcement it adds would be refused within 3 days. - After a rebase a rising count is the operator's step only, without the author hint. - forkFiles no longer names MarkdownFileLink.logic.test.ts, which upstream has from nightly 4736 on. - Docs: #398's worked example (holdWorkConnect* forkFiles, keep the old lines until #398 merges), pending files, re-run dates, "//" keys. Co-Authored-By: Claude Opus 5.5 <[email protected]> --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
List only. Announces #398's two new cli/connect.ts lines (main's three old lines stay listed until #398 drops them), adds RemoteDelegation.ts with #412's ten lines announced, and adds apps/server/src/cloud/holdWorkConnect* to forkFiles. Co-authored-by: Claude Opus 5.5 <[email protected]>
…tests and docs (#368) (#398) * hold-work: a marker guards a held or stopped copy's home in the CLI (#368) A held boot writes hold-work-copy.json in the copy's home before the real CloudLink is built (exclusive create: a marker already there stays). The CLI refuses connect login, link, unlink, logout, publish (turning it on) and t3 up turning Connect on or off while the marker exists, running or not, and still while the home's server runs held. Only deleting the marker clears it, and the refusal names it. - cli/connect.holdWork.test.ts runs the real commands on temp homes with a recording fetch: each is refused before any request or file change, and the same unlink on an unmarked home sends the relay delete. - The boot test checks the marker after the held and normal boots, and that stopping the normal boot sent the tunnel release itself. - docs: the marker, the policy-off unlink at start-up, the held-hooks waker and the relay client ledger clean-up. Co-Authored-By: Claude Opus 5.5 <[email protected]> * hold-work: plain text marker (hold-work-copy.txt); test types Co-Authored-By: Claude Opus 5.5 <[email protected]> * fork seams: hold-work files are the fork's own; pin the connect.ts seam lines Co-Authored-By: Claude Opus 5.5 <[email protected]> * test(hold-work): a marked copy's normal boot holds Connect; marker write failure, publish, up --no-connect, dangling symlink Tests only, ahead of the fix (#368 fix round): they fail on this commit. - A normal boot of a home with hold-work-copy.txt (a file, an empty one or a dangling symlink) must hold CloudLink and agent activity as a held boot does. - The boot test boots the marked copy normally (no tunnel DELETE, no relay request), then again with the marker deleted (one tunnel DELETE). It points the managed policy at a missing file so the host's policy does not apply. - A held boot that cannot write its marker fails before CloudLink is built. - t3 connect publish and t3 up --no-connect are refused on a marked home. - The CLI refuses on a dangling symlink at the marker path. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fix(hold-work): every boot of a marked copy holds T3 Connect; one marker check for CLI and server A copy booted held once is marked (hold-work-copy.txt). A later normal boot of it used to register and, on stop, release the tunnel under the live server's environment id. HoldWorkConnect.layer and agentActivityLayer now hold when the boot is held or the home is marked, read once as the layers build. The CLI and the server share one marker check, which also counts a dangling symlink (the held boot's exclusive create keeps one) and a check that fails. Docs: a marked copy started normally, copies held-booted by builds before the marker, and what a refused command may still create. Seams: undo the unrelated reorder of the two capacity entries. Co-Authored-By: Claude Opus 5.5 <[email protected]> * probe (reverted next): the boot test's server ignores hold-work-copy.txt Shows that holdWork.boot.test.ts fails without the marker hold at boot. Only the spawned server (T3CODE_POSTHOG_HOST set) skips the marker, so the unit tests in the same CI shard still pass and the shard runs the boot test. Co-Authored-By: Claude Opus 5.5 <[email protected]> * test(hold-work): boot test checks the marked copy's tunnel release before its log lines Co-Authored-By: Claude Opus 5.5 <[email protected]> * Revert the probe: the boot test's server reads hold-work-copy.txt again The probe (89594df) made shard 5 fail at holdWork.boot.test.ts:842: the marked copy's normal boot sent DELETE /v1/client/environment-links/<id>/tunnel. Co-Authored-By: Claude Opus 5.5 <[email protected]> --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
…#410) (#576) A sync that drops both ForkLayers.layerRuntimeServices and ForkLayers.layerRoutes from server.ts still type-checks and boots, so the usage pacing gate, the slot gate and automatic updates could go silently. - forkLayers.ts: the /mcp requirement read of the usage pacer and slot gate now runs in one span, ForkLayers.mcpGatesPresent. - holdWork.boot.test.ts: each of the three boots must show that span, HeadlessUsageRefresher.make and cloud.auto_update.make. The held boot must also log the held-boot warning. - The child's environment keeps LD_LIBRARY_PATH, DYLD_LIBRARY_PATH, DYLD_FALLBACK_LIBRARY_PATH, SystemRoot and windir from this process and nothing else of it. A new unit test checks that. The managed-policy path was already pointed at a missing file (#398). Fixes #410 Co-authored-by: Claude Opus 5.5 <[email protected]>
…#410) (#576) A sync that drops both ForkLayers.layerRuntimeServices and ForkLayers.layerRoutes from server.ts still type-checks and boots, so the usage pacing gate, the slot gate and automatic updates could go silently. - forkLayers.ts: the /mcp requirement read of the usage pacer and slot gate now runs in one span, ForkLayers.mcpGatesPresent. - holdWork.boot.test.ts: each of the three boots must show that span, HeadlessUsageRefresher.make and cloud.auto_update.make. The held boot must also log the held-boot warning. - The child's environment keeps LD_LIBRARY_PATH, DYLD_LIBRARY_PATH, DYLD_FALLBACK_LIBRARY_PATH, SystemRoot and windir from this process and nothing else of it. A new unit test checks that. The managed-policy path was already pointed at a missing file (#398). Fixes #410 Co-authored-by: Claude Opus 5.5 <[email protected]>
…erator messages (#409, #432) (#436) * fork seams: upstream's fork-title scenario test is not a fork file (#432) From upstream nightly v0.1.10-nightly.20261114.4695 on, upstream has scripts/scenarios/fork-title-regenerates-from-inherited-history.e2e.ts. Its name is fork-like, so the seam check after fork-follow's rebase refused it (a pull request's run would take it for a fork file) and the next follow stopped. Exclude it with a "!" entry in forkFiles. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fork seams: announce a new seam line, then add it (#409); list guards (#432) A pull request is judged by main's list, so a new seam line had no green path. Step 1, a list-only change, announces the lines in the file's entry ("announced": {"since": day, "added": [lines]}); the seam check allows them like "added" ones. Step 2 adds the lines and moves them to "added". The seam-check tests (on the tree they test) refuse an announced line already in its file beyond the listed copies, so step 2 must drop the flag and a line upstream has cannot be announced. From upstream, fork-follow refuses an announcement more than 14 days older than the head's commit date (or dated ahead): announcements cannot pile up. A pull request's run has no dates, so the fix is green. #432: - "files" and "pending" keys must be plain repository paths (no empty part, absolute path, "..", ".", pathspec magic, backslash or control character); once merged, such a key crashed every later run. - A pull request's own list with a duplicate key is refused. - Keys are printed JSON-escaped and every printed line has its control characters escaped, so a list or a line cannot forge a workflow command in the log. - After a rebase, a count or ceiling that rises tells the operator what to do (rebase by hand, raise it in the rebased series), not a pull request author. - fork-follow's seam refusal says the series was left as it is. - The real list is parsed inside the tests, so a parse mutation fails the tests that pin it instead of the file's load. - Docs: a count is not a set of lines; a pull request can swap one gone upstream line for another in a pending file with a "lost" entry. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fork seams: fix round 1 on the announce-then-add path (#409) - From upstream, an announced line the head's file already has (upstream added it) is refused before fork-follow pushes, naming the list-only fix: pushed, main's stale-list test would fail every pull request. - On a pull request only "added" lines may go: an announced line in main's file is upstream's. - A line in both "added" and "announced" is a malformed list (step 2 moves a line, never copies it). - A pull request's run refuses a line only an expired announcement allows, dated by main's commit; it warns when an announcement it adds would be refused within 3 days. - After a rebase a rising count is the operator's step only, without the author hint. - forkFiles no longer names MarkdownFileLink.logic.test.ts, which upstream has from nightly 4736 on. - Docs: #398's worked example (holdWorkConnect* forkFiles, keep the old lines until #398 merges), pending files, re-run dates, "//" keys. Co-Authored-By: Claude Opus 5.5 <[email protected]> --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
List only. Announces #398's two new cli/connect.ts lines (main's three old lines stay listed until #398 drops them), adds RemoteDelegation.ts with #412's ten lines announced, and adds apps/server/src/cloud/holdWorkConnect* to forkFiles. Co-authored-by: Claude Opus 5.5 <[email protected]>
…tests and docs (#368) (#398) * hold-work: a marker guards a held or stopped copy's home in the CLI (#368) A held boot writes hold-work-copy.json in the copy's home before the real CloudLink is built (exclusive create: a marker already there stays). The CLI refuses connect login, link, unlink, logout, publish (turning it on) and t3 up turning Connect on or off while the marker exists, running or not, and still while the home's server runs held. Only deleting the marker clears it, and the refusal names it. - cli/connect.holdWork.test.ts runs the real commands on temp homes with a recording fetch: each is refused before any request or file change, and the same unlink on an unmarked home sends the relay delete. - The boot test checks the marker after the held and normal boots, and that stopping the normal boot sent the tunnel release itself. - docs: the marker, the policy-off unlink at start-up, the held-hooks waker and the relay client ledger clean-up. Co-Authored-By: Claude Opus 5.5 <[email protected]> * hold-work: plain text marker (hold-work-copy.txt); test types Co-Authored-By: Claude Opus 5.5 <[email protected]> * fork seams: hold-work files are the fork's own; pin the connect.ts seam lines Co-Authored-By: Claude Opus 5.5 <[email protected]> * test(hold-work): a marked copy's normal boot holds Connect; marker write failure, publish, up --no-connect, dangling symlink Tests only, ahead of the fix (#368 fix round): they fail on this commit. - A normal boot of a home with hold-work-copy.txt (a file, an empty one or a dangling symlink) must hold CloudLink and agent activity as a held boot does. - The boot test boots the marked copy normally (no tunnel DELETE, no relay request), then again with the marker deleted (one tunnel DELETE). It points the managed policy at a missing file so the host's policy does not apply. - A held boot that cannot write its marker fails before CloudLink is built. - t3 connect publish and t3 up --no-connect are refused on a marked home. - The CLI refuses on a dangling symlink at the marker path. Co-Authored-By: Claude Opus 5.5 <[email protected]> * fix(hold-work): every boot of a marked copy holds T3 Connect; one marker check for CLI and server A copy booted held once is marked (hold-work-copy.txt). A later normal boot of it used to register and, on stop, release the tunnel under the live server's environment id. HoldWorkConnect.layer and agentActivityLayer now hold when the boot is held or the home is marked, read once as the layers build. The CLI and the server share one marker check, which also counts a dangling symlink (the held boot's exclusive create keeps one) and a check that fails. Docs: a marked copy started normally, copies held-booted by builds before the marker, and what a refused command may still create. Seams: undo the unrelated reorder of the two capacity entries. Co-Authored-By: Claude Opus 5.5 <[email protected]> * probe (reverted next): the boot test's server ignores hold-work-copy.txt Shows that holdWork.boot.test.ts fails without the marker hold at boot. Only the spawned server (T3CODE_POSTHOG_HOST set) skips the marker, so the unit tests in the same CI shard still pass and the shard runs the boot test. Co-Authored-By: Claude Opus 5.5 <[email protected]> * test(hold-work): boot test checks the marked copy's tunnel release before its log lines Co-Authored-By: Claude Opus 5.5 <[email protected]> * Revert the probe: the boot test's server reads hold-work-copy.txt again The probe (89594df) made shard 5 fail at holdWork.boot.test.ts:842: the marked copy's normal boot sent DELETE /v1/client/environment-links/<id>/tunnel. Co-Authored-By: Claude Opus 5.5 <[email protected]> --------- Co-authored-by: Claude Opus 5.5 <[email protected]>
…#410) (#576) A sync that drops both ForkLayers.layerRuntimeServices and ForkLayers.layerRoutes from server.ts still type-checks and boots, so the usage pacing gate, the slot gate and automatic updates could go silently. - forkLayers.ts: the /mcp requirement read of the usage pacer and slot gate now runs in one span, ForkLayers.mcpGatesPresent. - holdWork.boot.test.ts: each of the three boots must show that span, HeadlessUsageRefresher.make and cloud.auto_update.make. The held boot must also log the held-boot warning. - The child's environment keeps LD_LIBRARY_PATH, DYLD_LIBRARY_PATH, DYLD_FALLBACK_LIBRARY_PATH, SystemRoot and windir from this process and nothing else of it. A new unit test checks that. The managed-policy path was already pointed at a missing file (#398). Fixes #410 Co-authored-by: Claude Opus 5.5 <[email protected]>
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
hold-work: guard a held or stopped copy's home in the CLI; tests and docs (#313 follow-ups)
There was an error while loading. Please reload this page.