oficina / equipo Public

placement: no Mac work on an older primary; recheck Engineering at start

Astra round 1 on mac-placement-wait (7 findings; 6 fixed, 1 declined):

1. An older primary (protocol 1) is no exception any more: Mac
   Engineering waits (waiting_mac) and checks that need macOS with no
   fitting runner wait for a Mac, never judged needs_macos on Linux.
   With a Mac enrolled but a primary that cannot relay, checks wait for
   a runner (waiting_runner, resolved as not run after the offline
   limit, as for an offline Mac).
2. Declined: a repository missing from the primary's catalog stays
   "needs no Mac". The runner keeps its catalog on disk (Index.Path),
   so an entry is missing only for a repository never indexed (the
   runner cannot fetch it); treating missing as unknown would stall
   every project the catalog does not list, which is most contract
   rigs' and any not yet indexed. Checks still wait when Engineering
   touched Apple files.
3. Engineering is placed again before it starts (Authorize): an
   attempt dispatched to the Linux primary before this rule, or before
   the catalog said Xcode, is refused (withdrawn) and its next attempt
   waits for a Mac.
4. Checks need a Mac when any Engineering round of the task touched
   Apple files, not only the one whose commit is the candidate (a
   delegated Copy commit or a README-only fix round keeps the Swift).
5. An exploration waiting for a Mac shows under Needs you
   (mac_runner / mac_engineering) and cancels like any task.
6. Gate-only checks placement is covered again, at the contract level:
   TestContractChecksWaitForTheGatesMac (no Apple files, base gate
   needs Xcode: waits, then runs on the Mac that enrols).
7. 4b_ask carries the Review write attempt 4_checks_honest lost:
   review:write:README.md, "Write to README.md was denied.", claude
   family and account, README unchanged by Review.

Tests first (red before the fix): TestContractMacWorkWaitsOnAnOlder-
Primary, TestContractMacEngineeringQueuedBeforeTheRule,
TestContractExplorationWaitsForAMac, TestChecksNeedAMacForEveryApple-
Round; TestContractChecksWaitForTheGatesMac is coverage (green, held by
P15).

Mutation checks (each broke one guard, ran the test, restored):
P10 protocol 1 Engineering exemption: ...OnAnOlderPrimary FAIL
P11 checks to an older primary: ...OnAnOlderPrimary FAIL
P12 no recheck at start: ...QueuedBeforeTheRule FAIL
P13 Apple of the candidate's round only: ...EveryAppleRound FAIL
P14 no exploration Mac need: ...ExplorationWaitsForAMac FAIL
P15 no gate need for checks: ...ChecksWaitForTheGatesMac FAIL
P16 4b_ask without the write attempt: TestHeadless/4b_ask FAIL

Local: go test ./internal/equipo/chat ./internal/equipo ./internal/wire
ok; ./internal/thintest -run 'Mac|Placement|Place|Explore|Worker|
Lease|Authoriz|Checks' ok; -tags testbuild ./internal/headless
TestHeadless/4b_ask ok; staticcheck clean; budget size, fmt-check,
lanes-check, runner-dead-references ok. Budgets: chat 38116/11998,
headless 11977, thintest 37223.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Paul Campbell pushed by paul@keymail.dev 741408280bbe7236f43ba6f78c1dbd227775a537 parent 570375e
6 files changed, +274 −19
  • .rastrillo/budgets.txt +3 −3
  • internal/equipo/chat/explore.go +5 −0
  • internal/equipo/chat/mac_needs_test.go +83 −0
  • internal/equipo/chat/runners.go +51 −14
  • internal/headless/ask_test.go +10 −2
  • internal/thintest/mac_wait_contract_test.go +122 −0

CI failed — run details

CI log
=== prepare ===
ci-box: machine: aarch64, 32 CPUs, 62 GiB memory, kernel 7.0.0-1017-aws
ci-box: python 3.12.3; Docker version 29.1.3, build 29.1.3-0ubuntu3~24.04.2
ci-box: user namespaces allowed: 233151
ci-box: cgroup: cgroup2fs
ci-box: disk /home/ci/work/repos/oficina__equipo/wt/mac-placement-wait: Type  Size Avail | ext4   96G   84G
ci-box: disk /home/ci/.cache/equipo-ci-box: Type  Size Avail | ext4   96G   84G
ci-box: bwrap: fetched and verified in 0.3s
ci-box: claude: fetched and verified in 1.8s
ci-box: codex: fetched and verified in 3.4s
ci-box: codex-code-mode-host: fetched and verified in 1.3s
ci-box: libwrap: fetched and verified in 0.3s
ci-box: socat: fetched and verified in 0.3s
npm warn deprecated node-domexception@1.0.0: Use your platform's native DOMException instead
ci-box: image pulled in 9.8s
ci-box: pi: installed and verified in 7.5s
ci-box: opencode: installed and verified in 2.3s
ci-box: chromium 156.0.8078.79-1~deb13u1: 76 packages fetched, verified and unpacked in 8.7s
ci-box: clone deepened in 4.7s
ci-box: file times set from content: 3285 files, 213 directories
ci-box: ready in 18.3s
=== copy ===
EQUIPO_RELEASE_COPY_CHECK=1 CGO_ENABLED=0 go test ./internal/equipotest -run '^TestReleaseCopyReviewed$' -count=1
ok  	amadan.net/oficina/equipo/internal/equipotest	0.148s
=== compile ===
go build ./...
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py compile
+ go build -tags testbuild ./...
  4.3s
+ go list -export -test -tags testbuild -f  ./...
  4.1s
+ go list -export -test -tags browser,testbuild -f  ./internal/equipo ./internal/equipotest ./internal/headless ./internal/idtest ./internal/plan3test ./internal/thintest
  3.6s
go run honnef.co/go/tools/cmd/staticcheck@v0.7.0 -version
staticcheck 2026.1 (v0.7.0)
go run golang.org/x/vuln/cmd/govulncheck@v1.8.0 -version
Go: go1.26.11
Scanner: govulncheck@v1.8.0
DB: https://vuln.go.dev
DB updated: 2026-11-24 15:56:00 +0000 UTC

go run github.com/zricethezav/gitleaks/v8@v8.30.1 version
version is set by build process
=== check ===
--- shard 0 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
test lane headless-work: ./internal/headless
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m -run '^TestHeadless$/^4c_rebase$|^TestHeadless$/^4b_ask$|^TestHeadless$/^4c_checks_card$|^TestHeadless$/^4_step_crash$' ./internal/headless

receipt: test step 1m18.919s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 1m16.954s amadan.net/oficina/equipo/internal/headless
receipt: slow test 1m16.95s amadan.net/oficina/equipo/internal/headless TestHeadless
machine: 32 CPUs, load 61.92, cpu waiting 37.17%, memory waiting 0.00%, io waiting 0.41%
--- shard 1 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
test lane headless-review: ./internal/headless
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m -run '^TestHeadless$/^4_review$|^TestHeadless$/^2b_access$|^TestHeadless$/^runner_crash$|^TestHeadless$/^2b_first_message$|^TestHeadless$/^4_checks_honest$|^TestHeadless$/^7_stream_resume$|^TestHeadless$/^2b_notebook$|^TestHeadless$/^2b_move_in$|^TestHeadless$/^2b_desk_failure$|^TestHeadless$/^cancel$' ./internal/headless

receipt: test step 1m17.634s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 1m15.638s amadan.net/oficina/equipo/internal/headless
receipt: slow test 1m15.64s amadan.net/oficina/equipo/internal/headless TestHeadless
machine: 32 CPUs, load 62.44, cpu waiting 37.37%, memory waiting 0.00%, io waiting 0.43%
--- shard 2 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
test lane headless-connections: ./internal/headless
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m -run '^TestHeadlessConnections$|^TestHeadlessTokenPasteEndToEnd$|^TestHeadlessTokenConnection$' ./internal/headless

receipt: test step 1m19.285s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 1m17.383s amadan.net/oficina/equipo/internal/headless
receipt: slow test 1m8.07s amadan.net/oficina/equipo/internal/headless TestHeadlessConnections
receipt: slow test 4.76s amadan.net/oficina/equipo/internal/headless TestHeadlessTokenPasteEndToEnd
receipt: slow test 4.55s amadan.net/oficina/equipo/internal/headless TestHeadlessTokenConnection
machine: 32 CPUs, load 61.92, cpu waiting 36.80%, memory waiting 0.00%, io waiting 0.40%
--- shard 3 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
test lane headless-mac: ./internal/headless
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m -run '^TestMacWorker$|^TestHeadlessAttachments$|^TestHeadlessPrewarm$|^TestHeadless$/^1_first_token$|^TestHeadless$/^6_quick_messages$|^TestHeadless$/^8_instance_restart$|^TestHeadless$/^3_runner_offline$' ./internal/headless

receipt: test step 1m16.881s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 1m15.073s amadan.net/oficina/equipo/internal/headless
receipt: slow test 38.28s amadan.net/oficina/equipo/internal/headless TestMacWorker
receipt: slow test 18.76s amadan.net/oficina/equipo/internal/headless TestHeadless
receipt: slow test 9.1s amadan.net/oficina/equipo/internal/headless TestHeadlessAttachments
receipt: slow test 8.93s amadan.net/oficina/equipo/internal/headless TestHeadlessPrewarm
machine: 32 CPUs, load 61.92, cpu waiting 37.17%, memory waiting 0.00%, io waiting 0.41%
--- shard 4 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
test lane headless-guards: ./internal/headless
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m -run '^TestHeadlessCopyRotation$|^TestHeadlessPolicyGuards$|^TestHeadlessRunnerKillLeavesNoCopies$|^TestHeadlessNewHouseRuleStartsFresh$|^TestHeadless$/^3_engineering$|^TestHeadless$/^3_step_cancel$|^TestHeadless$/^3_step_contained$|^TestHeadless$/^3_step_refused$|^TestHeadless$/^3_empty_repo$|^TestHeadless$/^3_empty_engineering$|^TestHeadless$/^3_empty_merge$|^TestHeadless$/^3_empty_merge_rebuilt$|^TestHeadless$/^3_empty_fix_round$' ./internal/headless

