Repository navigation
fix(cluster): DevNet round 2: what both pairs' validations found, the agent setup guide, plain-words changelog - #1783
Conversation
- cluster-candidate-findings (#1781): a title for users, "measured on one pair", the speculative assistant by its documented name, and the ✗ title's old "starting; " head said plainly. The last bullet is unchanged. - cluster-start-says-serving-only-when-loaded (#1764): the joining Mac's setup ends with the same ✓ or ✗ as the leading Mac (as #1778 says), not "pointing to the leader's screen". - cluster-console-clarity (#1778): Qwen 3.8 27B's tensor-parallel-only rule said once, with why; what a person sees instead of "scope switch", "a choice forwarded from the other Mac uses the planner's mode" and the older-build leader; the joining Mac's ending in one bullet; the registration line's old wording named. - provider-uninstall-keep-or-remove (#1772): on a pair, uninstall stops both Macs, as darkbloom stop does there. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…(red) From the DevNet validation of 6497e8e on the M5 Ultra pair: - A-1: the DevNet app's start card, `cluster stop --service`, its refusal, `cluster local` and the follower's Local Network hint name `darkbloom` instead of the identity's CLI (and app). - A-11: restart (and a script start) wait minutes with no output; each wait must say what it waits for and its bound. - A-13: both installs share ~/.darkbloom/cluster/incidents.json; each install's feed should hold its own (older records: production). - A-12: a following window's `status` requests log once a second. Adds the API these need with today's behavior: LinkFollower's localNetworkApp(cli:), a progress-delay seam and Wait.heartbeat, ClusterIncidentLog's install, ClusterService.logsControl. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The DevNet build of dev 6497e8e (0.10.6-dev.branch.76) on the production M5 Ultra pair, overnight/candidate-0108-proof.md "DevNet validation of 6497e8e", table A-1…A-13: - A-9: choosing Pipeline for GLM-5.3-Flash loaded tensor parallel again. useMode compared the choice with the listing's first mode, not with the plan the adopt uses; GLM's listing put Pipeline first while its plan was tensor parallel, so nothing was kept. useMode now always keeps the person's family (keptFamily), and localAdopt plans again in it only when the listed plan's mode isn't in it (replansInFamily). A-8's moving split isn't the same cause: the listing is planned while the serving model's parts hold memory, and the adopt plans again once they gave it back. - A-4: when this Mac's own worker died, its part also ended "closed" and the ✗ blamed the other Mac. ownWorker reads this Mac's incident log: worker_crashed from the part it leads since the wait began names this Mac's worker; none keeps B17's wording; an unreadable log (or a Mac that doesn't lead) blames neither. The title and the lines read one snapshot. - A-3: a member kept off the local network logged why and ended cleanly, so the leader's ✗ said "Make sure it is on". ClusterService.lastError carries that refusal as the part's reason, which the member already publishes in its status. - A-1 (onboarding part): commands in the live operations and the cluster service name BuildEnvironment.current.cliName (17 + 2 code lines). - A-10 (B18): a planned switch's clean stops showed as parts that ended. endShown: a stop (stopped, or exit 0 with no reason) isn't an end on either Mac; an exit 0 that says why still is. Red: behaviour-preserving seams first, then the tests: 22 tests with 5 issues (A-4 3, A-9 1, A-3 1); A-10 10 tests with 3 issues. Green: ProviderCoreTests 8-suite filter 68 tests and #1774's 8 suites 67 tests (prod build); onboarding 1165/0 (the real runner, sandboxed); control 229/0, placement flow-run 33, setup 264, provisioning 161/0, diagnostics, the placement library's checks and GLM image admission (40) pass; product build OK; docs gates OK. Reported, not changed: A-11's follower keeps its old setup after a leader-only restart until the next adopt. Not reached: A-6. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
From the DevNet validation of 6497e8e on the M5 Ultra pair: - A-1: one runtime CLI name. main.swift names it at startup (ClusterOnboardingCommand.use(BuildEnvironment.current.cliName)); ClusterPairSummary.cli reads it, and the pair texts interpolate it: the start/restart card, cluster stop (--service, its refusal and help), cluster local, and the status/doctor/desktop/start hints. ProviderCore's texts are named with it: the leadership refusal, pair --forget's line (which no longer prints a raw ClusterSetupFailure), the approval refusal, "not paired" and the tensor assistant's "press m". The follower's Local Network hint names the app to allow ("Darkbloom Dev"). Production output is byte-identical. - A-11: stop, restart and cluster stop --service say what they wait for when the stop request runs past 3 s (up to about 6 min) and while the parts end (with their bound); a script start says it waits until the pair serves (with its bound) and repeats an unchanged status once a minute. - A-13: each incident records its install; each install's feed (status, diagnostics, cluster incidents) holds its own records and the older unstamped ones (production's). The store is libs/darkbloom-cluster's DarkbloomClusterRemote. - A-12: the leader logs a following window's status requests once a minute, and every other command each time. - A-5: the port stays 8000; two-mac-cluster.md says both apps use it. Docs: cli-reference (waits), two-mac-cluster (port, DevNet names), architecture/inference (runtime name, shared incident log); changelog. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…; pin the incident install contract
- `Cluster.Stop.stopPair(_:progressAfter:)` is now `stopBothMacs(_:progressAfter:)`. It sat in the same type as
`pairStop(role:serving:)`, which decides who stops, and the two call sites read
`switch Self.pairStop(...) { case .leaderStopsBoth: stopped = Self.stopPair(...)`. Private; no behaviour change.
- `ClusterIncidentInstallTests` also expects `ClusterIncidentLog.unstampedInstall` to equal
`BuildEnvironment.prod.rawValue` (the library's literal for records without an install must be production's case
name), and `ClusterObservability`'s log to carry `BuildEnvironment.current.rawValue` (the provider's per-install
wiring had no test). Two assertions added; none removed; the test count is unchanged.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ame neither Mac on an unreadable incident log - `lastErrors` and `keepsEndingTitle` have their own doc comments again: `ownWorker` and `OwnWorker` had been inserted between each declaration and its doc. The docs of `linkClosedError`, `keepsEndingTitle`, `errorLines`' rule and `chosenFamilies` now say what the fix changed. - `ownPart(since:)` reads this Mac's part once for the ✗ title and the per-Mac lines. `lastErrors` uses the caller's read whole; it used to read the status again when that read had no part. - `ownWorker(inIncidentLog:since:)` reads the feed once. A log that is missing or can't be read (its `loadError`: too large, malformed, another schema) now blames neither Mac, as the docs and the PR say, instead of reading as "no crash here" and blaming the other Mac. A test covers a missing log, a malformed log, the other Mac's record, the time window and a field this build doesn't know. - `endShown` loses its unused `own` parameter. `replansInFamily` is written as a guard. - The live operations use `Self.cli`, the file's idiom. The service uses `OnboardingLive.cli` instead of keeping a second copy. - The A-9 test no longer has a tautology over a local constant. - two-mac-cluster.md: on the Mac that doesn't lead, the ✗ blames neither Mac too. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…e at once On a lane pair, a started request whose consumer goes away before its first token is asked for a clean stop, which ends it only at its first token: the pair first finishes the whole prompt while every newer request waits. The new check, against scripted ranks, expects such a request to be cancelled (its lane alone retires at once, nothing fenced, the pair serves the next request), and a pair without lanes to keep the clean stop. Red on dev: the request keeps its lane and neither rank is told to end the prompt. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…to G-12) An agent followed docs/provider/agent-setup.md literally on pair-2 (M3 Ultra leads, M5 Max follows) with the DevNet build of dev at 6497e8e and found twelve guide bugs (overnight/devnet-validation-pair2.md §2). Every quoted screen line is re-checked against that run's screens. - G-1, G-2: a marked DevNet variant ("DevNet (testers only)"): darkbloom-dev, ~/.darkbloom-dev, Darkbloom Dev.app, the DevNet installer, Build: dev and the dev coordinator, port 8001, and what X.Y.Z-dev.branch.N means (not a release number, so "older builds" doesn't apply). Rule 9 now allows the DevNet installer when the human asks for DevNet. - G-3: after installing another app on a paired Mac, Pair again may not appear; choose Start over on both Macs (it unpairs the Mac for both apps). - G-4: doctor's "[FAIL] cluster savedConfiguration …" before the first setup is expected (go on); a later build stops reporting it. - G-5: act on the first "Local link:" line (real output quoted); step 4.3 reads `darkbloom status --solo`. - G-6: both Connect lines (local and over SSH), "✓ Paired. This Mac (…) leads.", no password when the port is already set up, the 30 s hint. - G-7: the Local Network step can be missing while macOS blocks the service: the human checks System Settings on each Mac (Screen Sharing on a Mac with no display); a troubleshooting row for the ✗ and the follower's "link refused … may not reach the local network"; a later build names it. - G-8, G-9: the working lines print only in colour; a real model list and loading line. - G-10: Retry only waits for a stopped part; Ctrl-C, then darkbloom cluster. - G-11: DevNet's result block still prints darkbloom; type darkbloom-dev. - G-12: uninstalling one of two installs keeps the shared pairing, cable setup and models, asks no password, leaves the other service running. - The person-only list says plainly what an agent can't do. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… stops the pair first Pair-2 (P2-16): uninstalling the member of a serving pair beside the other install stopped the member's service cleanly but never told the leader, which logged "this Mac's part ended (exit 1) … starting it again" and looped. As tests, with stand-ins only (never real launchd, processes or network): - The pair is asked to stop first, on both Macs, then this Mac's service stops, then the files go. The summary says so, and has no other-Mac line while the pair still works through the other install. - When the other Mac doesn't answer, this Mac's part still stops locally, the run does not fail, and the summary ends with the other Mac's name and the command to run there. - The pair is not asked for the other install's service, nor on the one-install path, whose `cluster stop --service` asks the leader itself. - The dry run names the pair's stop. Red at 6497e8e: a runtime probe with the old API found no pair stop before the service's; the tests above do not compile (no `PairStop`, `Operations.stopPair`). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
On the leader, a `worker_crashed` recorded with source "leader" can be about either Mac's worker. In the DevNet run, the member's four kills were recorded on the leader as "ClusterWorkerOwnerError: closed | rank 1 follower said: …". A-4 therefore named the leader for the member's worker, which reversed B17. `ownWorker` now decides from the record's message: - it names this Mac only when the record is this Mac's rank's own exit record (`worker-exit-v1 rank=<rank>`, with any redacted prefix); - it names the other Mac, in B17's words, only when the record is what that Mac's link follower said (`rank <other> follower said:`); - otherwise it names neither Mac. Both formats are now shared with the code that writes them: `ClusterWorkerOwnerService.workerExitMarker` (DarkbloomClusterRemote) and `DistributedInstalledSession.followerSaid(rank:)`. The output is unchanged. The new test loads Mac A's real records: - each of the 4 member kills names the other Mac; - each of the 4 leader kills names this Mac; - both kinds in one wait name neither; - a malformed log names neither. Against the previous rule it fails with 5 issues. Also: - F2: `ClusterService.localNetworkRefusal` is now public, and `cluster link-follower` writes that same phrase. - F4: `offeredReadiness` and the "rank 0 on the other Mac ended" line no longer show clean stops as ends either. - F5: `readyWaitSeconds` names the 15-minute wait. `lastErrors` reads incidents since this start's wait began. - F6: `useMode` itself is now tested, through `useListing` and `keptFamily(forModel:)`. That test fails against the base's rule. - Docs: - two-mac-cluster.md says which record names which Mac; - cli-reference.md describes the follower's local-network line. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…I side (red) From the DevNet validation on pair-2: - A-13: a non-production install keeps its own incident file (incidents.dev.json), which an older build never reads or rewrites; ClusterIncidentLog.forThisInstall opens this build's. - P2-2: no-terminal `cluster`, the cluster service status lines and the Ctrl-C line still name `darkbloom` in the DevNet app. - P2-5: a provider configuration the installer left readable by others (no setup saved yet) makes doctor fail "unsafe, empty or oversized"; with a setup saved it must say the fix. - P2-11: a Mac's cluster service tells the other Mac whether it starts at login (ClusterServiceStatus.startsAtLogin). - P2-13: the leading Mac's other_mac.answers is null while they serve. - P2-8: the leading Mac's answer on the Mac that follows is unbounded in the CLI and silent while slow. Adds the API these need with today's behavior: defaultFile(homeDirectory: install:), forThisInstall, startsAtLogin (field and check), ClusterOnboardingTerminal.stoppedLine, ClusterPairSummary.boundedStatus. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…lled A consumer that goes away (a closed client connection, a coordinator cancel) asks the pair's lease for a clean stop, which ends a request only at its next committed token. Before its first token that means finishing the whole prompt: on DevNet a client that closed its connection 15 s into a 60K-token prompt on a Qwen 3.8 27B tensor-parallel pair kept both Macs prefilling it for about 4 minutes. The pair prefills one prompt at a time, oldest first, so every newer request waited behind it and failed at its own first-token deadline, while the pair still reported serving. On a pair whose lanes retire alone, ClusterWorkerRequest.requestCleanStop now refuses a request that has produced no token yet, so the engine cancels it: both ranks end only that lane at their next step boundary and the next request is served at once. A request that has produced a token keeps the clean stop, and so does a pair without such lanes, where a cancel ends the pair. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… part P2-16: beside the other install, step 2 stopped this install's running cluster service with SIGTERM, as `cluster stop --local-only` does, and the leader kept restarting its part for a member that was gone. When this install's service runs, step 2 now first asks the pair to stop on both Macs (`Operations.stopPair`), as `darkbloom stop` on either Mac does: the leader stops both, a serving member asks the leader over the control channel. Then the service stops and its agent goes, as before. The pairing, the cable port setup and the shared cluster files stay. If the other Mac does not answer, only this Mac's part stops (as before), and the summary ends with "The other Mac (<name>) did not answer, so its part may keep restarting: run `<cli> cluster stop` on it." The other install's service and the one-install path are unchanged. The CLI reference's step 2, a troubleshooting row and the changelog fragment say so. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…-1, P2-3, P2-4, P2-7
Pair-2's DevNet run (overnight/devnet-validation-pair2.md) and the M5 Ultra
pair's headless Mac B (A-2):
- P2-1 + A-2: macOS kept a member's link follower off the local network
("link refused: connectFailed (unreachable) … this process may not reach
the local network") while the service's own probe, one broadcast datagram
from the service process, logged "allowed". The follower keeps running and
retrying, so its Mac's status said "running, no error" and the first setup
ended "the other Mac did not answer". The follower's own last dial now
decides: ClusterService.followerRefusal (the refusal, or a link opened
since) is a running part's published lastError (no new field);
ClusterLocalNetworkAccess.state reads it as blocked whatever the probe
found. The leading Mac's wait ends at once on the member's refusal
(otherMacRefused) with what to do there (localNetworkRefusalLines); the
joining Mac's follow says its own refusal once (localNetworkBlockedLines);
the wizard's step names the build's app (ClusterService.appName via
ClusterOnboardingCommand.app) and says plainly where to turn it on,
through Screen Sharing on a Mac with no display.
- P2-3: darkbloom start on the member, with no terminal, replaced its
session service silently and then waited 10 min 37 s with no reason.
ClusterPairCommands (three spots: serve's service step, its end, and
waitUntilServing's loop) says what the service step does, ends the wait
at once when this Mac's service reports blocked, and says the instruction
instead of the loading lines, exit 1.
- P2-4: Retry after the pair was stopped only waited for parts nothing would
start, and q was ignored. Retry on a stopped pair says so and serves;
the start's wait leaves at q, Esc or Ctrl-C (as a key) with a line.
- P2-7: the joining Mac's window showed nothing while the leader sat at ✗.
The follow says each new state of the leader's start, and where to choose
Retry once a part ended there.
Red: ProviderCoreTests theFollowersOwnRefusalIsTheTruth after seams holding
today's behaviour, 4 issues; onboarding's new checks against today's
sources, 1174/6. Green: onboarding 1180/0 (the real runner, sandboxed;
one existing check's expected last line reworded with the new wording);
ProviderCoreTests 8-suite filter 69 tests and #1774's 8 suites 67 tests
(prod build); control 229/0, placement flow-run 33, setup 264,
provisioning 161/0, diagnostics, the placement library's checks and GLM
image admission (40) pass; product build OK; docs gates OK.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… side From the DevNet validation on pair-2: - A-13: a non-production install keeps its own incident file (ClusterIncidentLog.defaultFile(homeDirectory:install:): incidents.dev.json), which an older build never reads or rewrites; production keeps incidents.json. Every reader and writer opens this build's with ClusterIncidentLog.forThisInstall (the helper for the onboarding branch's A-4 read); the install stamp stays as a second check. The snapshot reads the install's file. - P2-2: the remaining DevNet names: no-terminal `cluster`, the "Cluster service" status lines (named by the CLI's Status.clusterServiceLines), the Ctrl-C line (made before the signal handlers are set), the member supervisor's restart hint and the pair update hints. - P2-5: a provider configuration other users can open that saves no setup (the installer writes it so for a non-production coordinator) is no saved setup, so doctor no longer fails on a fresh DevNet install; one that saves a setup fails with `chmod 600 <file>`. - P2-11: each Mac's cluster service reports startsAtLogin in its status (under its login agent's supervisor, agent installed; no launchctl). - P2-13: on the leading Mac, other_mac.answers is true while both run the cluster or confirm its leader. - P2-8: on the Mac that follows, cluster status and status wait at most 10 s for the leading Mac's answer, say so after 3 s, then show this Mac's own view. The ClusterConsole/Diagnostics/InstalledSession check runners compile ClusterObservability.swift by name; they now also compile its dependencies (ProviderBuildEnvironment, ClusterIncidentLog+Install). Docs: cli-reference (other_mac.answers, the bound, doctor's saved setup), architecture/inference (per-install files, startsAtLogin); changelog. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Brings this branch (162cf34: P2-1/A-2, P2-3, P2-4, P2-7) up to the final onboarding head: 68130a8, the refactor pass 7e7ddc6 and F1 3a0cc09. Conflict, ClusterOnboardingLive.swift, two hunks: - readinessOnce: this branch's one fetch of the member's status and its final refusal (otherMacRefused → otherMacLocalNetworkLine), with the head's endShown(member.child), which lost its own: parameter (F4). - the helpers: this branch's otherMacRefused, localNetworkRefusalLines and otherMacLocalNetworkLine, then the head's endShown doc and signature (also used by offeredReadiness and the rank 0 line). Merged on their own: ownPart(since:) read once, the rank-aware ownWorker(inIncidentLog:since:rank:otherRanks:), readyWaitSeconds and waitBegan (F5), Self.cli with ClusterService.cli gone, the useMode test (F6); and this branch's waitReady refusal branch, the follow, Retry and q, followerRefusal/serviceState, and its three ClusterPairCommands spots. In the merge: - waitReady's refusal branch passes ownPart(since: began) to lastErrors, so both ✗ paths read this Mac's part once, scoped to this start. - One phrase, one constant: followerRefusal matches F2's public ClusterService.localNetworkRefusal. It also needs the follower's "connected" and "session opened" lines (a refusal stays in the log after Local Network is turned on, and the follower doesn't log one per retry), now ClusterService.followerLinkOpenedLines, shared the same way. ClusterLinkFollowerCommand still spells those words itself; that file is the CLI branch's, so it is left for integration. Validation (prod-identity build; runners sandboxed, ObservabilityChecks outside the sandbox): onboarding 1180/0; ProviderCoreTests 8-suite filter 71 tests; #1774's 8 suites 67 tests; control 229/0, placement flow-run 33, setup 264, provisioning 161/0; diagnostics, GLM image admission (40), library placement pass; ObservabilityChecks 212/0; product build OK; docs-check 207, changelog 54, docs-impact-check BASE=6497e8e7a8 OK, git diff --check clean. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ay what shutdown cancels The refactor pass over the cancel-mid-prefill fix. Behaviour is unchanged. - ClusterWorkerPairAdmissionDeadlineTests: a lane that has produced a token keeps the clean stop. Its consumer leaves at its first token and does what the engine does (the clean stop, else a cancel) from inside the token callback: the lease accepts, and no rank is told to cancel. The check fails when producedToken is never set, and when it is set only after the token reached the consumer (both tried as mutants: its 3 assertions fail, the class's other 6 tests pass). - ClusterWorkerPair.shutdown and ClusterWorkerPairTiming.cleanStopWaitNanoseconds: a cancel ends the ranks except on a pair whose lanes retire alone, where it ends only that lane; such a lane still in its prompt takes no clean stop and is cancelled without the wait. - ClusterWorkerRequest.requestCleanStop: the doc states the lane exception with the rule it qualifies, and names ClusterWorkerPair.lanesRetireAlone. - docs/architecture/inference.md: the pair's shutdown cancels such a lane without waiting, too. docs/developer/test.md: the new check. - The changelog entry in plain words, with its limit: a pair that serves one request at a time still runs the prompt to its end. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… stop's pairStop - `ProviderUninstall.Operations.stopPair` is now `stopBothMacs`, and its result `ProviderUninstall.PairStop` is now `PairStopOutcome`. The live closure called `Cluster.Stop.pairStop(role:serving:)`, which returns another `PairStop` (who stops), and returned this one (how the stop ended), in the same lines. `stopBothMacs` is also the name the cluster CLI branch gives its own pair stop for `cluster stop --service`. - `otherMacStillServingLine` is now `otherMacNoAnswerLine`: it is shown when the other Mac did not answer (`.noAnswer`, `pairNoAnswer`), and that Mac's part keeps restarting rather than serving. - The live pair stop is `Uninstall.stopBothMacs(_:)`, over the `ClusterPairActions` `darkbloom stop` uses (`ClusterPairActions.live(config: nil)`: the same `ClusterOnboardingOperations.live(.clusterService(config: nil, worker: nil))` resume and stop), still run detached. A new test pins its mapping with stand-in actions: a serving member and a leader ask the pair; an idle member and an unpaired Mac don't; a failure is no answer, with its lines; an unreachable cluster is no answer. No behaviour change; no assertion removed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The guide ships in the same dev round as the fixes for the first real run's product bugs, so it now describes that build instead of 6497e8e. Every quoted line is checked against the fix heads' code: fix/cluster-local-network-truth 9a1d633, fix/cluster-cli-devnet-findings 935dbe4 and fix/uninstall-member-tells-leader 4a3b0f0. - Port: a pair's local API is on 8000 in both apps (the lowest port up to 8020 free on both Macs when another program holds 8000; the card says which), only one app serves a pair at a time, and 8001 is only the DevNet app's single-Mac default (ClusterLocalServing.sharedPort). - Local Network (P2-1): the leader's ✗ comes at once ("The other Mac can't reach this Mac over the cable: macOS keeps Darkbloom there off the local network", then where to turn it on); the joining Mac's "This Mac can't reach the other Mac over the cable: …"; a scripted start ends at once, exit 1. Still the person's action, in System Settings, without waiting for a prompt. - Retry and q (P2-4): Retry starts a stopped pair; q, Esc or Ctrl-C leaves with "Left the start: …", exit 1. The joining Mac's lines (P2-7). - doctor (P2-5): no cluster FAIL before the first setup ("Saved setup: notConfigured"); the chmod 600 FAIL for a saved setup others can open. - DevNet names darkbloom-dev everywhere (P2-2); the waiting lines of stop, restart and a scripted start (A-11); the scripted start's session-service line (P2-3); the follower's 3 s / 10 s status lines (P2-8); uninstall asks the pair to stop first and names a silent other Mac (P2-16). - Every "a later build …" note and every line about a fixed bug is gone; G-3 (Start over after installing the other app) stays. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Beside the other install, step 2 asks the pair to stop before it stops this install's cluster service. That stop answers once both Macs have stopped, after their accepted requests (the stop over the cable gives up after 330 s), and meanwhile the uninstall printed nothing after "→ Remove this install's cluster service": minutes of silence. `Uninstall.stopBothMacs` now says, before it waits, once and only when it asks the pair (a leader, or a serving member): "Asking the pair to stop; accepted requests finish first (up to about 6 min)." (`ProviderUninstall.pairStopWaitLine`), through `ClusterPairCommands.printLine` (flushed), as step 1 says its drain's deadline before it waits. Nothing else prints differently. Red first: with the test's new expectations on e0c90d3, the tests target did not compile, 5 x "extra argument 'say' in call": the pair's stop had no way to say anything. Green: 96/96 (the uninstall's prod set), 66 in 9 (#1774's set). Docs: `cli-reference.md` step 2 names the line, and no longer also says "the pair is not stopped": beside the other install, the pair is asked to stop when this install's service serves it, and the other install's pair is not asked. The changelog line says it is said. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… it; a refusal the follower got past no longer counts
- A start run from the joining Mac's own window forwards its wait to the leader. For a refused member, the leader
answered with its own line ("the other Mac can't reach this Mac …"), so the joining Mac's ✗ told its person to fix
the leading Mac. `readinessOnce` now words the line for the screen that shows it (`localNetworkLine(forwarded:)`).
`waitReady` gives the joining Mac its own instruction (`localNetworkBlockedLines`, "then choose Retry here").
- A-3's reason for an ended part read the last refusal even after the follower had connected. So a planned stop
after Local Network was turned on published a stale refusal:
- the leader's wait ended at once with a ✗;
- `endShown` showed the clean stop as an end;
- the Mac read as blocked.
The ended part's reason now reads the follower's last dial too (`followerRefusal`), one rule for running and ended
parts. The A-3 case with no later link is unchanged.
- `ClusterService.appName` is the identity's `appDisplayName` (the bundle's `CFBundleName`), no longer the bundle's
file name minus ".app". The strings are the same for all three identities.
- Docs: `two-mac-cluster.md` and `architecture/inference.md` say both.
Red first: 3 issues, 1 for the forwarded wording and 2 for the stale refusal. Then green.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ter, an accurate saved-setup read doc - `ClusterOnboardingTerminal`'s signal handler wrote the cursor-show sequence from an `Array` it built inside the handler, an allocation that can deadlock if the signal lands inside malloc. It writes a `StaticString` now (the same 6 bytes, checked), so the handler only reads statics made beforehand, writes and exits. - `ClusterPairSummary.sayOnStandardError` repeated the CLI's `printError`; it calls it now (same bytes). - `optionalInstalledReference`'s doc said "diagnostics-only", but the setup screens, approval checks and member supervision read it too, so the relaxation for a file others can read reaches them; and "a file only other users can open" read as a file its owner can't open. Both corrected. No behaviour change. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…line; DevNet app path quoted The refactor pass on the agent setup guide (head 606bdc5). Behaviour described is unchanged; the guide reads the same for production and DevNet, with these fixes for a literal reader: - Step 7.3: the card has "a line about starting at login (such as `Starts by itself at login on both Macs.`)", and verify checks it on each Mac, whatever it says. True now (the card reads this Mac only) and once the card reads the other Mac's `startsAtLogin`; the guide no longer says what the card computes. - Verify (two Macs): `service.starts_at_login` false on a Mac is a STOP: the person runs `darkbloom cluster` there (the product's own hint), then check again. The sentence moves under the exit-status table, so "Otherwise" again refers to "not serving". - DevNet names: `~/.darkbloom-dev/"Darkbloom Dev.app"`, quoted, so step 1.4's codesign commands work when substituted (the first run's agent had to quote it). - Step 5.4: the joining Mac ends with the same ✓ or ✗ block; `You can close this window.` only after ✓. - Step 5.3: the Local Network line is an example (over SSH it names this Mac's screen). - Local Network row: Retry where the ✗ offers it (usually the leader); a start run from the joining Mac shows its ✗ there. - System Settings paths use → throughout, as the screens do. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… a per-install corrupt aside (red) From the review of the pair-2 round: - The 10-second wait also ran on the leading Mac, naming "the leading Mac" about itself, and bounded a script start's looks, whose timed-out forwards could pile up. A person's `cluster status` or `status` on the Mac that follows is the only bounded read. - Both installs moved a corrupt incident log to incidents.corrupt.json; DevNet's must be kept as incidents.dev.corrupt.json (ObservabilityChecks A23). Adds, at today's behavior, the seam that sees whether a read asks for the bounded wait and ClusterPairSummary.statusLines(leads:slow:…). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…rrupt incident copy The review of the pair-2 round raised three behaviour issues: - The 10-second wait ran on the leading Mac too, saying "the leading Mac's answer" about itself. ClusterPairSummary.statusLines bounds only when this Mac doesn't lead; the leading Mac's status waits as before. - A script start's or restart's looks were bounded too, so a timed-out look left its forward running beside the next one. Only a person's read (`live(config:bounded:)` from `cluster status` and `status`) is bounded; the scripted wait's looks wait as before, inside their own overall bound and lines. - A corrupt incident log was moved to incidents.corrupt.json by both installs. The aside is named after its file: incidents.dev.corrupt.json for DevNet; production's name stays (ObservabilityChecks A23). Docs: architecture/inference names each install's corrupt copy. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…efusal counts only while the follower can still be refused The status scan, which is part of P2-8 (a member's `status` took up to 29 s): - A running part's `lastError` now reads the log only for a link follower (`runningPartRefusal`). That is the only part that writes a refusal: rank 0, a coordinator-paired member and a solo server never do. - The result is remembered by the log's size since the part started, so a status read with nothing new written reads nothing. Before, every read walked up to 8 MiB back under the service's lock, and the joining Mac's window asks every second. - The output is the same. A member just allowed no longer reads as refused: - The follower redials 20 ms doubling to 1 s apart, plus up to a quarter of jitter (`ClusterLinkControlClient.connectLoop`). But it logs a refusal only when the refusal value changes (`note`), and every connect failure is the same `.connectFailed`. So after Local Network is turned on, a dial that now fails because the leading Mac's part isn't listening is never logged. The old refusal stays the follower's last line until it connects. - Retry never restarts a running follower. So the leader's Retry, or the joining Mac's own, could end at once on the old refusal with the same ✗: while the leading Mac's part was between restarts (up to 30 s apart), and at once after Retry started a stopped pair, from the ended follower's reason. The change: - Only a running follower's refusal blocks (`otherMacRefused`, `ClusterLocalNetworkAccess.state`). - The leader's wait ends on it only once its own part, which hosts the listener the follower dials, has run `refusalSettleSeconds` (20 s: its start up to the listener, plus a dial and its handshake; `refusalIsCurrent`). - A later "link refused:" line, a dial that got further and failed another way, supersedes the refusal. - A still-blocked member still gets the Local Network ✗ without waiting for the start to give up. Red first: 16 tests, 9 issues; then green. Docs: two-mac-cluster.md and architecture/inference.md. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… 2 integration
The CLI side of both DevNet rounds: A-1 CLI, A-11, A-13, A-12, A-5, and
pair-2's A-13 per-install incident file, P2-2, P2-5, P2-11, P2-13, P2-8,
with both refactor passes and three review closures.
Three conflicts, each kept both sides:
- ClusterService.swift, the unpair line when the other Mac isn't
reached: the CLI branch's reason (a ClusterSetupFailure's own text,
else the error) with the Local Network branch's command name
`\(OnboardingLive.cli)`, so there is one naming mechanism there and no
ClusterOnboardingCommand.named wrapper; production bytes are unchanged
("darkbloom"). The integration edit makes the two name sources one.
- ClusterLinkFollowerCommand.swift, the follower's refusal: line 1 from
the Local Network branch (the phrase from its shared constant,
ClusterService.localNetworkRefusal), line 2 from the CLI branch (the
app named for the running identity). The integration edit replaces
the CLI branch's helper with ClusterService.appName.
- ClusterPairCommands.swift, waitUntilServing's loop: the Local Network
branch's early return when this Mac's service reports blocked, then
the CLI branch's status tracking (heartbeat lines, the wait's bound).
Merged on their own: the Local Network branch's other two spots in
serve (the session-service line, the blocked instruction and exit 1),
and the CLI branch's forThisInstall readers and startsAtLogin.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…2 integration P2-9: a lane whose consumer leaves during its prompt is cancelled and freed at once (test 66121ed, fix 55e3c93, refactor pass 5786f46: a lane's clean stop after its first token is guarded; the docs say what shutdown cancels). P2-6 assessed in its PR body. No conflicts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…nd 2 integration P2-16: a serving member's uninstall beside the other install stops the pair before this install's serving part, and says what the pair's stop waits for (test 8ce0886, fix 4a3b0f0, refactor pass e0c90d3 and de739bd). No conflicts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ntegration Plain words for the 0.10.8 cluster changelog fragments. Docs only. No conflicts; the uninstall fragment keeps this branch's reworded sentence and the uninstall branch's appended line. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…tegration The agent setup guide's fixes from its first real run (G-1 to G-12), round 2 (the fixed build) and its refactor pass (the card's login line true either way; the DevNet app path quoted). Docs only. No conflicts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… this install's incidents, per-Mac login line
The integration edits after merging the six DevNet round 2 branches.
1. One CLI name: ClusterOnboardingCommand.name starts from
BuildEnvironment.current.cliName in the package (#if SWIFT_PACKAGE; the
checks that compile the screens alone keep "darkbloom" and set theirs
with use), and OnboardingLive.cli reads it. The wizard's and main.swift's
own use(...) calls set the same value again and go. Production bytes are
unchanged.
2. One app name: ClusterService.appName (the identity's appDisplayName)
everywhere. The screens' seam starts from it and the link follower's
refusal reads it; Cluster.LinkFollower.localNetworkApp(cli:) goes.
Production's hint now says "Allow Darkbloom under ..." (decided), as the
✗ does. The DevNet exit test that pinned "darkbloom" through the helper
now checks the follower's real output.
3. The follower writes the words the service reads from ClusterService's
constants (followerLinePrefix, followerConnected, followerSessionOpened,
followerLinkRefused); followerLinkOpenedLines and followerLinkRefusedLine
are built from them. Bytes unchanged.
4. A-4 reads this install's incidents: OnboardingLive.ownWorker passes
ClusterIncidentLog.forThisInstall() (its file and install filter)
instead of production's defaultFile; the static reader takes the log, and
F1's real-records test passes it, its records and expectations unchanged.
5. P2-11, the ✓ card's login line (loginLine): "on both Macs" only when this
Mac's service outlives its window and the other Mac's status says
startsAtLogin; otherwise it names the Mac that doesn't, or says the other
Mac doesn't say. The new operation otherMacStartsAtLogin reads the other
Mac's status over the cable (default true). The guide's card line holds
(an example; verify checks each Mac).
6. P2-2 in onboarding: the member's Local Network hint names the app; its
command and the stop line already named OnboardingLive.cli, which now
follows the identity in exit tests too.
7. Found in validation: placement flow-run and setup didn't compile on
the CLI branch's changes (its validation didn't run them). run-flow.sh
now compiles ClusterIncidentLog+Install.swift and BuildEnvironment, as
the CLI branch did for the diagnostics runner; the setup runner gets
OnboardingCommandStandIn.swift (production's name), in its stand-in
pattern.
The development-build check (developmentBuildKeepsTheWindowsOpen) now says
the other Mac's service doesn't start at login either, as in a real
development pair; the card then says to keep both windows open, as before.
The changelog's A-4 sentence says the ✗ names this Mac's worker too, so it
doesn't read as contradicting the earlier "names the other Mac's side".
Red first:
- theLoginLineNamesTheMacThatDoesNot against the merged screens with only
the knob added: 6 failures; green with the change.
- onboardingTextsNameTheIdentity (DevNet identity): 3 issues;
followerWritesTheWordsTheServiceReads: 1 issue ("Allow darkbloom under").
Guards: onlyThisInstallsRecordsNameThisMac, theNamesAreThisBuildsWithoutBeingSet.
Docs: two-mac-cluster.md (the login line), architecture/inference.md (one
CLI name, one app name, the follower's phrases); changelog: a bullet in
cluster-candidate-findings.md.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…d's stand-in
ClusterConfigurationChecks compiles ClusterConfiguration.swift without the
onboarding screens. Since the CLI branch, its tensorAssistantServesLocally
names the command with ClusterOnboardingCommand.named, so the check stopped
compiling ("cannot find 'ClusterOnboardingCommand' in scope"), as the
placement setup check had; neither runs in CI.
It now compiles the setup check's OnboardingCommandStandIn.swift
(production's name), as it already compiles the installed session's
AttestationSignerStandIn.swift.
Red: on the integrated head 5732dda the check fails to compile. On dev
6497e8e it passes (9 file groups, the provider config file, 14
configuration groups). Green with this change: the same three pass, and
placement setup still passes 264.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ch Mac Read as a user, the 0.10.8 section contradicted itself: the console's bullet said every start ends with "Starts by itself at login on both Macs.", and P2-11's bullet says the card says so only when the cluster service on both Macs does, and otherwise names the Mac where it doesn't. The console's bullet now names the line by what it tells (whether it starts by itself at login on each Mac), as the guide does. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The ✗ line for a worker that ended on this Mac named the incident code ("worker_crashed in its incident log"). It now says "its worker ended unexpectedly"; the incident list in `cluster status` keeps the code.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
SummaryOnboarding fixes from two DevNet runs of The mode chosen for a model is the one that loads, GLM included (A-9). The ✗ after a part keeps ending names the right Mac (A-4, A-3, A-10).
Local Network truth (P2-1, A-2). When macOS's Local Network privacy keeps a Mac's link follower off the cable:
Also:
Linked issueNone: the DevNet validations' findings A-1, A-2, A-3, A-4, A-9, A-10 ( Test planEvery check binary was compiled outside the sandbox and run under a
Components touched
Protocol / interface changes
Documentation impact
Updated:
Changelog
Two bullets appended to Notes for reviewersWhere to look:
Decisions:
For integration with the CLI branch:
Limits:
Follow-ups: A-6, A-11, P2-2, the remaining P2 and A rows outside onboarding. Before And AfterBehaviourBefore flowchart TD
G["GLM: Pipeline chosen (listed first)"] --> TP["tensor parallel loads again"]
W["a worker killed on either Mac"] --> X1["✗ the link keeps closing; the other Mac's worker ended … (wrong for this Mac's own kill)"]
S["planned switch"] --> R["live row: parts ended (exit 0, stopped)"]
F["member's follower refused by macOS (the probe said allowed)"] --> X2["leader ✗: The other Mac did not answer over the cable … · its part is running, no error"]
F --> J["member's window: nothing"]
St["darkbloom start (no terminal)"] --> Q["silently replaces the session service · waits 10 min · no reason"]
Re["✗ Retry after cluster stop --service"] --> Wt["waits for parts nothing starts; q ignored"]
After flowchart TD
G["GLM: Pipeline chosen"] --> PP["kept; the adopt plans again in pipeline; pipeline loads"]
W["a worker killed"] --> I{"this Mac's incident records since the wait"}
I -->|this Mac's rank's own exit| X1["✗ this Mac's worker keeps ending"]
I -->|the other Mac's follower said| X2["✗ the other Mac's worker ended or the cable dropped"]
I -->|neither, both, or unreadable| X3["✗ can't be told; blames neither"]
S["planned switch"] --> R["clean stops aren't ends"]
F["member's follower refused"] --> Pub["its status: its part can't reach the local network …"]
Pub --> X4["leader ✗ at once: macOS keeps Darkbloom Dev there off the local network · turn it on there (Screen Sharing if no display) · Retry"]
Pub --> J["member's window and darkbloom start: the same instruction for this Mac"]
Re["✗ Retry on a stopped pair"] --> Wt["starting both Macs again · wait (q leaves with a line)"]
Code flowBefore flowchart LR
um["useMode: planned = modes.first"] --> ad["localAdopt: listed plan"]
t["keepsEndingTitle: closed → the other Mac"]
probe["startServiceProbe (broadcast)"] --> st["serviceState() = report"]
child["status lastError: nil while running"]
retry["finishStart .retry → waitForParts (no leave)"]
After flowchart LR
um["useMode: keptFamily"] --> ad["localAdopt: replansInFamily"]
op["ownPart(since:) once"] --> ow["ownWorker(inIncidentLog:since:rank:otherRanks:)"] --> t["keepsEndingTitle / errorLines"]
log["follower log: localNetworkRefusal / followerLinkOpenedLines"] --> fr["followerRefusal"] --> child["status lastError while running"]
child --> st["ClusterLocalNetworkAccess.state: blocked"] --> scr["wizard · follow · darkbloom start"]
child --> lead["readinessOnce: otherMacRefused → waitReady ends at once"]
retry["finishStart .retry: Stopped → serve"] --> wfp["waitForParts: leaving → .left"]
Refactor PassOutcome: a refactor commit (
Refactor Pass addendum (P2-1, P2-3, P2-4, P2-7)Outcome: one signed commit (
Addendum 2 (
|
SummaryFixes the CLI-side findings of two DevNet validations (
Linked issueNo issue: DevNet findings A-1, A-5, A-11, A-12, A-13 (M5 Ultra pair) and P2-2, P2-5, P2-8, P2-11, P2-13 (pair-2). Test plan
Components touched
Protocol / interface changes
All local or between the two Macs; no coordinator protocol change, no CLI flag change, no version bump.
Documentation impact
Changelog
Notes for reviewers
Before And AfterBefore: behavior flowchart TD
A["DevNet app: card, hints, cluster stop --service, no-terminal cluster, Ctrl-C, status service line"] --> B["print darkbloom ..."]
C["darkbloom-dev restart"] --> D["stop up to 330 s, teardown up to 300 s: no output"]
E["both installs"] --> F["one incidents.json and one corrupt copy"]
F --> G["older build rewrites it: stamps lost, logs mixed"]
H["fresh DevNet install, paired Mac"] --> I["doctor: FAIL cluster savedConfiguration, exit 1"]
J["leader cluster status --json while serving"] --> K["other_mac.answers null"]
L["member cluster status"] --> M["silent, up to 30 s per forward"]
N["leader's card"] --> O["Starts at login on both Macs, from this Mac alone"]
After: behavior flowchart TD
A["DevNet app: the same outputs"] --> B["print darkbloom-dev ... and Darkbloom Dev"]
C["darkbloom-dev restart"] --> D["says each wait and its bound"]
E["DevNet install"] --> F["its own incidents.dev.json and incidents.dev.corrupt.json"]
E2["production"] --> F2["incidents.json: own records plus unstamped"]
H["fresh DevNet install, paired Mac"] --> I["doctor: no saved setup yet, no FAIL"]
H2["saved setup in a file others can open"] --> I2["FAIL with: run chmod 600 file"]
J["leader cluster status --json while serving"] --> K["other_mac.answers true"]
L["member cluster status or status"] --> M["after 3 s says it waits; at 10 s shows its own view"]
L2["leader status, and a script start's checks"] --> M2["wait as before, no bound"]
N["each Mac's status"] --> O["startsAtLogin for the other Mac's card"]
Before: code flow flowchart LR
W["wizard only"] -->|use cliName| N["ClusterOnboardingCommand.name"]
T["CLI and ProviderCore texts"] --> Lit["literal darkbloom"]
Obs["ClusterObservability, ClusterService, ClusterDiagnostics"] --> Shared["defaultFile: incidents.json"]
Doc["doctor"] --> Strict["optionalInstalledReference: private read only"]
Live["liveFacts"] --> Fwd["operations.status"]
After: code flow flowchart LR
Main["main.swift"] -->|use cliName| N["ClusterOnboardingCommand.name"]
N --> CLI["ClusterPairSummary.cli and Status.clusterServiceLines"]
N --> PC["ClusterOnboardingCommand.named"]
Obs["ClusterObservability, ClusterService, ClusterDiagnostics"] --> FTI["ClusterIncidentLog.forThisInstall"]
FTI --> Own["defaultFile homeDirectory install: incidents.install.json"]
Doc["doctor"] --> Ref["optionalInstalledReference: no setup in an open file is not configured"]
Live["live config bounded"] --> SL["statusLines leads slow"]
SL -->|follower and a person's read| BS["boundedStatus: 10 s, said after 3 s"]
SL -->|leader, or a script start's check| Fwd["operations.status, as before"]
Svc["cluster service status"] --> SAL["ClusterServiceAgent.startsAtLogin"]
Refactor PassA dedicated refactor subagent reviewed the change (AGENTS.md § Required Refactor Pass). It made one small commit that
Checked and unchanged:
Known limits:
Rerun after the pass (prod build identity, sandboxed):
Refactor Pass addendumA dedicated refactor subagent reviewed the pair-2 round (
Checked and unchanged:
Known limits:
Rerun (prod build identity, sandboxed):
All three known limits are closed in |
SummaryA client that closed its connection during a long prompt kept a two-Mac pair busy for minutes. The pair's lease took Linked issueNone filed. DevNet validation finding P2-9 (pair-2, Test plan
Components touched
Protocol / interface changes
Documentation impact
Changelog
Notes for reviewers
Before And AfterBefore: behavior sequenceDiagram
autonumber
participant Client
participant Engine as Leader engine
participant Lease as Pair lease
participant Ranks as Both ranks (TP batch)
participant Next as Newer requests
Client->>Engine: 60K-token prompt
Engine->>Ranks: reserve, start (lane 1)
Client--xEngine: closes the connection 15 s in
Engine->>Lease: requestCleanStop()
Lease-->>Engine: accepted (stop at the first token)
Note over Ranks: nothing sent: both Macs prefill the whole prompt (about 4 min)
Next->>Ranks: admitted to other lanes
Note over Ranks: one prompt prefills at a time, oldest first
Note over Next: each times out at its first-token deadline (about 11 s): "Response generation failed", then 429s
Ranks-->>Lease: first token, clean stop, retired
After: behavior sequenceDiagram
autonumber
participant Client
participant Engine as Leader engine
participant Lease as Pair lease
participant Ranks as Both ranks (TP batch)
participant Next as Newer requests
Client->>Engine: 60K-token prompt
Engine->>Ranks: reserve, start (lane 1)
Client--xEngine: closes the connection 15 s in
Engine->>Lease: requestCleanStop()
Lease-->>Engine: declined (a lane with no token yet)
Engine->>Lease: cancel()
Lease->>Ranks: cancel lane 1
Ranks-->>Lease: retired (cancelled) at the next step boundary
Next->>Ranks: served at once
Before / After: code flowchart TB
subgraph Before
direction TB
b1["DistributedCBv2Engine.stop(.cancelled)"] --> b2["lease.requestCleanStop()"]
b2 --> b3["ClusterWorkerRequest: accepted, cleanStopRequested"]
b3 --> b4["ranks prefill to the first token"]
b4 --> b5["tokenDecision(.cleanStop): finished, retired"]
end
subgraph After
direction TB
a1["DistributedCBv2Engine.stop(.cancelled)"] --> a2["lease.requestCleanStop()"]
a2 --> a3{"lanes retire alone and no token yet?"}
a3 -->|"yes"| a4["false: engine calls lease.cancel()"]
a4 --> a5["both ranks retire that lane at the next step"]
a3 -->|"no"| a6["accepted: clean stop at the next token, as before"]
end
classDef bad fill:#fee2e2,stroke:#b91c1c,color:#7f1d1d;
classDef good fill:#dcfce7,stroke:#15803d,color:#14532d;
class b4 bad;
class a4,a5 good;
Refactor PassA dedicated refactor subagent reviewed the fix and added one signed commit (
|
SummaryUninstalling the member of a serving pair, beside the other install on the same Mac, no longer leaves the leader looping (pair-2's P2-16). Before, step 2 stopped this install's cluster service with SIGTERM, as Now step 2 first asks the pair to stop on both Macs, as Linked issueCloses # (pair-2 DevNet validation, P2-16; follow-up to #1780) Test plan
Components touched
Protocol / interface changes
Documentation impact
Changelog
Notes for reviewers
Before And Afterflowchart LR
subgraph Before["Before (pair-2 §5.4)"]
direction TB
b1["darkbloom-dev uninstall on the serving member<br/>(production app also on this Mac)"] --> b2["step 2: SIGTERM this install's service<br/>(as cluster stop --local-only)"]
b2 --> b3["leader: 'this Mac's part ended (exit 1) … starting it again'<br/>'the lease to the other Mac did not go through' — loops"]
end
subgraph After
direction TB
a1["darkbloom-dev uninstall on the serving member"] --> a2["step 2: stopPair()<br/>(as darkbloom stop: the member asks the leader; both stop)"]
a2 -->|stopped| a3["SIGTERM this install's (now idle) service; remove its agent"]
a2 -->|no answer| a4["local stop as before;<br/>summary: 'The other Mac (name) did not answer … run `darkbloom-dev cluster stop` on it.'"]
a3 --> a5["check before deleting → delete this install's files<br/>pairing, cable, cluster files stay"]
a4 --> a5
end
flowchart LR
subgraph Code["Code path (After)"]
direction TB
c1["ProviderUninstall.run (shared path)"] --> c2["removeOwnClusterService(label, keptFor:, otherMac:, operations:)"]
c2 --> c3["operations.stopBothMacs()<br/>Uninstall.stopBothMacs: says the wait line → resume → Cluster.Stop.pairStop → stop()"]
c2 --> c4["ClusterServiceAgent.remove(label:) · operations.stopClusterService(pid)"]
c1 --> c5["summary: otherMacNoAnswerLine when the pair did not answer"]
end
Refactor PassThe dedicated refactor subagent ran. Verdict: changed. Two signed commits on
|
SummaryPlain words for four 0.10.8 changelog fragments, read as a user would. The internal terms ("candidate", "tensor
Linked issueNone: the 0.10.8 preparation's changelog review ( Test plan
Components touched
Protocol / interface changes
Documentation impact
Changelog
Notes for reviewersEach change, with what it was checked against: 1.
2.
3. Qwen, said once, with why. Two bullets became one.
The joining Mac's ending. Two bullets became one, and "Only a leader on an older build leaves it to test the pair itself." is dropped: a pair of mixed builds can't serve together, and the notes say both Macs must run 0.10.8.
The registration line, its own bullet.
"Scope switch".
4.
Before And AfterThe before → after of each sentence is under Notes for reviewers. Refactor PassNot run: a wording-only change to four changelog fragments, with no code. Each changed sentence was checked against the |
SummaryAn AI agent followed
Linked issueNone filed: the 2026-11-04 DevNet validation of Test plan
Components touched
Protocol / interface changes
Documentation impact
Changelog
Notes for reviewers
Before And Afterflowchart TB
subgraph Before["Before (the guide in dev at 6497e8e7a8)"]
A1["agent reads agent-setup.md"] --> B1{"DevNet?"}
B1 -->|"rule 9 forbids darkbloom-dev"| X1["refuse, or guess every name"]
A1 --> D1["step 2: doctor exit 1 on cluster savedConfiguration"] --> S1["STOP"]
A1 --> P1["step 5.3: wait for a Local Network step"] --> N1["never shown; macOS blocks the other Mac's link"]
N1 --> F1["✗ did not answer over the cable: no matching row"]
end
subgraph After["After (the fixed build)"]
A2["agent reads agent-setup.md"] --> B2{"network the person chose"}
B2 -->|production| P2["steps 1–7"]
B2 -->|DevNet| V2["DevNet (testers only): darkbloom-dev, DevNet installer, Darkbloom Dev.app, pair API on 8000"] --> P2
P2 --> D2["step 2: no cluster FAIL before the first setup; chmod 600 line if the file is open to others"]
P2 --> L2["step 5.3: STOP; the person turns on Local Network in System Settings on each Mac"]
L2 --> C2["verify: cluster status --json on each Mac"]
L2 -->|"still off at the start"| T2["✗ at once: macOS keeps Darkbloom there off the local network → turn it on, Retry"]
end
Refactor PassA dedicated refactor subagent reviewed
Gates: |
…ments Release Integrity's test-provider-identity.py allows the DevNet and staging names only in the generated identity. Three doc comments added in this round quoted them; they now say the value comes from the build identity. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Summary
DevNet round 2 in one PR: six branches merged in order, their conflicts resolved, and one integration commit. It fixes
what two DevNet validations of
dev6497e8e7a8found (the production M5 Ultra pair: A-n; pair-2, an M3 Ultra and anM5 Max: P2-n), updates the agent setup guide after its first real run, and puts the 0.10.8 changelog in plain words.
Each branch's own PR body follows as a comment.
The M5 Ultra pair (DevNet
6497e8e7a8)darkbloom-dev, and the app "Darkbloom Dev", in every command and hint it shows for apair: the setup screens and their live operations,
start/restart's card,cluster stop --service,cluster local,pair --forget, and the link follower's Local Network hint.truth, not the service's broadcast probe; every screen says so and what to do on that Mac.
Mac's own incident records, of this install only; otherwise it says it can't tell and blames neither Mac.
restart,stop,cluster stop --serviceand a scriptstartsay what they wait for and their boundinstead of going quiet. The split setup after a leader-only restart underneath it is reported, not changed.
statusonce a minute, not every second.incidents.dev.json) and corrupt copy, and reads only its ownrecords.
Pair-2
darkbloom startsay plainly what to do on therefused Mac, and the leading Mac's wait ends at once once its own part has run 20 s.
darkbloom-dev: no-terminalcluster, the status lines, Ctrl-C, the pairupdate hints, and the setup's Local Network hint, which also names the app.
darkbloom startends at once on a Local Network refusal, with what to do and exit 1, and says when itreplaces a session service with the login agent.
darkbloom-dev doctorno longer fails right after install on a paired Mac; a saved setup others can openfails with the fix (
chmod 600 …).cluster statusandstatuswait at most 10 s for the leading Mac; arunning part's status reads its log only when it is a link follower, and only once the log grew.
otherwise it names the Mac that doesn't, or says the other Mac doesn't say. The status the Macs exchange now carries
startsAtLogin.cluster status --jsonfillsother_mac.answers.says so before it waits.
Docs
Not in this PR: A-6 (a stale roster after a re-pair), A-7 and P2-15 (a long prompt holds other first tokens under
mixed load; by design for 0.10.8), A-8 (explained: the listed split is planned while a serving model holds memory),
P2-12's B15 and B19, P2-14 (the DevNet app reads the production app's pairing as its own), and the shelved
request-limits branch (the catalog's Qwen
max_output_length65,536 against the pair's 32,768; the owner's call).Linked issue
None filed: the findings of two DevNet validations of
dev6497e8e7a8(on the production M5 Ultra pair, A-n; onpair-2, an M3 Ultra and an M5 Max, P2-n), and of the agent setup guide's first real run (G-1 to G-12).
Test plan
On the integrated head
5732dda926, prod identity unless noted, then re-run by an independent validator with the sameresults. Its two commits on top (
ef3461aaba, Notes item 8) touch only a check runner, its stand-in and a changelogline.
1b7723ed76(Notes item 9) changes one on-screen string, re-checked withClusterServiceStopReasonTests|ClusterOnboardingPeerLabelTests(32 passed). The final head41a73a8da8(item 10)changes three doc comments for Release Integrity. Every check binary ran under
sandbox-execwith a profile that denies~/.darkbloom*(
no-darkbloom.sb); everyswift testwas filtered and--skip-build:sandbox-exec … env DARKBLOOM_RELEASE_ENVIRONMENT=prod nice -n 19 swift test --disable-sandbox --skip-build --filter '…'.DARKBLOOM_RELEASE_ENVIRONMENT=prod swift build --build-tests --jobs 6: OK; no new warning in the touched files.ProviderCoreTests, the 8-suite onboarding filter(
ClusterOnboardingPeerLabelTests|ClusterPlacementTensorWidthTests|ClusterPlacementTensorWidthRegisteredTests|DistributedAutomaticBatchPlannerTests|MiMoImageOnboardingSelectionTests|ChildExitWaitConventionTests|ClusterServiceLogScanTests|ClusterServiceStopReasonTests):77 tests in 8 suites passed (the Local Network branch's 75, plus the integration's two). It includes
ClusterServiceStopReasonTestsand F1's real-records test.ClusterConsoleCommandTests,ClusterDevNetFindingsTestsandStatusCommandRunTests): 72 tests in 10 suites passed (71, plus the followertest).
ClusterPairTwoFindingsTests,ClusterBoundedWaitScopeTests,ClusterServiceStartsAtLoginTests(P2-11's status field),ClusterInstalledReferenceTests): 10 tests in 4 suites passed.ProviderCore set: 52 in 8. P2-16's prod set: 96 (92 in 5 + 4 in 1).
swift build --build-testswithoutDARKBLOOM_RELEASE_ENVIRONMENT): P2-16's dev set 33passed (29 in 1 + 4 in 1, as in the uninstall branch's own dev run); the DevNet-name tests 6 passed:
theNamesAreThisBuildsWithoutBeingSet(with nothing set, the names aredarkbloom-devand "Darkbloom Dev"),followerWritesTheWordsTheServiceReads("Allow Darkbloom Dev under"),onboardingTextsNameTheIdentity,clusterTextsNameTheIdentity,startCardNamesTheIdentityandremainingTextsNameTheIdentity.with only its knob added; the DevNet exit test for the setup's names failed with 3 issues, and the follower test with
1 ("Allow darkbloom under"). All green after.
ClusterOnboardingChecks: 1204 passed, 0 failed (1180 + the P2-11 check's 24). Control 229/0, placement flow-run 33 and setup 264 (withthe runner fix, Notes item 7), provisioning 161/0, diagnostics pass, GLM image admission PASS (40 CPU
checks), library placement pass.
ClusterConfigurationCheckspass (9 file groups, the provider configfile, 14 configuration groups), with the stand-in from Notes item 8; it didn't compile on the CLI branch's change.
libs/darkbloom-clusterObservabilityChecks, inside the sandbox through a temporaryxcrunshim that addsswiftc -disable-sandbox: 213 passed, 0 failed (212 + the CLI branch's A23).libs/darkbloom-cluster, the cancel branch's steps: RemoteChecks (the wholeDarkbloomClusterRemoteTeststarget) 87 XCTest + 3 Swift Testing, 0 failures; LinkWorkerChecks 16 of 16 groups; ProcessChecks, focused (owner, readiness, retirement, endpoint, partial admission, clean stop, provider pipe, deadline pipe, clean-stop pipe) pass; QualificationChecks (SDKROOT=macosx) 79 of 80: the 80th,PairDriverTests.testRefusesWhileAWorkerFromThisPathIsStillRunningAndCountsIt, counts worker processes by path, which the sandbox hides, and fails the same way ondev(the cancel branch's run)ClusterInstalledSessionChecks: compiled, not run: all 6 executables (Swift 6, warnings as errors).ClusterConsoleChecksisn't run: it doesn't compile here or at6497e8e7a8(its file list lacksClusterApprovalFallback; a follow-up).swift build --jobs 6 --product darkbloom(prod): OK.make docs-check207 files OK ·make docs-impact-check BASE=6497e8e7a874 changed files atef3461aaba(73 at5732dda926), coverage OK ·make changelog-check55 valid fragments ·
make changelog-previewexit 0 ·git diff --checkclean.swift test. The pair-2 re-test after the DevNet build:repro2.py 61000 15);Components touched
Local Network check; the pair commands, status, doctor, uninstall and link follower; the incident log's per-install
file. Also
libs/darkbloom-cluster:DarkbloomClusterRemote's incident log and its snapshot, and the worker owner'sshared exit marker (F1);
DarkbloomClusterProcess's lane cancel (P2-9); their checks.Protocol / interface changes
All local, or between the two Macs over their cable. No coordinator protocol, HTTP endpoint, config key or CLI flag
changes; the registration and the release's cluster runtime facts are unchanged.
installfield (A-13): written by this build, left out when absent and read asproduction's.
schema_versionstays 1, and an unknown field is ignored (F3).~/.darkbloom/cluster/incidents.json; another install keeps its own,incidents.<install>.json(incidents.dev.json), and its own corrupt copy. Every reader and writer opens thisbuild's through
ClusterIncidentLog.forThisInstall, A-4's ✗ included (integration edit 4). DevNet records already inincidents.jsoncount as production's until they age out or are dismissed.ClusterServiceStatus.startsAtLogin: Bool?(JSONstartsAtLogin, between the two Macs;darkbloom status --jsonshowsservice.starts_at_login): each Mac's cluster service sets it in every status it answers. An olderbuild ignores it; nil from an older build means unknown, which the card says as "the other Mac doesn't say".
lastError(ClusterServiceStatus.Child.lastError, existing): a running link follower'sLocal Network refusal, where it was nil while the part ran; an ended part's reason reads the follower's last dial. A
reader on an older build shows it as that Mac's error line.
cluster status --json: no new keys;other_mac.answersis filled on the leading Mac.Documentation impact
Canonical documentation updated
No documentation needed — reason:
docs/provider/two-mac-cluster.md: the chosen mode; the ✗ for each Mac's worker; Local Network on each screen;darkbloom start, Retry and q; the joining Mac's view; the card's login line per Mac.docs/provider/cli-reference.md:darkbloom starton a paired Mac; the waits;darkbloom uninstall's step 2.docs/provider/troubleshooting.md: the uninstall's pair stop.docs/provider/agent-setup.md: the guide's G-1 to G-12 and the fixed build.docs/architecture/inference.md: the person's family, Local Network truth, one CLI name and one app name, theincident files per install,
startsAtLogin, and the pair's shutdown cancelling a lane still in its prompt.docs/developer/test.md: the new cancel check.Changelog
Added or updated this PR's unique
changelog.d/<topic>.mdfragment and ranmake changelog-check.No user-visible change, or an explicitly authorized release/history change.
New:
cluster-cancel-mid-prefill.md(P2-9).Appended:
cluster-everyday-commands-on-a-pair.md(the CLI side, both rounds),cluster-candidate-findings.md(theonboarding and Local Network bullets, and the card's login line),
provider-uninstall-keep-or-remove.md(P2-16),provider-agent-setup-guide.md(the guide).Reworded:
cluster-candidate-findings.md,cluster-console-clarity.md,cluster-start-says-serving-only-when-loaded.mdandprovider-uninstall-keep-or-remove.md(plain words).make changelog-check: 55 valid fragments. The 0.10.8 section ofmake changelog-previewwas read as a user: one overlap fixed. In "Two-Mac cluster: Serve locally only starts the faster local plan, and a closing link names the other Mac", the earlier bullet says the ✗ names the other Mac's side instead of blaming this Mac, and the A-4 bullet now says the ✗ names the Mac whose worker actually stopped, "this Mac's included", so the two don't read as contradicting. The everyday-commands entry keeps one incidents bullet and one DevNet-names bullet per CLI round; each is true. The independent validation found one more:cluster-console-clarity.mdsaid every start's card ends with "Starts by itself at login on both Macs.", which P2-11's bullet now limits to both Macs starting at login; that bullet now says the card says whether it starts by itself at login on each Mac.Notes for reviewers
Merge order (each a signed merge commit, "Merge () into the DevNet round 2 integration"):
fix/cluster-local-network-truth(contains the onboarding stack3a0cc09c49)8552ba7109f80a0a4e97fix/cluster-cli-devnet-findingse1a85413208075ea1f41fix/cluster-cancel-mid-prefill5786f46ad84240ecc7b4fix/uninstall-member-tells-leaderde739bd8dca4404ad933docs/changelog-0108-wording1dc927166296dbac97c8docs/agent-setup-first-runf35866d88a7ef22a01a0Then the integration commit
5732dda926, the independent validation's two commits (item 8 below) and one wordingcommit (item 9) and one comment-only commit (item 10). The request-limits branch is shelved.
The three conflicts (merge 2), each keeping both sides:
ClusterService.swift, the unpair line when the other Mac isn't reached: the CLI branch's reason (aClusterSetupFailure's own text) with the Local Network branch's\(OnboardingLive.cli), so the line has one namingmechanism, without the CLI branch's
ClusterOnboardingCommand.namedwrapper. Production bytes are unchanged.ClusterLinkFollowerCommand.swift, the follower's refusal: line 1 from the Local Network branch (the phrase from theshared constant
ClusterService.localNetworkRefusal, which A-3 reads), line 2 from the CLI branch (the app's name;edit 2 then gives it one source).
ClusterPairCommands.swift,waitUntilServing: the Local Network branch's early return when this Mac's servicereports blocked, then the CLI branch's status tracking (its heartbeat lines and bound). The Local Network branch's
other two spots in
serve(the session-service line; the blocked instruction and exit 1) merged on their own. Theguide quotes lines from both sides.
Two fragments auto-merged across branches and were read after:
provider-uninstall-keep-or-remove.mdkeeps thewording branch's sentence and the uninstall branch's bullet;
cluster-candidate-findings.mdkeeps the plain words andthe Local Network branch's bullets.
The integration commit:
ClusterOnboardingCommand.namestarts fromBuildEnvironment.current.cliNamein the package(
#if SWIFT_PACKAGE; the checks that compile the screens alone keep"darkbloom"and set theirs withuse), andOnboardingLive.clireads it. The startup and wizarduse(…)calls set the same value again and go. Production bytesare unchanged.
ClusterService.appName(BuildEnvironment.current.appDisplayName) everywhere; the screens' seamstarts from it.
Cluster.LinkFollower.localNetworkApp(cli:)goes, and production's follower hint now says "AllowDarkbloom under …", as the ✗ does (decided).
ClusterService's constants: its prefix, "connected","session opened" and "link refused: " (the third phrase
followerRefusalreads). Bytes unchanged.ownWorkerpassesClusterIncidentLog.forThisInstall()instead ofproduction's file. F1's real-records test passes, its records and expectations unchanged.
ClusterOnboardingFlow.loginLine): "on both Macs" only when this Mac's serviceoutlives its window and the other Mac's
startsAtLoginis true; otherwise it names the Mac that doesn't, or saysthe other Mac doesn't say. The new operation
otherMacStartsAtLoginasks the other Mac's status over the cable.The guide's card line holds as written (an example; verify checks each Mac).
OnboardingLive.cli.validation didn't run them).
run-flow.shnow compilesClusterIncidentLog+Install.swiftandBuildEnvironment,as the CLI branch did for the diagnostics runner; the setup runner gets a stand-in for
ClusterOnboardingCommand(
OnboardingCommandStandIn.swift).252dbdd7bd:ClusterConfigurationChecksdidn't compile either, for the same reason as the setup runner(
ClusterConfiguration.swiftnames the command withClusterOnboardingCommand.named). It now compiles the samestand-in. Red: it fails to compile on
5732dda926and passes on6497e8e7a8; green: it passes, and setup stillpasses 264. Not run in CI.
ef3461aaba: the changelog line above (cluster-console-clarity.md).1b7723ed76): the ✗ line for a worker that ended on this Mac said "its worker ended (worker_crashedin its incident log)". It now says "its worker ended unexpectedly";
cluster statusstill lists the incident withits code.
41a73a8da8):scripts/test-provider-identity.pyallows the DevNet and staging names only inthe generated identity, and three doc comments added in this round quoted them. They now say the value comes from
the build identity. Comment-only; the build and
docs-impact-checkpass, and the whole Release Integrity list passeslocally except
.github/scripts/test-threat-diagnostics.py, which fails only under the local Python 3.14.Where to look:
ClusterOnboardingLive.swift(useMode,ownPart,ownWorker,readinessOnce,waitReady,otherMacStartsAtLogin);ClusterService.swift(followerRefusal,runningPartRefusal, the follower's words,appName);ClusterOnboardingFlow.swift(ClusterOnboardingCommand,loginLine, Retry and q);ClusterPairCommands.swift(serve,waitUntilServing);ClusterIncidentLog+Install.swift;ClusterWorkerPair.swiftandClusterWorkerRequest.swift(the lane cancel);ProviderUninstall.swift(stopBothMacs).Limits and follow-ups:
login agent is unverified.
install; an older production build lists DevNet'sincidents until it runs this code.
ClusterConsoleChecksdoesn't compile (since 10-31). A-6, A-7/P2-15, P2-12's B15/B19 and P2-14 are open.Refactor Pass).
Before And After
Behaviour
Before
After
Code flow
Before
After
Refactor Pass
Each branch had its own dedicated refactor pass; its full PR body, with its refactor sections, is posted as a comment.
fix/cluster-local-network-truth(with the onboarding stack): the onboarding refactor7e7ddc6952and F1's fix3a0cc09c49(A-4 counts only this Mac's own worker exits, from the real records), then the Local Network addendaf4eae6bb3b(the ✗ worded for the screen that shows it, one refusal rule for ended and running parts, one app name)and
8552ba7109(only a link follower's log is scanned, cached by its size; a refusal blocks only while the followerruns and after the leader's part ran 20 s). See comment 1.
fix/cluster-cli-devnet-findings: two refactor passes (9cc3b4ab2c: names and the incident contract pinned;539ee67e1a: an allocation-free Ctrl-C handler, one stderr writer, an accurate doc), then three review issues closed(
1727df88dered,e1a8541320). See comment 2.fix/cluster-cancel-mid-prefill:5786f46ad8adds the missing guard (a lane that produced a token keeps the cleanstop) and makes the comments and docs accurate for lane pairs; behaviour unchanged. See comment 3.
fix/uninstall-member-tells-leader:e0c90d3574renames the seam (stopBothMacs,PairStopOutcome) andde739bd8dcsays what the pair's stop waits for, red first. See comment 4.docs/changelog-0108-wording: a wording-only change; each sentence checked against the code and docs; no separatepass. See comment 5.
docs/agent-setup-first-run:f35866d88akeeps the card's login line true either way and quotes the DevNet app'spath; 30 quoted screen lines checked against the fix heads. See comment 6.
5732dda926had no separate refactor subagent: this integration was done withoutdelegating. Checked instead: production bytes are unchanged except the decided follower hint and P2-11's card line;
the screens' standalone compile keeps production's names; each new behaviour was red first; and the validation above
ran on the commit. A fresh agent then validated the integrated branch independently and reviewed this commit as a
refactor pass would: nothing that blocks the PR (two style nits left for later); it added the two commits in Notes
item 8.