0
0
resumed sandbox contract stays Held (finding 78)
docs/plans/0044-ci-by-hand.md+1−0
| @@ -382,6 +382,7 @@ everything and exits (finding 5). If its cleanup reports errors (`cleanupErrors` | ||
| 75 | The v0.0.0-rc168 tag build (53cad0e3): `stage` "killed after 900s": two small PUTs to Spaces answered UnknownError (retried), the 545 MB arm64 binary uploaded in 26 s, the amd64 one's PUT never returned: `publish-spaces.ts` gives a request no time limit. Rerun (attempt 2). Fix: every S3 request gets a limit that grows with the file (60 s + 1 s per 5 MB), so a hung PUT is aborted and `attempt` retries it (owner, 2026-11-16: not a control) | fixed | | ||
| 76 | CI test on 62841d92, 0005 FAIL "R2 not Held in 10 min". Cause: staging bidder b2 published no heartbeat until 17:31:48 (0006 reading `guestImageReadyAt`; b1 17:08:52), because a bidder writes no offering/heartbeat until its guest image verifies, and b2's 1.5 GB rootfs download from Spaces ran ~1 MB/s for 24 min (b1, same host, same object, same minute: 66 s; probes now 20-65 MB/s from hat-8 and from both staging VMs). `guestimage.fetchOne` had only the 30 min FetchTimeout, no per-attempt limit, no resume. R2 dropped b2 (`no fresh heartbeat`) and b1 was full. Fix: each attempt gets 60 s + 1 s per 5 MB still to fetch, then resumes with `Range` from the bytes already hashed (hand proof: a stream stalled at 10 of 40 MiB resumes and verifies in 70 s). Also: `requester_bidder_discovery` names each drop and its reason. Lesson: I cleaned up the frozen run before finding this; the cause came from the CI artifacts (0006 readings) | fixed | | ||
| 77 | CI test on b8b8ed18, 0006 and 0008 FAIL: b2's one startup ERROR `the HostProcess supervisor stopped` at 20:08:33.874: `APIBinding hostprocesses in root ... metadata.labels[claimed.internal.apis.kcp.io/...]: Invalid value: ""`. Cause: the computevm component and the HostProcess supervisor apply the same hostprocesses set at once (20:08:33.632/.665/.861); kcpapply skips an unchanged APIBinding only on a strict spec match, and the live spec carries the server default `deletionPolicy: Delete`, so every re-apply was an update; one landed after the create (20:08:33) and before `kcp-apibinding` stamped the claimed label (20:08:34), and admission refused it. Fix: an APIBinding is unchanged when every field the manifest declares matches the live spec (`covered`), so repeated and concurrent applies send no update Still red on bce9465b (the covered fix in): b1 `policy-binding.yaml` in set provider, computevm and hostprocess both applying it at 21:19:03.6, both reading no binding, so the second apply was an update before kcp stamped the label (live spec covered, managers socialweb-computer then kcp-apibinding 1 s later). Root: two components of one core apply the same set at once. Fix 2: kcpapply serializes Apply per (kcp, base, set name) in the process, so the second reads the created binding and sends nothing | fixed (2) | | ||
| 78 | CI test on 7bc127f1 (0006/0008 green: 77 fixed), 0013 FAIL `sbx1 is "Requesting" after the restart`. Cause: a resumed contract re-enters the guest wait and replays its events; network, host keys, secrets and image skip an event already recorded, the sandbox case did not, so the replayed sandbox event wrote `Requesting` ("awaitingGuestOnNetwork") over the Held contract (22:55:06.799) before the wait ended and wrote Held again; 0013's one read after the restart landed in that window. Fix: a sandbox event equal to the recorded one is skipped | fixed | | ||
| ||
## Runs | ||
| ||
internal/market/requester/runner.go+1−1
| @@ -1532,7 +1532,7 @@ func (r *contractRunner) waitGuest(ctx context.Context, state *v1alpha1.NodeClai | ||
r.writeStatus(ctx, v1alpha1.ComputeContractReleased, terminationMessage(parsed.Termination), state, r.currentBids(), r.currentChosen(), "terminated", 1) | ||
return true | ||
case market.ComputeEventsVMSandboxNSID: | ||
if parsed.Sandbox == nil { | ||
if parsed.Sandbox == nil || (state.Sandbox != nil && *state.Sandbox == *parsed.Sandbox) { | ||
return false | ||
} | ||
state.Sandbox = parsed.Sandbox | ||