receipt: test step 1m35.604s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 1m33.68s amadan.net/oficina/equipo/internal/headless
receipt: slow test 1m4.12s amadan.net/oficina/equipo/internal/headless TestHeadless
receipt: slow test 9.4s amadan.net/oficina/equipo/internal/headless TestHeadlessRunnerKillLeavesNoCopies
receipt: slow test 7.99s amadan.net/oficina/equipo/internal/headless TestHeadlessCopyRotation
receipt: slow test 7.37s amadan.net/oficina/equipo/internal/headless TestHeadlessPolicyGuards
receipt: slow test 4.8s amadan.net/oficina/equipo/internal/headless TestHeadlessNewHouseRuleStartsFresh
machine: 32 CPUs, load 58.27, cpu waiting 36.17%, memory waiting 0.00%, io waiting 0.31%
--- shard 5 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
test lane headless-rest: ./internal/headless
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m -skip '^TestHeadless$/^4c_rebase$|^TestHeadless$/^4b_ask$|^TestHeadless$/^4c_checks_card$|^TestHeadless$/^4_step_crash$|^TestHeadless$/^4_review$|^TestHeadless$/^2b_access$|^TestHeadless$/^runner_crash$|^TestHeadless$/^2b_first_message$|^TestHeadless$/^4_checks_honest$|^TestHeadless$/^7_stream_resume$|^TestHeadless$/^2b_notebook$|^TestHeadless$/^2b_move_in$|^TestHeadless$/^2b_desk_failure$|^TestHeadless$/^cancel$|^TestHeadlessConnections$|^TestHeadlessTokenPasteEndToEnd$|^TestHeadlessTokenConnection$|^TestMacWorker$|^TestHeadlessAttachments$|^TestHeadlessPrewarm$|^TestHeadless$/^1_first_token$|^TestHeadless$/^6_quick_messages$|^TestHeadless$/^8_instance_restart$|^TestHeadless$/^3_runner_offline$|^TestHeadlessCopyRotation$|^TestHeadlessPolicyGuards$|^TestHeadlessRunnerKillLeavesNoCopies$|^TestHeadlessNewHouseRuleStartsFresh$|^TestHeadless$/^3_engineering$|^TestHeadless$/^3_step_cancel$|^TestHeadless$/^3_step_contained$|^TestHeadless$/^3_step_refused$|^TestHeadless$/^3_empty_repo$|^TestHeadless$/^3_empty_engineering$|^TestHeadless$/^3_empty_merge$|^TestHeadless$/^3_empty_merge_rebuilt$|^TestHeadless$/^3_empty_fix_round$' ./internal/headless

receipt: test step 2m56.429s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 2m54.43s amadan.net/oficina/equipo/internal/headless
receipt: slow test 1m38.72s amadan.net/oficina/equipo/internal/headless TestHeadlessAssistant
receipt: slow test 20.17s amadan.net/oficina/equipo/internal/headless TestHeadless
receipt: slow test 9.09s amadan.net/oficina/equipo/internal/headless TestHeadlessResearchHandoff
receipt: slow test 7.23s amadan.net/oficina/equipo/internal/headless TestHeadlessAssistantAttachments
receipt: slow test 6.69s amadan.net/oficina/equipo/internal/headless TestHeadlessTurnBatching
machine: 32 CPUs, load 21.52, cpu waiting 10.32%, memory waiting 0.00%, io waiting 0.07%
--- shard 6 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
test lane thintest: ./internal/thintest
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m -run '^Test([^C]|C[^o]|Co[^n]|Con[^t])|^TestContract(Assistant|Outcome|Team|Handoff|HostAllowlist|HostIsPerPerson|Look|Use[A-Z]|RemoteCall|LanesRunAtOnce|NoMergeQuestionWhenGateMerges|PreviewHeldUntilPublishAnswer|PreviewNotHeldBelow19|PublishNeedsOwnerAnswer)' ./internal/thintest

receipt: test step 2m19.104s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 2m16.835s amadan.net/oficina/equipo/internal/thintest
receipt: slow test 10.98s amadan.net/oficina/equipo/internal/thintest TestContractTeamJobSettledStates
receipt: slow test 6.75s amadan.net/oficina/equipo/internal/thintest TestExplorePreviewsOff
receipt: slow test 4.97s amadan.net/oficina/equipo/internal/thintest TestContractTeamNudgePersonNeeds
receipt: slow test 3.83s amadan.net/oficina/equipo/internal/thintest TestContractPreviewHeldUntilPublishAnswer
receipt: slow test 2.66s amadan.net/oficina/equipo/internal/thintest TestContractTeamUpdatePersonNeeds
machine: 32 CPUs, load 33.13, cpu waiting 18.81%, memory waiting 0.00%, io waiting 0.14%
--- shard 7 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
test lane thintest-contract: ./internal/thintest
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m -skip '^Test([^C]|C[^o]|Co[^n]|Con[^t])|^TestContract(Assistant|Outcome|Team|Handoff|HostAllowlist|HostIsPerPerson|Look|Use[A-Z]|RemoteCall|LanesRunAtOnce|NoMergeQuestionWhenGateMerges|PreviewHeldUntilPublishAnswer|PreviewNotHeldBelow19|PublishNeedsOwnerAnswer)' ./internal/thintest
rastrillo: budget test: go test failed
--- FAIL amadan.net/oficina/equipo/internal/thintest TestContractWorkerTaintIsSticky
=== RUN   TestContractWorkerTaintIsSticky
    placement_contract_test.go:555: waiting for send_pack: failed to get reader: context deadline exceeded
--- FAIL: TestContractWorkerTaintIsSticky (45.34s)

--- FAIL amadan.net/oficina/equipo/internal/thintest (package output)
FAIL
rastrillo-budget/v1 ran 2m41.143s
FAIL	amadan.net/oficina/equipo/internal/thintest	161.428s


receipt: test step 2m42.932s against a 60s target (the gate's other steps are not in this figure)
receipt: 0 packages ran, 0 cached, 0 without tests, 1 failed
receipt: slow package 2m41.143s amadan.net/oficina/equipo/internal/thintest
receipt: slow test 45.34s amadan.net/oficina/equipo/internal/thintest TestContractWorkerTaintIsSticky
receipt: slow test 9.28s amadan.net/oficina/equipo/internal/thintest TestContractRetryPreviewUnverifiedMerge
receipt: slow test 8.9s amadan.net/oficina/equipo/internal/thintest TestContractPreviewNotScheduled
receipt: slow test 4.84s amadan.net/oficina/equipo/internal/thintest TestContractPublishNotOffered
receipt: slow test 4.68s amadan.net/oficina/equipo/internal/thintest TestContractMacRecheckMergeAuthority
exit status 1
+ go test -tags testbuild -timeout 15m -skip '^Test([^C]|C[^o]|Co[^n]|Con[^t])|^TestContract(Assistant|Outcome|Team|Handoff|HostAllowlist|HostIsPerPerson|Look|Use[A-Z]|RemoteCall|LanesRunAtOnce|NoMergeQuestionWhenGateMerges|PreviewHeldUntilPublishAnswer|PreviewNotHeldBelow19|PublishNeedsOwnerAnswer)' -v -run '^TestContractWorkerTaintIsSticky$' -count=1 ./internal/thintest   (retry, once)
##############################################################################
FLAKE ./internal/thintest:TestContractWorkerTaintIsSticky thintest-contract 741408280bbe7236f43ba6f78c1dbd227775a537 45.34s 24.69
##############################################################################
failed, then passed on its one retry: the step stays green and the flake is on record
machine: 32 CPUs, load 24.69, cpu waiting 12.19%, memory waiting 0.00%, io waiting 0.09%
--- shard 8 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
test lane runner-thin: ./internal/runner/thin
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m ./internal/runner/thin
cache miss: amadan.net/oficina/equipo/internal/runner/thin: its inputs changed
budget note: internal/runner/thin took 5m11.774s, over the 45s its record on line 44 allows; reported only, timing fails on CI

receipt: test step 5m26.157s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 5m11.774s amadan.net/oficina/equipo/internal/runner/thin
receipt: slow test 37s amadan.net/oficina/equipo/internal/runner/thin TestModelsProbeAnsweredByAnotherModel
receipt: slow test 36.84s amadan.net/oficina/equipo/internal/runner/thin TestModelsEngineeringProbesThenRunsTheStrongest
receipt: slow test 36.8s amadan.net/oficina/equipo/internal/runner/thin TestModelsUnhealthyRetriedOnDemand
receipt: slow test 18.47s amadan.net/oficina/equipo/internal/runner/thin TestModelsProbeRunsInsideTheAdmission
receipt: slow test 9.85s amadan.net/oficina/equipo/internal/runner/thin TestTimeoutKeepsNothingForAnOlderInstance
machine: 32 CPUs, load 2.47, cpu waiting 0.84%, memory waiting 0.00%, io waiting 0.00%
--- shard 9 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
test lane runner-bug: ./internal/runner
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m -run '^TestDirectBugWorkflow$|^TestEnrolKeepsTheRole$' ./internal/runner
cache miss: amadan.net/oficina/equipo/internal/runner: its inputs changed

receipt: test step 51.337s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 50.15s amadan.net/oficina/equipo/internal/runner
receipt: slow test 30.12s amadan.net/oficina/equipo/internal/runner TestDirectBugWorkflow
receipt: slow test 20.02s amadan.net/oficina/equipo/internal/runner TestEnrolKeepsTheRole
machine: 32 CPUs, load 50.60, cpu waiting 33.05%, memory waiting 0.00%, io waiting 0.64%
--- shard 10 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
test lane runner-plans: ./internal/runner
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m -run '^TestPlanWorkflowCandidateOrder$|^TestPlanWorkflowFeature$|^TestCoordinatorRecoveryCallRefusalKeepsServing$|^TestCoordinatorRefusalMatrix$' ./internal/runner
cache miss: amadan.net/oficina/equipo/internal/runner: its inputs changed

receipt: test step 1m0.224s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 58.094s amadan.net/oficina/equipo/internal/runner
receipt: slow test 48.01s amadan.net/oficina/equipo/internal/runner TestPlanWorkflowCandidateOrder
receipt: slow test 46.43s amadan.net/oficina/equipo/internal/runner TestPlanWorkflowFeature
receipt: slow test 8.43s amadan.net/oficina/equipo/internal/runner TestCoordinatorRecoveryCallRefusalKeepsServing
receipt: slow test 1.62s amadan.net/oficina/equipo/internal/runner TestCoordinatorRefusalMatrix
machine: 32 CPUs, load 59.97, cpu waiting 36.60%, memory waiting 0.00%, io waiting 0.56%
--- shard 11 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
test lane runner-rest: ./internal/runner
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m -skip '^TestDirectBugWorkflow$|^TestEnrolKeepsTheRole$|^TestPlanWorkflowCandidateOrder$|^TestPlanWorkflowFeature$|^TestCoordinatorRecoveryCallRefusalKeepsServing$|^TestCoordinatorRefusalMatrix$' ./internal/runner
cache miss: amadan.net/oficina/equipo/internal/runner: its inputs changed

receipt: test step 36.468s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 35.438s amadan.net/oficina/equipo/internal/runner
receipt: slow test 5.13s amadan.net/oficina/equipo/internal/runner TestDirectFaultIsolation
receipt: slow test 3.38s amadan.net/oficina/equipo/internal/runner TestClaimRefusalsBackOff
receipt: slow test 3.13s amadan.net/oficina/equipo/internal/runner TestCoordinatorRecoveryRefusedKeepsServing
receipt: slow test 2.94s amadan.net/oficina/equipo/internal/runner TestToolVerbUnderFakeHarness
receipt: slow test 1.61s amadan.net/oficina/equipo/internal/runner TestCoordinatorTransientRefusalKeepsServing
machine: 32 CPUs, load 38.84, cpu waiting 21.11%, memory waiting 0.00%, io waiting 0.85%
--- shard 12 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
stagger: equipotest-a started 30s late; cpu waiting 39.6%, load 19.30
test lane equipotest-a: ./internal/equipotest
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m -run '^Test[A-D]|^TestQ' ./internal/equipotest

receipt: test step 1m8.559s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 1m6.433s amadan.net/oficina/equipo/internal/equipotest
receipt: slow test 27.92s amadan.net/oficina/equipo/internal/equipotest TestAuthorityCoreIntegration
receipt: slow test 27.85s amadan.net/oficina/equipo/internal/equipotest TestBootstrapNamesOwnersSetting
receipt: slow test 25.72s amadan.net/oficina/equipo/internal/equipotest TestAccountLabelMigration
receipt: slow test 22.91s amadan.net/oficina/equipo/internal/equipotest TestBudgetLoweringBelowUsage
receipt: slow test 22.88s amadan.net/oficina/equipo/internal/equipotest TestAuthoritySnapshotChanges
machine: 32 CPUs, load 55.13, cpu waiting 35.06%, memory waiting 0.00%, io waiting 0.29%
--- shard 13 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
stagger: equipotest-e started 30s late; cpu waiting 39.6%, load 19.30
test lane equipotest-e: ./internal/equipotest
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m -run '^Test[E-P]' ./internal/equipotest

receipt: test step 2m13.573s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 2m11.562s amadan.net/oficina/equipo/internal/equipotest
receipt: slow test 20.42s amadan.net/oficina/equipo/internal/equipotest TestProjectWritesRequireCurrentOwner
receipt: slow test 20.4s amadan.net/oficina/equipo/internal/equipotest TestProjectsFailuresRollBack
receipt: slow test 20.4s amadan.net/oficina/equipo/internal/equipotest TestProjectRetryAndRevision
receipt: slow test 20.39s amadan.net/oficina/equipo/internal/equipotest TestProjectRequestActorAndUpdate
receipt: slow test 20.38s amadan.net/oficina/equipo/internal/equipotest TestProjectsReopen
machine: 32 CPUs, load 24.69, cpu waiting 13.02%, memory waiting 0.00%, io waiting 0.09%
--- shard 14 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
stagger: equipotest-r started 30s late; cpu waiting 39.6%, load 19.30
test lane equipotest-r: ./internal/equipotest
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m -run '^TestR' ./internal/equipotest

receipt: test step 1m16.868s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 1m10.934s amadan.net/oficina/equipo/internal/equipotest
receipt: slow test 16.09s amadan.net/oficina/equipo/internal/equipotest TestReleaseStampContract
receipt: slow test 13.36s amadan.net/oficina/equipo/internal/equipotest TestRosterChangesAffectExistingSession
receipt: slow test 10.34s amadan.net/oficina/equipo/internal/equipotest TestRosterRemovalWhileAssigned
receipt: slow test 10.18s amadan.net/oficina/equipo/internal/equipotest TestRosterRemovalRollsBack
receipt: slow test 7.27s amadan.net/oficina/equipo/internal/equipotest TestRosterBootstrapOnce
machine: 32 CPUs, load 48.95, cpu waiting 30.17%, memory waiting 0.00%, io waiting 0.25%
--- shard 15 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
stagger: equipotest-rest started 30s late; cpu waiting 39.6%, load 19.30
test lane equipotest-rest: ./internal/equipotest
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m -skip '^Test[A-D]|^TestQ|^Test[E-P]|^TestR' ./internal/equipotest

receipt: test step 1m9.268s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 1m7.175s amadan.net/oficina/equipo/internal/equipotest
receipt: slow test 24.91s amadan.net/oficina/equipo/internal/equipotest TestSpecialistsSeedExistingTeam
receipt: slow test 24.88s amadan.net/oficina/equipo/internal/equipotest TestSigninNoProof
receipt: slow test 24.82s amadan.net/oficina/equipo/internal/equipotest TestSpecialistsSeedRollback
receipt: slow test 23.02s amadan.net/oficina/equipo/internal/equipotest TestSpecialistsUpgrade
receipt: slow test 22.97s amadan.net/oficina/equipo/internal/equipotest TestSpecialistSettingsRollbackAndUnavailable
machine: 32 CPUs, load 55.13, cpu waiting 34.01%, memory waiting 0.00%, io waiting 0.28%
--- shard 16 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
stagger: plan3test started 30s late; cpu waiting 39.6%, load 19.30
test lane plan3test: ./internal/plan3test
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m ./internal/plan3test
rastrillo: budget test: go test failed
--- FAIL amadan.net/oficina/equipo/internal/plan3test TestPlan3ReleaseBoundaries
=== RUN   TestPlan3ReleaseBoundaries
--- FAIL: TestPlan3ReleaseBoundaries (0.32s)

--- FAIL amadan.net/oficina/equipo/internal/plan3test TestPlan3ReleaseBoundaries/inventory
=== RUN   TestPlan3ReleaseBoundaries/inventory
    plan3_release_test.go:22: entry has no copy review status or applicable acceptance work.needs.mac_runner
--- FAIL: TestPlan3ReleaseBoundaries/inventory (0.02s)

--- FAIL amadan.net/oficina/equipo/internal/plan3test (package output)
FAIL
rastrillo-budget/v1 ran 53.631s
FAIL	amadan.net/oficina/equipo/internal/plan3test	54.140s


receipt: test step 55.976s against a 60s target (the gate's other steps are not in this figure)
receipt: 0 packages ran, 0 cached, 0 without tests, 1 failed
receipt: slow package 53.631s amadan.net/oficina/equipo/internal/plan3test
receipt: slow test 3.84s amadan.net/oficina/equipo/internal/plan3test TestPlan3Upgrade
receipt: slow test 3.5s amadan.net/oficina/equipo/internal/plan3test TestCoordinatorAcceptance3B
receipt: slow test 1.78s amadan.net/oficina/equipo/internal/plan3test TestConversationQuestionRace
receipt: slow test 1.56s amadan.net/oficina/equipo/internal/plan3test TestCoordinatorAcceptance3A
receipt: slow test 1.33s amadan.net/oficina/equipo/internal/plan3test TestCoordinatorMessageSourcesUpgrade
exit status 1
+ go test -tags testbuild -timeout 15m -v -run '^TestPlan3ReleaseBoundaries$/^inventory$' -count=1 ./internal/plan3test   (retry, once)
FAILED TWICE ./internal/plan3test:TestPlan3ReleaseBoundaries/inventory plan3test
=== RUN   TestPlan3ReleaseBoundaries
=== RUN   TestPlan3ReleaseBoundaries/inventory
    plan3_release_test.go:22: entry has no copy review status or applicable acceptance work.needs.mac_runner
--- FAIL: TestPlan3ReleaseBoundaries (0.02s)
    --- FAIL: TestPlan3ReleaseBoundaries/inventory (0.02s)
FAIL
rastrillo-budget/v1 ran 18ms
FAIL	amadan.net/oficina/equipo/internal/plan3test	0.218s
FAIL
machine: 32 CPUs, load 59.08, cpu waiting 37.10%, memory waiting 0.00%, io waiting 0.35%
make: *** [Makefile:113: ci-shard] Error 1

amadan: step check shard 16 of 29 failed: exit status 2
--- shard 17 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
stagger: rest started 30s late; cpu waiting 39.6%, load 19.30
test lane rest: ./cmd/equipo ./cmd/equipo-runner ./cmd/equipo-tool-proxy ./internal/advice ./internal/attach ./internal/attach/attachtest ./internal/chatmarkdown ./internal/chatsend ./internal/chatstream ./internal/coordinator ./internal/coordinatorcontract ./internal/coordinatormail ./internal/copydesk ./internal/diffscan ./internal/equipo ./internal/equipo/activity ./internal/equipo/assist ./internal/equipo/chat ./internal/equipo/conversation ./internal/equipo/conversation/chatstate ./internal/equipo/door ./internal/equipo/github ./internal/equipo/housekeeping ./internal/equipo/icons ./internal/equipo/identity ./internal/equipo/kernel ./internal/equipo/library ./internal/equipo/mergegate ./internal/equipo/notifications ./internal/equipo/oficina ./internal/equipo/oficina/oficinatest ./internal/equipo/oficinaid ./internal/equipo/ownermode ./internal/equipo/pause ./internal/equipo/personapi ./internal/equipo/planning ./internal/equipo/push ./internal/equipo/setup ./internal/equipo/team ./internal/equipo/teamcontract ./internal/equipo/triage ./internal/fakeclaude ./internal/fakecodex ./internal/fakeopencode ./internal/fakepi ./internal/idtest ./internal/ownermodetest ./internal/release ./internal/runner/checks ./internal/runner/connect ./internal/runner/containment ./internal/runner/containment/sysunix ./internal/runner/egress ./internal/runner/forge ./internal/runner/forge/forgetest ./internal/runner/heartbeat ./internal/runner/mac ./internal/runner/mcpresource ./internal/runner/metered ./internal/runner/planflow ./internal/runner/provider ./internal/runner/provider/claude ./internal/runner/provider/claude/realcli ./internal/runner/provider/codex ./internal/runner/provider/gotoolchain ./internal/runner/provider/opencode ./internal/runner/provider/pi ./internal/runner/setup ./internal/runner/transporttest ./internal/runner/webread ./internal/runner/workspace ./internal/runnerproto ./internal/schedule ./internal/sealbox ./internal/specialist ./internal/stagingtest ./internal/taskplan ./internal/testci ./internal/toolproxy ./internal/websource ./internal/wire ./internal/wire/forgekey ./internal/wire/wireschema ./internal/wire/wiretest ./tools/drive
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags testbuild -timeout 15m ./cmd/equipo ./cmd/equipo-runner ./cmd/equipo-tool-proxy ./internal/advice ./internal/attach ./internal/attach/attachtest ./internal/chatmarkdown ./internal/chatsend ./internal/chatstream ./internal/coordinator ./internal/coordinatorcontract ./internal/coordinatormail ./internal/copydesk ./internal/diffscan ./internal/equipo ./internal/equipo/activity ./internal/equipo/assist ./internal/equipo/chat ./internal/equipo/conversation ./internal/equipo/conversation/chatstate ./internal/equipo/door ./internal/equipo/github ./internal/equipo/housekeeping ./internal/equipo/icons ./internal/equipo/identity ./internal/equipo/kernel ./internal/equipo/library ./internal/equipo/mergegate ./internal/equipo/notifications ./internal/equipo/oficina ./internal/equipo/oficina/oficinatest ./internal/equipo/oficinaid ./internal/equipo/ownermode ./internal/equipo/pause ./internal/equipo/personapi ./internal/equipo/planning ./internal/equipo/push ./internal/equipo/setup ./internal/equipo/team ./internal/equipo/teamcontract ./internal/equipo/triage ./internal/fakeclaude ./internal/fakecodex ./internal/fakeopencode ./internal/fakepi ./internal/idtest ./internal/ownermodetest ./internal/release ./internal/runner/checks ./internal/runner/connect ./internal/runner/containment ./internal/runner/containment/sysunix ./internal/runner/egress ./internal/runner/forge ./internal/runner/forge/forgetest ./internal/runner/heartbeat ./internal/runner/mac ./internal/runner/mcpresource ./internal/runner/metered ./internal/runner/planflow ./internal/runner/provider ./internal/runner/provider/claude ./internal/runner/provider/claude/realcli ./internal/runner/provider/codex ./internal/runner/provider/gotoolchain ./internal/runner/provider/opencode ./internal/runner/provider/pi ./internal/runner/setup ./internal/runner/transporttest ./internal/runner/webread ./internal/runner/workspace ./internal/runnerproto ./internal/schedule ./internal/sealbox ./internal/specialist ./internal/stagingtest ./internal/taskplan ./internal/testci ./internal/toolproxy ./internal/websource ./internal/wire ./internal/wire/forgekey ./internal/wire/wireschema ./internal/wire/wiretest ./tools/drive
cache miss: amadan.net/oficina/equipo/internal/copydesk: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/equipo/team: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/forge: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/provider/claude/realcli: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/provider/opencode: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/webread: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runnerproto: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/workspace: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/checks: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/testci: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/wire/wireschema: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/containment: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/provider/pi: its inputs changed
--- FAIL amadan.net/oficina/equipo/internal/runner/webread TestTimeouts
=== RUN   TestTimeouts
    fetch_test.go:537: s1: {Source:s1 Origin:paul Parent: URL:https://shop.example.com/slow-body Hops:[{URL:https://shop.example.com/slow-body Address:151.101.1.1 Status:200}] Address:151.101.1.1 Status:200 Type:text/plain Bytes:5 SHA256:2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824 Millis:301 Reason: File:s001.txt}
--- FAIL: TestTimeouts (0.61s)

--- FAIL amadan.net/oficina/equipo/internal/runner/webread (package output)
FAIL
rastrillo-budget/v1 ran 1.374s
FAIL	amadan.net/oficina/equipo/internal/runner/webread	1.383s

budget note: internal/equipo took 2m23.8s, over the 10s the default allows; reported only, timing fails on CI
budget note: internal/equipo/chat took 23.579s, over the 10s the default allows; reported only, timing fails on CI
budget note: internal/equipo/github took 40.581s, over the 10s the default allows (measured on the run this cached result came from); reported only, timing fails on CI
budget note: internal/idtest took 1m51.424s, over the 10s the default allows; reported only, timing fails on CI
budget note: internal/release took 24.619s, over the 10s the default allows (measured on the run this cached result came from); reported only, timing fails on CI
budget note: internal/runner/containment took 48.042s, over the 15s its record on line 40 allows; reported only, timing fails on CI
budget note: internal/runner/provider/claude/realcli took 12.29s, over the 10s the default allows; reported only, timing fails on CI

receipt: test step 2m32.425s against a 60s target (the gate's other steps are not in this figure)
receipt: 22 packages ran, 46 cached, 16 without tests, 1 failed
receipt: slow package 2m23.8s amadan.net/oficina/equipo/internal/equipo
receipt: slow package 1m51.424s amadan.net/oficina/equipo/internal/idtest
receipt: slow package 1m6.032s amadan.net/oficina/equipo/internal/runner/provider/opencode
receipt: slow package 53.294s amadan.net/oficina/equipo/internal/runner/provider/pi
receipt: slow package 51.521s amadan.net/oficina/equipo/internal/runner/checks
receipt: slow test 54.57s amadan.net/oficina/equipo/internal/idtest TestDoorRemembersOficinaID
receipt: slow test 46.34s amadan.net/oficina/equipo/internal/idtest TestDoorForgetsOficinaIDForARefusedSession
receipt: slow test 46.13s amadan.net/oficina/equipo/internal/idtest TestDoorOficinaSettingsUnreadableIsNoLoop
receipt: slow test 45.87s amadan.net/oficina/equipo/internal/idtest TestDoorStepUpIsLocal
receipt: slow test 45.63s amadan.net/oficina/equipo/internal/idtest TestDoorNeverJudgesANativeSession
rastrillo: budget test: go test failed
exit status 1
+ go test -tags testbuild -timeout 15m -v -run '^TestTimeouts$' -count=1 ./internal/runner/webread   (retry, once)
##############################################################################
FLAKE ./internal/runner/webread:TestTimeouts rest 741408280bbe7236f43ba6f78c1dbd227775a537 0.61s 18.52
##############################################################################
failed, then passed on its one retry: the step stays green and the flake is on record
machine: 32 CPUs, load 18.52, cpu waiting 9.03%, memory waiting 0.00%, io waiting 0.06%
--- shard 18 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
browser: /opt/chromium-156.0.8078.79-1_deb13u1/chrome: Chromium 156.0.8078.79
browser lane browser-headless-chat: ./internal/headless
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags browser,testbuild -timeout 15m -run '^TestBrowserChat$|^TestBrowserChatSendStaysOnPage$|^TestBrowserComposer$|^TestBrowserComposerReconcile$|^TestBrowserComposerFocus$|^TestBrowserComposerDock$|^TestBrowserDraftStreamsFormatted$|^TestBrowserDraftIsTheMessage$' ./internal/headless

receipt: test step 1m26.409s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 1m24.606s amadan.net/oficina/equipo/internal/headless
receipt: slow test 38.89s amadan.net/oficina/equipo/internal/headless TestBrowserDraftIsTheMessage
receipt: slow test 14.71s amadan.net/oficina/equipo/internal/headless TestBrowserDraftStreamsFormatted
receipt: slow test 10.86s amadan.net/oficina/equipo/internal/headless TestBrowserChat
receipt: slow test 7.64s amadan.net/oficina/equipo/internal/headless TestBrowserComposer
receipt: slow test 6.89s amadan.net/oficina/equipo/internal/headless TestBrowserChatSendStaysOnPage
machine: 32 CPUs, load 59.08, cpu waiting 37.10%, memory waiting 0.00%, io waiting 0.35%
--- shard 19 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
browser: /opt/chromium-156.0.8078.79-1_deb13u1/chrome: Chromium 156.0.8078.79
browser lane browser-headless-work: ./internal/headless
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags browser,testbuild -timeout 15m -run '^TestBrowserTaskCard$|^TestBrowserReceiptFollowsReview$|^TestBrowserRailFollowsWork$|^TestBrowserTaskThread$|^TestBrowserAskAfterMerge$|^TestBrowserReceiptsDesktop$|^TestBrowserReceiptsTouch$' ./internal/headless

receipt: test step 1m31.546s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 1m29.731s amadan.net/oficina/equipo/internal/headless
receipt: slow test 28.19s amadan.net/oficina/equipo/internal/headless TestBrowserRailFollowsWork
receipt: slow test 21.21s amadan.net/oficina/equipo/internal/headless TestBrowserTaskThread
receipt: slow test 13.13s amadan.net/oficina/equipo/internal/headless TestBrowserReceiptFollowsReview
receipt: slow test 9.44s amadan.net/oficina/equipo/internal/headless TestBrowserAskAfterMerge
receipt: slow test 8.86s amadan.net/oficina/equipo/internal/headless TestBrowserTaskCard
machine: 32 CPUs, load 58.27, cpu waiting 36.45%, memory waiting 0.00%, io waiting 0.32%
--- shard 20 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
browser: /opt/chromium-156.0.8078.79-1_deb13u1/chrome: Chromium 156.0.8078.79
browser lane browser-headless-connections: ./internal/headless
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags browser,testbuild -timeout 15m -run '^TestBrowserConnections|^TestBrowserPasteBox$|^TestBrowserPasteCopiesItsBox$' ./internal/headless

receipt: test step 1m54.231s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 1m52.419s amadan.net/oficina/equipo/internal/headless
receipt: slow test 15.26s amadan.net/oficina/equipo/internal/headless TestBrowserConnectionsConversation
receipt: slow test 13.26s amadan.net/oficina/equipo/internal/headless TestBrowserConnectionsAddPage
receipt: slow test 12.52s amadan.net/oficina/equipo/internal/headless TestBrowserConnectionsAdd
receipt: slow test 11.52s amadan.net/oficina/equipo/internal/headless TestBrowserConnectionsMeteredLimitRequired
receipt: slow test 11.29s amadan.net/oficina/equipo/internal/headless TestBrowserConnectionsSignInEmail
machine: 32 CPUs, load 46.07, cpu waiting 27.49%, memory waiting 0.00%, io waiting 0.22%
--- shard 21 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
browser: /opt/chromium-156.0.8078.79-1_deb13u1/chrome: Chromium 156.0.8078.79
browser lane browser-headless-rest: ./internal/headless
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags browser,testbuild -timeout 15m -run '^(TestBrowserAskAfterMerge|TestBrowserCardAnswerSettlesAtBottom|TestBrowserChat|TestBrowserChatSendStaysOnPage|TestBrowserComposer|TestBrowserComposerDock|TestBrowserComposerFocus|TestBrowserComposerReconcile|TestBrowserConnectionsAdd|TestBrowserConnectionsAddPage|TestBrowserConnectionsConversation|TestBrowserConnectionsCopyLink|TestBrowserConnectionsEndedNote|TestBrowserConnectionsMeteredLimitRequired|TestBrowserConnectionsOpenCodeGoLimitRequired|TestBrowserConnectionsSignIn|TestBrowserConnectionsSignInEmail|TestBrowserConnectionsSignInSwitch|TestBrowserConnectionsToken|TestBrowserCopyContinue|TestBrowserCopySettingAndFlag|TestBrowserDraftIsTheMessage|TestBrowserDraftStreamsFormatted|TestBrowserEmptyExplore|TestBrowserMoveIn|TestBrowserNotebook|TestBrowserNotebookLook|TestBrowserPasteBox|TestBrowserPasteBoxLook|TestBrowserPasteCopiesItsBox|TestBrowserRailFollowsWork|TestBrowserReceiptFollowsReview|TestBrowserReceiptsDesktop|TestBrowserReceiptsTouch|TestBrowserRefreshRace|TestBrowserStalePageReloads|TestBrowserTaskCard|TestBrowserTaskThread|TestBrowserThinkingAndCards|TestBrowserUsageAndAdvice|TestBrowserWaitingTurns|TestNotebookScreenshots)$' -skip '^TestBrowserChat$|^TestBrowserChatSendStaysOnPage$|^TestBrowserComposer$|^TestBrowserComposerReconcile$|^TestBrowserComposerFocus$|^TestBrowserComposerDock$|^TestBrowserDraftStreamsFormatted$|^TestBrowserDraftIsTheMessage$|^TestBrowserTaskCard$|^TestBrowserReceiptFollowsReview$|^TestBrowserRailFollowsWork$|^TestBrowserTaskThread$|^TestBrowserAskAfterMerge$|^TestBrowserReceiptsDesktop$|^TestBrowserReceiptsTouch$|^TestBrowserConnections|^TestBrowserPasteBox$|^TestBrowserPasteCopiesItsBox$' ./internal/headless
rastrillo: budget test: go test failed
--- FAIL amadan.net/oficina/equipo/internal/headless TestBrowserCopyContinue
=== RUN   TestBrowserCopyContinue
time=2026-11-28T17:49:45.180Z level=INFO msg="startup phase" phase=state_lock
time=2026-11-28T17:49:45.181Z level=INFO msg="startup phase done" phase=state_lock took=298µs
time=2026-11-28T17:49:45.181Z level=INFO msg="startup phase" phase=claim_roots
time=2026-11-28T17:49:45.181Z level=INFO msg="startup phase done" phase=claim_roots took=185µs
time=2026-11-28T17:49:45.181Z level=INFO msg="startup phase" phase=sweep
time=2026-11-28T17:49:45.220Z level=INFO msg="startup phase done" phase=sweep took=38.868ms
time=2026-11-28T17:49:45.220Z level=INFO msg="startup phase" phase=credentials
time=2026-11-28T17:49:45.220Z level=INFO msg="startup phase done" phase=credentials took=138µs
time=2026-11-28T17:49:45.220Z level=INFO msg="startup phase" phase=open_state
time=2026-11-28T17:49:45.271Z level=INFO msg="startup phase done" phase=open_state took=50.814ms
time=2026-11-28T17:49:45.272Z level=WARN msg="no seal key: token connections cannot be added" err=*fs.PathError
time=2026-11-28T17:49:45.274Z level=INFO msg=connecting host=127.0.0.1:42415 protocol=35
time=2026-11-28T17:49:45.275Z level=INFO msg=connected host=127.0.0.1:42415 took=911µs
time=2026-11-28T17:49:45.275Z level=INFO msg="capabilities gathering"
time=2026-11-28T17:49:45.276Z level=INFO msg="capabilities gathered" took=489µs tags=linux,claude,go
time=2026-11-28T17:49:45.278Z level=INFO msg="hello sent" protocol=35
time=2026-11-28T17:49:45.285Z level=INFO msg=welcome protocol=35 role=primary generation=1
    browser_copy_test.go:90: waiting for !document.querySelector('[data-copy-continue]'): context deadline exceeded (last evaluation: context deadline exceeded)
--- FAIL: TestBrowserCopyContinue (6.34s)

--- FAIL amadan.net/oficina/equipo/internal/headless (package output)
FAIL
rastrillo-budget/v1 ran 1m39.417s
FAIL	amadan.net/oficina/equipo/internal/headless	99.625s


receipt: test step 1m41.074s against a 60s target (the gate's other steps are not in this figure)
receipt: 0 packages ran, 0 cached, 0 without tests, 1 failed
receipt: slow package 1m39.417s amadan.net/oficina/equipo/internal/headless
receipt: slow test 14.99s amadan.net/oficina/equipo/internal/headless TestBrowserThinkingAndCards
receipt: slow test 13.08s amadan.net/oficina/equipo/internal/headless TestBrowserWaitingTurns
receipt: slow test 10.37s amadan.net/oficina/equipo/internal/headless TestBrowserStalePageReloads
receipt: slow test 9.3s amadan.net/oficina/equipo/internal/headless TestBrowserMoveIn
receipt: slow test 7.64s amadan.net/oficina/equipo/internal/headless TestBrowserRefreshRace
exit status 1
+ go test -tags browser,testbuild -timeout 15m -run '^(TestBrowserAskAfterMerge|TestBrowserCardAnswerSettlesAtBottom|TestBrowserChat|TestBrowserChatSendStaysOnPage|TestBrowserComposer|TestBrowserComposerDock|TestBrowserComposerFocus|TestBrowserComposerReconcile|TestBrowserConnectionsAdd|TestBrowserConnectionsAddPage|TestBrowserConnectionsConversation|TestBrowserConnectionsCopyLink|TestBrowserConnectionsEndedNote|TestBrowserConnectionsMeteredLimitRequired|TestBrowserConnectionsOpenCodeGoLimitRequired|TestBrowserConnectionsSignIn|TestBrowserConnectionsSignInEmail|TestBrowserConnectionsSignInSwitch|TestBrowserConnectionsToken|TestBrowserCopyContinue|TestBrowserCopySettingAndFlag|TestBrowserDraftIsTheMessage|TestBrowserDraftStreamsFormatted|TestBrowserEmptyExplore|TestBrowserMoveIn|TestBrowserNotebook|TestBrowserNotebookLook|TestBrowserPasteBox|TestBrowserPasteBoxLook|TestBrowserPasteCopiesItsBox|TestBrowserRailFollowsWork|TestBrowserReceiptFollowsReview|TestBrowserReceiptsDesktop|TestBrowserReceiptsTouch|TestBrowserRefreshRace|TestBrowserStalePageReloads|TestBrowserTaskCard|TestBrowserTaskThread|TestBrowserThinkingAndCards|TestBrowserUsageAndAdvice|TestBrowserWaitingTurns|TestNotebookScreenshots)$' -skip '^TestBrowserChat$|^TestBrowserChatSendStaysOnPage$|^TestBrowserComposer$|^TestBrowserComposerReconcile$|^TestBrowserComposerFocus$|^TestBrowserComposerDock$|^TestBrowserDraftStreamsFormatted$|^TestBrowserDraftIsTheMessage$|^TestBrowserTaskCard$|^TestBrowserReceiptFollowsReview$|^TestBrowserRailFollowsWork$|^TestBrowserTaskThread$|^TestBrowserAskAfterMerge$|^TestBrowserReceiptsDesktop$|^TestBrowserReceiptsTouch$|^TestBrowserConnections|^TestBrowserPasteBox$|^TestBrowserPasteCopiesItsBox$' -v -run '^TestBrowserCopyContinue$' -count=1 ./internal/headless   (retry, once)
##############################################################################
FLAKE ./internal/headless:TestBrowserCopyContinue browser-headless-rest 741408280bbe7236f43ba6f78c1dbd227775a537 6.34s 51.99
##############################################################################
failed, then passed on its one retry: the step stays green and the flake is on record
machine: 32 CPUs, load 51.99, cpu waiting 31.12%, memory waiting 0.00%, io waiting 0.25%
--- shard 22 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
timing budgets: reported, not enforced: a shared runner's load is not this change's time (set EQUIPO_CI_DEDICATED=1 on a dedicated runner)
browser: /opt/chromium-156.0.8078.79-1_deb13u1/chrome: Chromium 156.0.8078.79
browser lane browser-rest: ./internal/equipo
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags browser,testbuild -timeout 15m -run '^(TestBrowserPreviewBlocksNavigation|TestBrowserPreviewPassExchange)$' ./internal/equipo

receipt: test step 4.4s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 2.583s amadan.net/oficina/equipo/internal/equipo
receipt: slow test 1.94s amadan.net/oficina/equipo/internal/equipo TestBrowserPreviewPassExchange
receipt: slow test 640ms amadan.net/oficina/equipo/internal/equipo TestBrowserPreviewBlocksNavigation
browser lane browser-rest: ./internal/equipotest
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags browser,testbuild -timeout 15m -run '^(TestBrowserGitHubManifestCSP)$' ./internal/equipotest

receipt: test step 7.878s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 6.298s amadan.net/oficina/equipo/internal/equipotest
receipt: slow test 6.3s amadan.net/oficina/equipo/internal/equipotest TestBrowserGitHubManifestCSP
browser lane browser-rest: ./internal/idtest
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags browser,testbuild -timeout 15m -run '^(TestBrowserOficinaIDDoor|TestBrowserSmartDoor)$' ./internal/idtest
budget note: internal/idtest took 10.498s, over the 10s the default allows; reported only, timing fails on CI

receipt: test step 12.071s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 10.498s amadan.net/oficina/equipo/internal/idtest
receipt: slow test 8.31s amadan.net/oficina/equipo/internal/idtest TestBrowserSmartDoor
receipt: slow test 2.18s amadan.net/oficina/equipo/internal/idtest TestBrowserOficinaIDDoor
browser lane browser-rest: ./internal/plan3test
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags browser,testbuild -timeout 15m -run '^(TestTeamsHierarchyBrowser)$' ./internal/plan3test

receipt: test step 3.959s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 2.192s amadan.net/oficina/equipo/internal/plan3test
receipt: slow test 2.19s amadan.net/oficina/equipo/internal/plan3test TestTeamsHierarchyBrowser
browser lane browser-rest: ./internal/thintest
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -tags browser,testbuild -timeout 15m -run '^(TestBrowserAccessEmojiByline|TestBrowserAccessFinalOutcomes|TestBrowserAccessRequest|TestBrowserAccessReview|TestBrowserActivitySubjects|TestBrowserAutonomySettings|TestBrowserCoordinatorQueue|TestBrowserEmptyConversation|TestBrowserEndedNoteStaysGone|TestBrowserHousekeeping|TestBrowserInnerGallery|TestBrowserInnerScreens|TestBrowserInstantThinking|TestBrowserInstantThinkingQueued|TestBrowserMachines|TestBrowserPausedWork|TestBrowserPhoneIndex|TestBrowserPlacementQuestionAndPending|TestBrowserProjectPlacement|TestBrowserProjectsList|TestBrowserReportActionFeedback|TestBrowserReportNextSteps|TestBrowserReportThread|TestBrowserRhythm|TestBrowserRollup|TestBrowserRosterAlignment|TestBrowserRosterDecisionStates|TestBrowserRosterQuietDay|TestBrowserRosterReports|TestBrowserRosterSetAside|TestBrowserRosterSubchat|TestBrowserRosterThinking|TestBrowserRosterVisual|TestBrowserSettingsHousekeepingGroups|TestBrowserSettingsMenu|TestBrowserSettingsRail|TestBrowserSettingsSaveBar|TestBrowserSettingsShots|TestBrowserSettingsStayOnPage|TestBrowserSettingsTeams|TestBrowserShipsButtons|TestBrowserSpecialistRows|TestBrowserSpendFollowsAnswers|TestBrowserTaskRows|TestBrowserTeamPanel|TestBrowserThinkingCycles|TestBrowserThinkingLinesClear|TestBrowserThinkingSteady|TestBrowserThinkingWords|TestBrowserTokenRowEmail|TestBrowserTrackPulse|TestBrowserTrackStarCentre|TestBrowserTryAgain)$' ./internal/thintest

receipt: test step 3m35.714s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 3m33.16s amadan.net/oficina/equipo/internal/thintest
receipt: slow test 26.19s amadan.net/oficina/equipo/internal/thintest TestBrowserAccessRequest
receipt: slow test 14.4s amadan.net/oficina/equipo/internal/thintest TestBrowserSettingsTeams
receipt: slow test 12.08s amadan.net/oficina/equipo/internal/thintest TestBrowserThinkingCycles
receipt: slow test 10.72s amadan.net/oficina/equipo/internal/thintest TestBrowserPlacementQuestionAndPending
receipt: slow test 9.23s amadan.net/oficina/equipo/internal/thintest TestBrowserRhythm
machine: 32 CPUs, load 6.96, cpu waiting 3.21%, memory waiting 0.00%, io waiting 0.01%
--- shard 23 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
shard 23: make test-quarantine
python3 scripts/ci-test.py quarantine
quarantine: 12 tests from scripts/ci-quarantine.txt; a failure is retried once, and a pass on the retry is reported as a flake
+ go test -tags testbuild -timeout 15m -v -run '^TestHeadlessConnections$/^A5_cancel_and_sign_out$|^TestHeadlessConnections$/^C4_claude_sign_in$|^TestHeadlessConnections$/^C5_engineering_failover$|^TestHeadlessConnections$/^C5_engineering_to_codex$|^TestHeadlessConnections$/^C5_engineering_waits$' ./internal/headless   (53s)
ok ./internal/headless TestHeadlessConnections/A5_cancel_and_sign_out 4.89s
ok ./internal/headless TestHeadlessConnections/C4_claude_sign_in 1.37s
ok ./internal/headless TestHeadlessConnections/C5_engineering_failover 8.20s
ok ./internal/headless TestHeadlessConnections/C5_engineering_to_codex 9.20s
ok ./internal/headless TestHeadlessConnections/C5_engineering_waits 27.03s
+ go test -tags testbuild -timeout 15m -v -run '^TestHeadlessConnections$/^C5_review_auth$|^TestHeadlessConnections$/^C5_review_failover$|^TestHeadlessConnections$/^C5_review_on_codex$|^TestHeadlessConnections$/^C5_review_other_family_first$' ./internal/headless   (57s)
ok ./internal/headless TestHeadlessConnections/C5_review_auth 13.72s
ok ./internal/headless TestHeadlessConnections/C5_review_failover 11.51s
ok ./internal/headless TestHeadlessConnections/C5_review_on_codex 10.51s
ok ./internal/headless TestHeadlessConnections/C5_review_other_family_first 19.03s
+ go test -tags testbuild -timeout 15m -v -run '^TestMixedVersions$' ./internal/headless   (21s)
ok ./internal/headless TestMixedVersions 19.22s
+ go test -tags testbuild -timeout 15m -v -run '^TestCheckSandboxDeniedPathsTampering$' ./internal/runner/checks   (2s)
ok ./internal/runner/checks TestCheckSandboxDeniedPathsTampering 0.80s
+ go test -tags testbuild -timeout 15m -v -run '^TestRunnerCancelAndSupersede$' ./internal/runner/thin   (1s)
ok ./internal/runner/thin TestRunnerCancelAndSupersede 0.05s
quarantine: 0 flaked (passed on the retry), 0 failed
machine: 32 CPUs, load 59.97, cpu waiting 36.18%, memory waiting 0.00%, io waiting 0.58%
--- shard 24 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
shard 24: make runner-host
python3 scripts/runner-prerequisites.py
CGO_ENABLED=0 RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py retried runner-host -run 'TestDirect|TestProvider|TestCheckSandbox' -count=1 ./internal/runner/provider/... ./internal/runner/checks
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -no-time -run 'TestDirect|TestProvider|TestCheckSandbox' -count=1 ./internal/runner/provider/... ./internal/runner/checks

receipt: test step 12.126s against a 60s target (the gate's other steps are not in this figure)
receipt: 4 packages ran, 0 cached, 4 without tests, 0 failed
receipt: slow package 7.596s amadan.net/oficina/equipo/internal/runner/checks
receipt: slow package 234ms amadan.net/oficina/equipo/internal/runner/provider/claude
receipt: slow package 90ms amadan.net/oficina/equipo/internal/runner/provider/codex
receipt: slow package 2ms amadan.net/oficina/equipo/internal/runner/provider
receipt: slow package 0s amadan.net/oficina/equipo/internal/runner/provider/claude/realcli
receipt: slow test 5.44s amadan.net/oficina/equipo/internal/runner/checks TestCheckSandboxDeniedPathsGoFixture
receipt: slow test 1.74s amadan.net/oficina/equipo/internal/runner/checks TestCheckSandboxDeniedPaths
receipt: slow test 320ms amadan.net/oficina/equipo/internal/runner/checks TestCheckSandboxDeniedPathsCache
receipt: slow test 230ms amadan.net/oficina/equipo/internal/runner/provider/claude TestDirectJournalAdapterBarrier
receipt: slow test 90ms amadan.net/oficina/equipo/internal/runner/provider/codex TestDirectJournalAdapterBarrier
CGO_ENABLED=0 RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py retried runner-host -run '^TestNamespace' -count=1 ./internal/runner/containment
+ go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget test -no-time -run '^TestNamespace' -count=1 ./internal/runner/containment

receipt: test step 3.264s against a 60s target (the gate's other steps are not in this figure)
receipt: 1 packages ran, 0 cached, 0 without tests, 0 failed
receipt: slow package 2.897s amadan.net/oficina/equipo/internal/runner/containment
receipt: slow test 270ms amadan.net/oficina/equipo/internal/runner/containment TestNamespaceReadOnlyScratch
receipt: slow test 180ms amadan.net/oficina/equipo/internal/runner/containment TestNamespaceRecoveryUnavailableProof
receipt: slow test 120ms amadan.net/oficina/equipo/internal/runner/containment TestNamespaceDirectPolicyAdmission
receipt: slow test 110ms amadan.net/oficina/equipo/internal/runner/containment TestNamespaceReapsOrphans
receipt: slow test 110ms amadan.net/oficina/equipo/internal/runner/containment TestNamespaceDirectPolicy
machine: 32 CPUs, load 12.23, cpu waiting 8.67%, memory waiting 0.00%, io waiting 1.18%
--- shard 25 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
stagger: runner-dead-references started 30s late; cpu waiting 39.6%, load 19.30
shard 25: make runner-dead-references lanes-check build vet fmt-check spacing budget migration-check
python3 scripts/runner-dead-references.py
reference scan: 2997 text files, 3229 matches, 0 failures
python3 native/scripts/check-share.py
Share packaging, keychain-only boundary and reviewed copy verified
python3 scripts/ci-test.py check
lanes: 18 lanes and 5 browser lanes run every test once; 20-check@29
CGO_ENABLED=0 go build ./...
CGO_ENABLED=0 GOOS=darwin GOARCH=arm64 go build -o /dev/null ./cmd/equipo-runner
go vet ./...
go vet -tags testbuild ./internal/runner/thin ./internal/headless
GOOS=darwin GOARCH=arm64 go vet ./cmd/equipo-runner/... ./internal/runner/... ./internal/wire/... ./internal/release/...
go tool fiesta spacing -skip tokens.css internal/equipo/static
go run amadan.net/rastrillo/rastrillo/cmd/rastrillo budget size
budget size: 94 directories within budget
CGO_ENABLED=0 go test ./internal/equipo -run '^TestMigrationModels$' -count=1
ok  	amadan.net/oficina/equipo/internal/equipo	2.522s
machine: 32 CPUs, load 61.96, cpu waiting 37.09%, memory waiting 0.00%, io waiting 0.46%
--- shard 26 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
stagger: staticcheck started 30s late; cpu waiting 39.6%, load 19.30
shard 26: make staticcheck
go run honnef.co/go/tools/cmd/staticcheck@v0.7.0 -tags browser,perf,testbuild ./...
machine: 32 CPUs, load 50.60, cpu waiting 30.57%, memory waiting 0.00%, io waiting 0.69%
--- shard 27 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
stagger: govulncheck started 30s late; cpu waiting 39.6%, load 19.30
shard 27: make govulncheck
go run golang.org/x/vuln/cmd/govulncheck@v1.8.0 ./...
=== Symbol Results ===

No vulnerabilities found.

Your code is affected by 0 vulnerabilities.
This scan also found 1 vulnerability in packages you import and 10
vulnerabilities in modules you require, but your code doesn't appear to call
these vulnerabilities.
Use '-show verbose' for more details.
machine: 32 CPUs, load 57.44, cpu waiting 34.22%, memory waiting 0.00%, io waiting 0.62%
--- shard 28 of 29 ---
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py shard
stagger: gitleaks started 30s late; cpu waiting 39.6%, load 19.30
shard 28: make gitleaks
5:49PM INF Unknown SCM platform. Use --platform to include links in findings. host=amadan.net
5:49PM INF 1266 commits scanned.
5:49PM INF scanned ~68813978 bytes (68.81 MB) in 23.4s
5:49PM INF no leaks found
machine: 32 CPUs, load 57.44, cpu waiting 33.05%, memory waiting 0.00%, io waiting 0.64%

amadan: job failed at step check shard 16 of 29 — its output is above, not at the tail of this log
diff --git a/.rastrillo/budgets.txt b/.rastrillo/budgets.txt
index ea637566..b7f4378d 100644
--- a/.rastrillo/budgets.txt
+++ b/.rastrillo/budgets.txt
@@ -56,7 +56,7 @@ perf GET /api/v1/tasks/{id} skip Thin v1 person API: bearer-only JSON for device
perf GET /api/v1/assistant/snapshot skip Assistant person API: bearer-only JSON for Base's chat, not a browser screen.
perf GET /api/v1/assistant/messages skip Assistant person API: bearer-only JSON for Base's chat, not a browser screen.
perf GET /api/v1/assistant/events skip Assistant event stream (Server-Sent Events), bearer-only and long-lived; not a screen.
-size internal/equipo/chat 38074 11915 File facts/diffs, previews, merge authority, unfinished work, CI feedback, notification receipts, Assistant files, places and where their cards land, waiting cards, Mac waits; measured 38074/11915.
+size internal/equipo/chat 38116 11998 File facts/diffs, previews, merge authority, unfinished work, CI feedback, notification receipts, Assistant files, places and where their cards land, waiting cards, Mac waits; measured 38116/11998.
perf GET /api/v1/questions/{id} skip Thin v1 person API: bearer-only JSON for devices; the browser reads questions on /tasks/{id}.
perf GET /api/v1/steps/{id}/log skip Thin v1 person API: bearer-only JSON for devices; the browser shows the log tail on /tasks/{id}.
perf GET /api/v1/connections/preference skip Connections slice 1 person API: bearer-only JSON for devices; the browser shows the preference on /conversation/connections.
@@ -70,8 +70,8 @@ perf GET /api/v1/tasks/{id}/files/{file} skip Research kept images: bearer-only
perf GET /tasks/{id}/files/{file} skip Research kept images: the bytes of one image, shown on the task page; a file, not a screen.
perf GET /api/v1/runners skip Mac runners person API: bearer-only JSON for devices; the browser shows runners in the Team section.
time cmd/equipo-runner 60s TestReleaseRunnerHasNoFakeWorker builds the release runner and the thin package under testbuild (about 12s locally).
-size internal/headless - 11969 Grant scenarios (#48); sign-in email at 1280 and 390; Assistant files end to end; the restart wait; the live site waits for a place; a card answer settles at the bottom; measured 11969 test lines.
-size internal/thintest - 37101 Protocol 31 contracts, 35 diffs, stuck tasks, no-access merges, held retries, unfinished work, free rounds, previews, Assistant files, places and where their cards land, Mac waits; measured 37101.
+size internal/headless - 11977 Grant scenarios (#48); sign-in email at 1280 and 390; Assistant files end to end; the restart wait; the live site waits for a place; a card answer settles at the bottom; measured 11977 test lines.
+size internal/thintest - 37223 Protocol 31 contracts, 35 diffs, stuck tasks, no-access merges, held retries, unfinished work, free rounds, previews, Assistant files, places and where their cards land, Mac waits; measured 37223.
perf GET /api/v1/projects/{id}/merge-policy skip Merge authority person API: bearer-only JSON for devices; the browser reads the policy on /projects/{id}.
perf GET /api/v1/usage skip Thin v1 person API: bearer-only JSON for devices; the browser reads usage through /usage.
diff --git a/internal/equipo/chat/explore.go b/internal/equipo/chat/explore.go
index 6a99c3dd..17cf7177 100644
--- a/internal/equipo/chat/explore.go
+++ b/internal/equipo/chat/explore.go
@@ -48,6 +48,11 @@ func (p progress) needsExplore(k taskRecord) string {
return wire.NeedsReviewBlocked
case w.State == wire.StepFailed && w.Terminated:
return wire.NeedsRetry
+ case w.State == wire.StepQueued && w.Placement == wire.PlacementMac:
+ // Waiting for a Mac, as any task (needsYou).
+ return wire.NeedsMacRunner
+ case w.State == wire.StepQueued && w.Placement == wire.PlacementMacEngineering:
+ return wire.NeedsMacEngineering
case w.State != wire.StepDone || p.candidate == "":
return ""
}
diff --git a/internal/equipo/chat/mac_needs_test.go b/internal/equipo/chat/mac_needs_test.go
new file mode 100644
index 00000000..261a123f
--- /dev/null
+++ b/internal/equipo/chat/mac_needs_test.go
@@ -0,0 +1,83 @@
+package chat
+
+import (
+ "context"
+ "io"
+ "log/slog"
+ "os"
+ "path/filepath"
+ "strings"
+ "testing"
+ "time"
+
+ "amadan.net/oficina/equipo/internal/wire"
+ "amadan.net/rastrillo/rastrillo/db"
+ "gorm.io/gorm"
+)
+
+// Checks need a Mac when any Engineering round of the task touched Apple
+// files, not only the round whose commit is the candidate: a delegated
+// Copy commit, or a later fix round that touched only the README, makes
+// a new candidate that still holds the Swift changes (Astra,
+// mac-placement-wait).
+func TestChecksNeedAMacForEveryAppleRound(t *testing.T) {
+ src, err := hkTemplatePath()
+ if err != nil {
+ t.Fatal(err)
+ }
+ raw, err := os.ReadFile(src)
+ if err != nil {
+ t.Fatal(err)
+ }
+ path := filepath.Join(t.TempDir(), "macneeds.db")
+ if err := os.WriteFile(path, raw, 0o600); err != nil {
+ t.Fatal(err)
+ }
+ d, err := db.Open(path, slog.New(slog.NewTextHandler(io.Discard, nil)))
+ if err != nil {
+ t.Fatal(err)
+ }
+ t.Cleanup(func() { _ = d.Close() })
+ s := NewStore(d, Authority{Copy: func(key string) string { return key }, PrimaryRunner: func(*gorm.DB, string) (string, error) { return "", nil }}, nil)
+ const person = "owner@example.com"
+ now := time.Now().UTC()
+ sha := func(c string) string { return strings.Repeat(c, 40) }
+ if err := d.G.Create(&projectRecord{ID: "p1", Repo: "oficina/sample"}).Error; err != nil {
+ t.Fatal(err)
+ }
+ for _, k := range []taskRecord{{ID: "tk1", ProjectID: "p1", Creator: person, Stage: wire.StageInProgress, Revision: 1, CreatedAt: now, UpdatedAt: now}, {ID: "tk2", ProjectID: "p1", Creator: person, Stage: wire.StageInProgress, Revision: 1, CreatedAt: now, UpdatedAt: now}} {
+ if err := d.G.Create(&k).Error; err != nil {
+ t.Fatal(err)
+ }
+ }
+ for _, st := range []stepRecord{
+ {ID: "e1", TaskID: "tk1", Idx: 1, Specialist: wire.SpecialistEngineering, Person: person, State: wire.StepDone, Round: 1, CandidateSHA: sha("a"), Apple: true},
+ {ID: "c1", TaskID: "tk1", Idx: 2, Specialist: wire.SpecialistCopy, Person: person, State: wire.StepDone, Round: 1, CandidateSHA: sha("b")},
+ {ID: "e2", TaskID: "tk1", Idx: 3, Specialist: wire.SpecialistEngineering, Person: person, State: wire.StepDone, Round: 2, CandidateSHA: sha("c")},
+ {ID: "e3", TaskID: "tk2", Idx: 1, Specialist: wire.SpecialistEngineering, Person: person, State: wire.StepDone, Round: 1, CandidateSHA: sha("d")},
+ } {
+ if err := d.G.Create(&st).Error; err != nil {
+ t.Fatal(err)
+ }
+ }
+ for _, c := range []struct {
+ task, candidate string
+ mac bool
+ }{{"tk1", sha("a"), true}, {"tk1", sha("b"), true}, {"tk1", sha("c"), true}, {"tk2", sha("d"), false}} {
+ var needs []string
+ err := s.tx(context.Background(), func(t *txn) error {
+ k, err := t.loadTask(c.task)
+ if err != nil {
+ return err
+ }
+ needs, err = t.checksNeeds(k, stepRecord{TaskID: c.task, Specialist: wire.SpecialistChecks, Person: person, CandidateSHA: c.candidate})
+ return err
+ })
+ if err != nil {
+ t.Fatal(err)
+ }
+ if got := strings.Join(needs, ","); (got == "macos,xcode") != c.mac {
+ t.Errorf("%s at %s: needs %q", c.task, c.candidate[:1], got)
+ }
+ }
+}
diff --git a/internal/equipo/chat/runners.go b/internal/equipo/chat/runners.go
index f22210aa..3a536fbc 100644
--- a/internal/equipo/chat/runners.go
+++ b/internal/equipo/chat/runners.go
@@ -375,18 +375,20 @@ const OfflineLimit = 30 * time.Minute
// checksNeeds are the tags checks of the task's newest candidate need:
// macOS and Xcode when the change touched Apple files or the
// repository's gate needs Xcode (the primary's index says so), and the
-// iOS simulator when the repository has a shared scheme.
+// iOS simulator when the repository has a shared scheme. The change is
+// every Engineering round of the task, not only the one whose commit is
+// the candidate: a later round, or a delegated Copy commit, makes a new
+// candidate that still holds an earlier round's Apple files.
func (t *txn) checksNeeds(k taskRecord, s stepRecord) ([]string, error) {
- var eng stepRecord
- err := t.db.Where("task_id = ? AND specialist = ? AND candidate_sha = ?", k.ID, wire.SpecialistEngineering, s.CandidateSHA).Order("idx DESC").First(&eng).Error
- if err != nil && !errors.Is(err, gorm.ErrRecordNotFound) {
+ var apple int64
+ if err := t.db.Model(&stepRecord{}).Where("task_id = ? AND specialist = ? AND apple = ?", k.ID, wire.SpecialistEngineering, true).Count(&apple).Error; err != nil {
return nil, err
}
info, err := t.repoInfo(k, s.Person)
if err != nil {
return nil, err
}
- return macNeeds(eng.Apple || info.NeedsMacOS, info), nil
+ return macNeeds(apple > 0 || info.NeedsMacOS, info), nil
}
// engineeringNeeds are the tags Engineering of the task needs: macOS and
@@ -537,16 +539,20 @@ func (t *txn) place(k *taskRecord, s *stepRecord) (placed bool, err error) {
fit = append(fit, r)
}
}
- if len(fit) == 0 && relay {
+ if len(fit) == 0 {
// No runner can, and none is enrolled that could: the checks wait
// for a Mac runner instead of the Linux primary judging them
- // needs_macos.
+ // needs_macos, whatever its protocol.
return t.waitForMac(s, needs, wire.PlacementMac)
}
if !relay {
- // An older primary cannot relay a pack: it judges and says why
- // (needs_macos).
- return true, nil
+ // A Mac is enrolled but an older primary cannot relay a pack to
+ // it: the checks wait for a runner (the primary's update), and
+ // resolve as not run after the offline limit, as for an offline
+ // Mac. Never judged on the Linux primary.
+ now := t.now()
+ s.RunnerID, s.Placement, s.WaitingSince = "", wire.PlacementWaiting, &now
+ return false, nil
}
var chosen, unproven *runnerInfo
for i := range fit {
@@ -584,7 +590,7 @@ func (t *txn) place(k *taskRecord, s *stepRecord) (placed bool, err error) {
// must wait rather than run on the Linux primary, and leaves it waiting
// if so: for a Mac runner when none enrolled fits, else because no runner
// that fits takes Engineering (only the primary does). An older primary
-// (protocol 1), which has no workers, runs it as before.
+// (protocol 1) is no exception.
func (t *txn) macEngineering(k *taskRecord, s *stepRecord, primary string) (bool, error) {
needs, err := t.engineeringNeeds(*k, s.Person)
if err != nil || len(needs) == 0 {
@@ -596,9 +602,6 @@ func (t *txn) macEngineering(k *taskRecord, s *stepRecord, primary string) (bool
}
fit := false
for _, r := range rs {
- if r.ID == primary && r.Protocol < wire.Protocol2 {
- return false, nil
- }
if r.fits(needs, nil) {
if r.ID == primary {
// A primary that is a Mac takes it.
@@ -615,6 +618,29 @@ func (t *txn) macEngineering(k *taskRecord, s *stepRecord, primary string) (bool
return true, err
}
+// restartMacEngineering: whether the unstarted Engineering attempt s is
+// Mac work its runner cannot take; if so the attempt is ended and the
+// next one placed (it waits for a Mac).
+func (t *txn) restartMacEngineering(s *stepRecord) (bool, error) {
+ k, err := t.loadTask(s.TaskID)
+ if err != nil {
+ return false, err
+ }
+ primary, err := t.s.authority.PrimaryRunner(t.db, s.Person)
+ if err != nil {
+ return false, err
+ }
+ probe := *s
+ wait, err := t.macEngineering(&k, &probe, primary)
+ if err != nil || !wait {
+ return false, err
+ }
+ if err := t.replace(&k, s); err != nil {
+ return false, err
+ }
+ return true, t.saveStep(s, &k)
+}
+
// replace ends the current attempt's placement and places the next one:
// after a refusal, a withdrawal before it started, or a withdrawn
// attempt's termination. The caller saves s.
@@ -739,6 +765,17 @@ func (s *Store) Authorize(ctx context.Context, l Lease, stepID string, attempt i
if st.StartedAt != nil {
return nil
}
+ if st.Specialist == wire.SpecialistEngineering {
+ // Placement is decided again before Engineering starts: one
+ // dispatched to the Linux primary before Mac work waited for a
+ // Mac (an instance upgraded with it queued), or before the
+ // catalog said the gate needs Xcode, does not start there.
+ mac, err := t.restartMacEngineering(&st)
+ if err != nil || mac {
+ refused = "withdrawn"
+ return err
+ }
+ }
now := t.now()
return t.db.Model(&stepRecord{}).Where("id = ? AND attempt = ?", st.ID, st.Attempt).Update("started_at", now).Error
})
diff --git a/internal/headless/ask_test.go b/internal/headless/ask_test.go
index 66e78229..40b020af 100644
--- a/internal/headless/ask_test.go
+++ b/internal/headless/ask_test.go
@@ -65,8 +65,9 @@ func scenarioAsk(t *testing.T, env *Env) {
// before merging: the task waits at Ready to merge while its creator
// asks (a task Equipo merges ends at once). It touched the iOS app
// until 2026-11-28, when such a change began waiting for a Mac instead
- // of having its checks judged on Linux.
- sent := s.send(t, "tool:record_task:oficina/sample|Fix the README typo|The README says teh panes.\ntool:start_task:$task|create:.github/notes.md|Reading notes.; edit:README.md|teh panes|the panes")
+ // of having its checks judged on Linux. Review tries to write too
+ // (4_checks_honest did this until then): it is read-only.
+ sent := s.send(t, "tool:record_task:oficina/sample|Fix the README typo|The README says teh panes.\ntool:start_task:$task|create:.github/notes.md|Reading notes.; edit:README.md|teh panes|the panes review:write:README.md")
id := s.taskOf(t, sent.Turn.ID)
k := s.settled(t, id, 5*time.Minute)
if k.Stage != wire.StageReadyToMerge {
@@ -84,6 +85,13 @@ func scenarioAsk(t *testing.T, env *Env) {
if !eng.Askable || !rev.Askable {
t.Fatalf("sessions not kept: engineering %v review %v", eng.Askable, rev.Askable)
}
+ // Review read the change and could not write anything.
+ if !strings.Contains(rev.Summary, "Write to README.md was denied.") || rev.Family != "claude" || rev.Account == "" {
+ t.Fatalf("review %+v", rev)
+ }
+ if strings.Contains(forgeShow(t, env.ForgePath("amadan.net/oficina/sample"), k.CandidateSHA+":README.md"), "\nx") {
+ t.Fatal("review wrote")
+ }
if n := env.KeptSessions(t); n != 2 {
t.Fatalf("%d kept sessions, want 2", n)
}
diff --git a/internal/thintest/mac_wait_contract_test.go b/internal/thintest/mac_wait_contract_test.go
index 8b8d8c70..776fcba3 100644
--- a/internal/thintest/mac_wait_contract_test.go
+++ b/internal/thintest/mac_wait_contract_test.go
@@ -120,3 +120,125 @@ func TestContractMacEngineeringWaits(t *testing.T) {
}
t.Fatal("plain engineering not dispatched to the primary")
}
+
+// An older primary (protocol 1, no relay) is no way round the rule:
+// Mac Engineering and checks that need macOS wait for a Mac there too,
+// rather than run, or be judged needs_macos, on Linux (Astra,
+// mac-placement-wait).
+func TestContractMacWorkWaitsOnAnOlderPrimary(t *testing.T) {
+ // The tool rig's runner is a protocol 1 primary.
+ older := func() *runnersRig {
+ r := newToolRig(t)
+ return &runnersRig{toolRig: r, primary: &peer{t: t, r: r, fr: r.runner}, creds: map[*FakeRunner][2]string{}}
+ }
+ r := older()
+ h := toolHello(0)
+ h.Catalog[0].NeedsMacOS = true
+ r.primary.heartbeat(h)
+ task := taskID(t, r.call("c-old", wire.ToolRecordTask, map[string]string{"repo": "oficina/sample", "title": "Mac app", "brief": "b"}))
+ r.call("s-old", wire.ToolStartTask, map[string]string{"task": task, "brief": "go"})
+ r.primary.none(wire.FrameDispatch, 200*time.Millisecond)
+ if n := r.heldKinds(wire.FrameDispatch); n != 0 {
+ t.Fatalf("%d dispatches to an older primary", n)
+ }
+ if s := r.engineeringStep(task); s.State != wire.StepQueued || s.Placement != wire.PlacementMac || s.RunnerID != "" {
+ t.Fatalf("Mac engineering on an older primary: %+v", s)
+ }
+
+ r = older()
+ task = taskID(t, r.call("c-side", wire.ToolRecordTask, map[string]string{"repo": "oficina/sample", "title": "Mac sidebar", "brief": "b"}))
+ r.call("s-side", wire.ToolStartTask, map[string]string{"task": task, "brief": "go"})
+ _, body := r.expect(wire.FrameDispatch)
+ d := body.(*wire.DispatchCommand)
+ sha := strings.Repeat("f", 40)
+ r.step("o1", wire.StepReport{TaskID: task, StepID: d.StepID, Attempt: d.Attempt, State: wire.StepRunning, BaseSHA: strings.Repeat("1", 40), Findings: []wire.Finding{}})
+ r.step("o2", wire.StepReport{TaskID: task, StepID: d.StepID, Attempt: d.Attempt, State: wire.StepDone, CandidateSHA: sha, Pushed: true, Termination: true, TerminationKind: wire.TerminationNamespace, Apple: true, Findings: []wire.Finding{}})
+ r.primary.none(wire.FrameDispatch, 200*time.Millisecond)
+ if n := r.heldKinds(wire.FrameDispatch); n != 0 {
+ t.Fatalf("%d checks dispatches to an older primary", n)
+ }
+ if s := r.checksStep(task); s.State != wire.StepQueued || s.Placement != wire.PlacementMac || s.RunnerID != "" {
+ t.Fatalf("Mac checks on an older primary: %+v", s)
+ }
+ if got := r.needsYou(task); got != wire.NeedsMacRunner {
+ t.Fatalf("needs you %q", got)
+ }
+}
+
+// Engineering dispatched to the Linux primary before this rule (an
+// instance upgraded with it queued, here: the catalog said Xcode only
+// after the dispatch) is refused when the primary asks to start it, and
+// waits for a Mac like new work.
+func TestContractMacEngineeringQueuedBeforeTheRule(t *testing.T) {
+ r := newRunnersRig(t)
+ task := taskID(t, r.call("c-q", wire.ToolRecordTask, map[string]string{"repo": "oficina/sample", "title": "Mac app", "brief": "b"}))
+ r.call("s-q", wire.ToolStartTask, map[string]string{"task": task, "brief": "go"})
+ _, body := r.expect(wire.FrameDispatch)
+ d := body.(*wire.DispatchCommand)
+ if d.Specialist != wire.SpecialistEngineering {
+ t.Fatalf("dispatch %+v", d)
+ }
+ h := primaryHello(0)
+ h.Catalog[0].NeedsMacOS = true
+ r.primary.heartbeat(h)
+ if r.primary.lease(d.StepID, d.Attempt) {
+ t.Fatal("Mac engineering started on the Linux primary")
+ }
+ if s := r.engineeringStep(task); s.State != wire.StepQueued || s.Placement != wire.PlacementMac || s.RunnerID != "" || s.Attempt != d.Attempt+1 {
+ t.Fatalf("not waiting for a Mac: %+v", s)
+ }
+ if got := r.needsYou(task); got != wire.NeedsMacRunner {
+ t.Fatalf("needs you %q", got)
+ }
+}
+
+// Checks of a change that touched no Apple file still wait for a Mac
+// when the repository's own gate needs Xcode (the base's catalog), and
+// run on the Mac once one enrols.
+func TestContractChecksWaitForTheGatesMac(t *testing.T) {
+ r := newRunnersRig(t)
+ task := taskID(t, r.call("c-g", wire.ToolRecordTask, map[string]string{"repo": "oficina/sample", "title": "Readme", "brief": "b"}))
+ r.call("s-g", wire.ToolStartTask, map[string]string{"task": task, "brief": "go"})
+ _, body := r.expect(wire.FrameDispatch)
+ d := body.(*wire.DispatchCommand)
+ // Engineering ran before the gate needed Xcode; its checks come after.
+ h := primaryHello(0)
+ h.Catalog[0].NeedsMacOS = true
+ r.primary.heartbeat(h)
+ sha := strings.Repeat("e", 40)
+ r.step("g1", wire.StepReport{TaskID: task, StepID: d.StepID, Attempt: d.Attempt, State: wire.StepRunning, BaseSHA: strings.Repeat("1", 40), Findings: []wire.Finding{}})
+ r.step("g2", wire.StepReport{TaskID: task, StepID: d.StepID, Attempt: d.Attempt, State: wire.StepDone, CandidateSHA: sha, Pushed: true, Termination: true, TerminationKind: wire.TerminationNamespace, Findings: []wire.Finding{}})
+ r.primary.none(wire.FrameDispatch, 200*time.Millisecond)
+ if s := r.checksStep(task); s.State != wire.StepQueued || s.Placement != wire.PlacementMac || !strings.Contains(strings.Join(s.Needs, ","), "xcode") {
+ t.Fatalf("gate-only checks did not wait for a Mac: %+v", s)
+ }
+ w, _ := r.newWorker("Tito Studio")
+ _, body = w.expect(wire.FrameDispatch)
+ if c := body.(*wire.DispatchCommand); c.TaskID != task || c.Specialist != wire.SpecialistChecks || c.CandidateSHA != sha {
+ t.Fatalf("checks on the new Mac: %+v", c)
+ }
+}
+
+// An exploration of an Xcode repository waits for a Mac under Needs you,
+// like any task, and can be cancelled from there.
+func TestContractExplorationWaitsForAMac(t *testing.T) {
+ r := newRunnersRig(t)
+ h := primaryHello(0)
+ h.Catalog[0].NeedsMacOS = true
+ r.primary.heartbeat(h)
+ task := taskID(t, r.call("c-x", wire.ToolRecordTask, map[string]any{"repo": "oficina/sample", "title": "Mac mockups", "brief": "Two mockups.", "separate": true, "kind": wire.KindExplore}))
+ r.call("s-x", wire.ToolStartTask, map[string]string{"task": task, "brief": "go"})
+ r.primary.none(wire.FrameDispatch, 200*time.Millisecond)
+ if s := r.engineeringStep(task); s.State != wire.StepQueued || s.Placement != wire.PlacementMac {
+ t.Fatalf("exploration engineering %+v", s)
+ }
+ if got := r.needsYou(task); got != wire.NeedsMacRunner {
+ t.Fatalf("an exploration waiting for a Mac needs you %q", got)
+ }
+ if _, err := r.client.CancelTask(r.ctx, task); err != nil {
+ t.Fatal(err)
+ }
+ if k, err := r.client.Task(r.ctx, task); err != nil || k.Stage != wire.StageCancelled || k.NeedsYou != "" {
+ t.Fatalf("not cancelled: %+v %v", k, err)
+ }
+}