oficina / equipo Public

hostedctl: confirm a missing VM twice before stop proof

Controller ruling R17: GetMicrovm is eventually consistent, so one
not-found no longer proves a VM gone. Stop and Refresh record the first
not-found in the new nullable jobs.notfound_since_t and prove the VM
gone only on a second not-found NotFoundConfirm (60 s) later, with the
first after the stop request and no live Get between; a live Get clears
the mark. Terminal states stay immediate proof.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
claude agent, operated by paul@keymail.dev pushed by paul@keymail.dev c9b9307e4c0929a099af32979489dfd348917989 parent 9202c3d
5 files changed, +215 −22
  • docs/superpowers/plans/HOSTED-SLICE1-PROGRESS.md +18 −1
  • internal/hostedctl/refresh.go +6 −5
  • internal/hostedctl/schema/0001_jobs.sql +1 −0
  • internal/hostedctl/stop.go +87 −11
  • internal/hostedctl/stop_test.go +103 −5

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/hosted-runners-1a: Type  Size Avail | ext4   96G   85G
ci-box: disk /home/ci/.cache/equipo-ci-box: Type  Size Avail | ext4   96G   85G
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.5s
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 10.0s
ci-box: pi: installed and verified in 8.0s
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 9.1s
ci-box: clone deepened in 3.6s
ci-box: file times set from content: 2875 files, 192 directories
ci-box: ready in 17.9s
=== 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.257s
=== compile ===
go build ./...
RASTRILLO='go run amadan.net/rastrillo/rastrillo/cmd/rastrillo' python3 scripts/ci-test.py compile
+ go build -tags testbuild ./...
  1.3s
+ go list -export -test -tags testbuild -f  ./...
  0.9s
+ go list -export -test -tags browser,testbuild -f  ./internal/equipo ./internal/headless ./internal/idtest ./internal/plan3test ./internal/thintest
  0.3s
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-11 02:51:11 +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
cache miss: amadan.net/oficina/equipo/internal/headless: its inputs changed

receipt: test step 1m24.404s 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 1m22.698s amadan.net/oficina/equipo/internal/headless
receipt: slow test 1m22.7s amadan.net/oficina/equipo/internal/headless TestHeadless
machine: 32 CPUs, load 42.02, cpu waiting 23.09%, memory waiting 0.00%, io waiting 0.61%
--- 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
cache miss: amadan.net/oficina/equipo/internal/headless: its inputs changed

receipt: test step 1m28.265s 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 1m26.482s amadan.net/oficina/equipo/internal/headless
receipt: slow test 1m26.48s amadan.net/oficina/equipo/internal/headless TestHeadless
machine: 32 CPUs, load 40.90, cpu waiting 22.12%, memory waiting 0.00%, io waiting 0.57%
--- 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
cache miss: amadan.net/oficina/equipo/internal/headless: its inputs changed

receipt: test step 1m29.331s 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 1m27.074s amadan.net/oficina/equipo/internal/headless
receipt: slow test 1m16.08s amadan.net/oficina/equipo/internal/headless TestHeadlessConnections
receipt: slow test 6s amadan.net/oficina/equipo/internal/headless TestHeadlessTokenPasteEndToEnd
receipt: slow test 4.99s amadan.net/oficina/equipo/internal/headless TestHeadlessTokenConnection
machine: 32 CPUs, load 40.90, cpu waiting 21.53%, memory waiting 0.00%, io waiting 0.55%
--- 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
cache miss: amadan.net/oficina/equipo/internal/headless: its inputs changed

receipt: test step 1m23.814s 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 1m22.095s amadan.net/oficina/equipo/internal/headless
receipt: slow test 40.12s amadan.net/oficina/equipo/internal/headless TestMacWorker
receipt: slow test 21.29s amadan.net/oficina/equipo/internal/headless TestHeadless
receipt: slow test 10.88s amadan.net/oficina/equipo/internal/headless TestHeadlessAttachments
receipt: slow test 9.8s amadan.net/oficina/equipo/internal/headless TestHeadlessPrewarm
machine: 32 CPUs, load 42.02, cpu waiting 23.47%, memory waiting 0.00%, io waiting 0.63%
--- 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_empty_repo$|^TestHeadless$/^3_empty_engineering$|^TestHeadless$/^3_empty_merge$|^TestHeadless$/^3_empty_merge_rebuilt$|^TestHeadless$/^3_empty_fix_round$' ./internal/headless
cache miss: amadan.net/oficina/equipo/internal/headless: its inputs changed

receipt: test step 1m42.455s 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 1m40.62s amadan.net/oficina/equipo/internal/headless
receipt: slow test 1m2.51s amadan.net/oficina/equipo/internal/headless TestHeadless
receipt: slow test 12.2s amadan.net/oficina/equipo/internal/headless TestHeadlessRunnerKillLeavesNoCopies
receipt: slow test 10.48s amadan.net/oficina/equipo/internal/headless TestHeadlessCopyRotation
receipt: slow test 9.2s amadan.net/oficina/equipo/internal/headless TestHeadlessPolicyGuards
receipt: slow test 6.22s amadan.net/oficina/equipo/internal/headless TestHeadlessNewHouseRuleStartsFresh
machine: 32 CPUs, load 35.31, cpu waiting 17.84%, memory waiting 0.00%, io waiting 0.45%
--- 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_empty_repo$|^TestHeadless$/^3_empty_engineering$|^TestHeadless$/^3_empty_merge$|^TestHeadless$/^3_empty_merge_rebuilt$|^TestHeadless$/^3_empty_fix_round$' ./internal/headless
cache miss: amadan.net/oficina/equipo/internal/headless: its inputs changed

receipt: test step 3m18.043s 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 3m15.897s amadan.net/oficina/equipo/internal/headless
receipt: slow test 1m49.34s amadan.net/oficina/equipo/internal/headless TestHeadlessAssistant
receipt: slow test 25.62s amadan.net/oficina/equipo/internal/headless TestHeadless
receipt: slow test 12.24s amadan.net/oficina/equipo/internal/headless TestHeadlessResearchHandoff
receipt: slow test 8.55s amadan.net/oficina/equipo/internal/headless TestHeadlessClaudeSignIn
receipt: slow test 7.55s amadan.net/oficina/equipo/internal/headless TestHeadlessTurnBatching
machine: 32 CPUs, load 9.09, cpu waiting 3.64%, memory waiting 0.00%, io waiting 0.08%
--- 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 1.249s against a 60s target (the gate's other steps are not in this figure)
receipt: 0 packages ran, 1 cached, 0 without tests, 0 failed
receipt: slow package 2m1.624s amadan.net/oficina/equipo/internal/thintest
receipt: slow test 7.84s amadan.net/oficina/equipo/internal/thintest TestContractTeamJobSettledStates
receipt: slow test 6.74s amadan.net/oficina/equipo/internal/thintest TestExplorePreviewsOff
receipt: slow test 4.31s amadan.net/oficina/equipo/internal/thintest TestContractTeamUpdatePersonNeeds
receipt: slow test 3.81s amadan.net/oficina/equipo/internal/thintest TestContractPreviewHeldUntilPublishAnswer
receipt: slow test 3.52s amadan.net/oficina/equipo/internal/thintest TestContractTeamNudgePersonNeeds
machine: 32 CPUs, load 1.50, cpu waiting 0.39%, memory waiting 0.00%, io waiting 2.51%
--- 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

receipt: test step 1.12s against a 60s target (the gate's other steps are not in this figure)
receipt: 0 packages ran, 1 cached, 0 without tests, 0 failed
receipt: slow package 1m26.784s amadan.net/oficina/equipo/internal/thintest
receipt: slow test 9.08s amadan.net/oficina/equipo/internal/thintest TestContractPreviewNotScheduled
receipt: slow test 5.03s amadan.net/oficina/equipo/internal/thintest TestContractPublishNotOffered
receipt: slow test 4.41s amadan.net/oficina/equipo/internal/thintest TestContractMacRecheckMergeAuthority
receipt: slow test 2.4s amadan.net/oficina/equipo/internal/thintest TestContractPreview
receipt: slow test 2.34s amadan.net/oficina/equipo/internal/thintest TestContractPublishNameTaken
machine: 32 CPUs, load 1.50, cpu waiting 0.39%, memory waiting 0.00%, io waiting 2.51%
--- 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 4m37.201s, over the 45s its record on line 44 allows; reported only, timing fails on CI

receipt: test step 4m50.474s 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 4m37.201s amadan.net/oficina/equipo/internal/runner/thin
receipt: slow test 37.05s amadan.net/oficina/equipo/internal/runner/thin TestModelsProbeAnsweredByAnotherModel
receipt: slow test 37.02s amadan.net/oficina/equipo/internal/runner/thin TestModelsEngineeringProbesThenRunsTheStrongest
receipt: slow test 36.88s amadan.net/oficina/equipo/internal/runner/thin TestModelsUnhealthyRetriedOnDemand
receipt: slow test 18.51s amadan.net/oficina/equipo/internal/runner/thin TestModelsProbeRunsInsideTheAdmission
receipt: slow test 7.58s amadan.net/oficina/equipo/internal/runner/thin TestOpenCodeStepsRealOpenCode
machine: 32 CPUs, load 2.63, cpu waiting 0.78%, memory waiting 0.00%, io waiting 0.01%
--- 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 50.286s 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 49.115s amadan.net/oficina/equipo/internal/runner
receipt: slow test 29.08s amadan.net/oficina/equipo/internal/runner TestDirectBugWorkflow
receipt: slow test 20.03s amadan.net/oficina/equipo/internal/runner TestEnrolKeepsTheRole
machine: 32 CPUs, load 42.88, cpu waiting 22.79%, memory waiting 0.00%, io waiting 1.09%
--- 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 50.949s 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 49.006s amadan.net/oficina/equipo/internal/runner
receipt: slow test 38.84s amadan.net/oficina/equipo/internal/runner TestPlanWorkflowCandidateOrder
receipt: slow test 35.97s amadan.net/oficina/equipo/internal/runner TestPlanWorkflowFeature
receipt: slow test 8.45s amadan.net/oficina/equipo/internal/runner TestCoordinatorRecoveryCallRefusalKeepsServing
receipt: slow test 1.69s amadan.net/oficina/equipo/internal/runner TestCoordinatorRefusalMatrix
machine: 32 CPUs, load 42.88, cpu waiting 22.79%, memory waiting 0.00%, io waiting 1.09%
--- 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 35.992s 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.08s amadan.net/oficina/equipo/internal/runner
receipt: slow test 5.13s amadan.net/oficina/equipo/internal/runner TestDirectFaultIsolation
receipt: slow test 3.59s amadan.net/oficina/equipo/internal/runner TestClaimRefusalsBackOff
receipt: slow test 3.13s amadan.net/oficina/equipo/internal/runner TestCoordinatorRecoveryRefusedKeepsServing
receipt: slow test 2.53s amadan.net/oficina/equipo/internal/runner TestToolVerbUnderFakeHarness
receipt: slow test 1.61s amadan.net/oficina/equipo/internal/runner TestReportPostsRetryExactRequest
machine: 32 CPUs, load 31.20, cpu waiting 15.76%, memory waiting 0.00%, io waiting 1.42%
--- 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 31.1%, load 24.43
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
cache miss: amadan.net/oficina/equipo/internal/equipotest: its inputs changed

receipt: test step 1m7.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 1m5.228s amadan.net/oficina/equipo/internal/equipotest
receipt: slow test 27.68s amadan.net/oficina/equipo/internal/equipotest TestAuthorityCoreIntegration
receipt: slow test 27.55s amadan.net/oficina/equipo/internal/equipotest TestBootstrapNamesOwnersSetting
receipt: slow test 25.47s amadan.net/oficina/equipo/internal/equipotest TestAccountLabelMigration
receipt: slow test 22.79s amadan.net/oficina/equipo/internal/equipotest TestBudgetConfigurationFailuresAreAtomic
receipt: slow test 22.57s amadan.net/oficina/equipo/internal/equipotest TestBudgetLoweringBelowUsage
machine: 32 CPUs, load 38.13, cpu waiting 19.61%, memory waiting 0.00%, io waiting 0.50%
--- 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 30.0%, load 24.43
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 1.452s against a 60s target (the gate's other steps are not in this figure)
receipt: 0 packages ran, 1 cached, 0 without tests, 0 failed
receipt: slow package 1m12.399s amadan.net/oficina/equipo/internal/equipotest
receipt: slow test 19.2s amadan.net/oficina/equipo/internal/equipotest TestProjectWritesRequireCurrentOwner
receipt: slow test 19.12s amadan.net/oficina/equipo/internal/equipotest TestProjectOwnersAreMembers
receipt: slow test 19.11s amadan.net/oficina/equipo/internal/equipotest TestProjectsReopen
receipt: slow test 19.11s amadan.net/oficina/equipo/internal/equipotest TestProjectRetryAndRevision
receipt: slow test 19.08s amadan.net/oficina/equipo/internal/equipotest TestProjectsFailuresRollBack
machine: 32 CPUs, load 24.43, cpu waiting 12.37%, memory waiting 0.00%, io waiting 1.52%
--- 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 30.0%, load 24.43
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
cache miss: amadan.net/oficina/equipo/internal/equipotest: its inputs changed

receipt: test step 1m19.684s 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.081s amadan.net/oficina/equipo/internal/equipotest
receipt: slow test 15.02s amadan.net/oficina/equipo/internal/equipotest TestReleaseStampContract
receipt: slow test 13.23s amadan.net/oficina/equipo/internal/equipotest TestRosterChangesAffectExistingSession
receipt: slow test 10.2s amadan.net/oficina/equipo/internal/equipotest TestRosterRemovalWhileAssigned
receipt: slow test 10.14s amadan.net/oficina/equipo/internal/equipotest TestRosterRemovalRollsBack
receipt: slow test 7.09s amadan.net/oficina/equipo/internal/equipotest TestRosterAuditFailureRollsBack
machine: 32 CPUs, load 35.45, cpu waiting 16.17%, memory waiting 0.00%, io waiting 0.41%
--- 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 30.0%, load 24.43
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 457ms against a 60s target (the gate's other steps are not in this figure)
receipt: 0 packages ran, 1 cached, 0 without tests, 0 failed
receipt: slow package 1m4.231s amadan.net/oficina/equipo/internal/equipotest
receipt: slow test 24.45s amadan.net/oficina/equipo/internal/equipotest TestSigninNoProof
receipt: slow test 23.28s amadan.net/oficina/equipo/internal/equipotest TestSpecialistsSeedExistingTeam
receipt: slow test 23.2s amadan.net/oficina/equipo/internal/equipotest TestSpecialistsSeedRollback
receipt: slow test 21.61s amadan.net/oficina/equipo/internal/equipotest TestSpecialistsUpgrade
receipt: slow test 21.57s amadan.net/oficina/equipo/internal/equipotest TestSpecialistSettingsRollbackAndUnavailable
machine: 32 CPUs, load 24.43, cpu waiting 12.37%, memory waiting 0.00%, io waiting 1.52%
--- 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 31.1%, load 24.43
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

receipt: test step 717ms against a 60s target (the gate's other steps are not in this figure)
receipt: 0 packages ran, 1 cached, 0 without tests, 0 failed
receipt: slow package 48.756s amadan.net/oficina/equipo/internal/plan3test
receipt: slow test 3.61s amadan.net/oficina/equipo/internal/plan3test TestPlan3Upgrade
receipt: slow test 3.41s amadan.net/oficina/equipo/internal/plan3test TestCoordinatorAcceptance3B
receipt: slow test 1.5s amadan.net/oficina/equipo/internal/plan3test TestConversationQuestionRace
receipt: slow test 1.47s amadan.net/oficina/equipo/internal/plan3test TestCoordinatorAcceptance3A
receipt: slow test 1.21s amadan.net/oficina/equipo/internal/plan3test TestPlanMigrationUpgrade
machine: 32 CPUs, load 24.43, cpu waiting 12.37%, memory waiting 0.00%, io waiting 1.52%
--- 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 30.0%, load 24.43
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/equipo ./internal/equipo/activity ./internal/equipo/assist ./internal/equipo/chat ./internal/equipo/conversation ./internal/equipo/conversation/chatstate ./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/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/hostedctl ./internal/hostedwire ./internal/idtest ./internal/isolatedjob ./internal/isolatedjob/awsjob ./internal/isolatedjob/guardfixture ./internal/isolatedjob/isolatedjobtest ./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/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/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/equipo ./internal/equipo/activity ./internal/equipo/assist ./internal/equipo/chat ./internal/equipo/conversation ./internal/equipo/conversation/chatstate ./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/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/hostedctl ./internal/hostedwire ./internal/idtest ./internal/isolatedjob ./internal/isolatedjob/awsjob ./internal/isolatedjob/guardfixture ./internal/isolatedjob/isolatedjobtest ./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/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/wireschema ./internal/wire/wiretest ./tools/drive
cache miss: amadan.net/oficina/equipo/internal/isolatedjob: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/copydesk: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/provider/opencode: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/provider: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/forge: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/webread: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/equipo/team: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/provider/claude: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/workspace: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/provider/codex: its inputs changed
cache miss: amadan.net/oficina/equipo/internal/runner/checks: 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
budget note: internal/equipo took 45.275s, over the 10s the default allows (measured on the run this cached result came from); reported only, timing fails on CI
budget note: internal/equipo/chat took 12.529s, 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 39.84s, over the 10s the default allows (measured on the run this cached result came from); reported only, timing fails on CI
budget note: internal/release took 34.981s, 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 42.952s, over the 15s its record on line 40 allows; reported only, timing fails on CI

receipt: test step 2m22.851s against a 60s target (the gate's other steps are not in this figure)
receipt: 13 packages ran, 52 cached, 20 without tests, 0 failed
receipt: slow package 59.495s amadan.net/oficina/equipo/internal/runner/provider/opencode
receipt: slow package 55.975s amadan.net/oficina/equipo/internal/runner/provider/pi
receipt: slow package 45.275s amadan.net/oficina/equipo/internal/equipo
receipt: slow package 42.952s amadan.net/oficina/equipo/internal/runner/containment
receipt: slow package 40.242s amadan.net/oficina/equipo/internal/runner/checks
receipt: slow test 24.55s amadan.net/oficina/equipo/internal/runner/provider/opencode TestOpenCodeAcceptanceHostileRepository
receipt: slow test 15.93s amadan.net/oficina/equipo/internal/runner/containment TestEngineeringOfflineGo
receipt: slow test 11.2s amadan.net/oficina/equipo/internal/runner/containment TestEngineeringMissingModuleCache
receipt: slow test 10.89s amadan.net/oficina/equipo/internal/idtest TestIDCallbackGuardAndPendingNonce
receipt: slow test 10.82s amadan.net/oficina/equipo/internal/equipo TestAgentReadRechecksIdentity
machine: 32 CPUs, load 13.16, cpu waiting 5.61%, memory waiting 0.00%, io waiting 0.13%
--- 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
cache miss: amadan.net/oficina/equipo/internal/headless: its inputs changed

receipt: test step 1m25.164s 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 1m23.445s amadan.net/oficina/equipo/internal/headless
receipt: slow test 37.77s amadan.net/oficina/equipo/internal/headless TestBrowserDraftIsTheMessage
receipt: slow test 15.48s amadan.net/oficina/equipo/internal/headless TestBrowserDraftStreamsFormatted
receipt: slow test 11.23s amadan.net/oficina/equipo/internal/headless TestBrowserChat
receipt: slow test 7.97s amadan.net/oficina/equipo/internal/headless TestBrowserComposer
receipt: slow test 6.07s amadan.net/oficina/equipo/internal/headless TestBrowserChatSendStaysOnPage
machine: 32 CPUs, load 42.02, cpu waiting 22.60%, memory waiting 0.00%, io waiting 0.59%
--- 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
cache miss: amadan.net/oficina/equipo/internal/headless: its inputs changed

receipt: test step 1m38.464s 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 1m36.68s amadan.net/oficina/equipo/internal/headless
receipt: slow test 28.36s amadan.net/oficina/equipo/internal/headless TestBrowserRailFollowsWork
receipt: slow test 24.22s amadan.net/oficina/equipo/internal/headless TestBrowserTaskThread
receipt: slow test 14.7s amadan.net/oficina/equipo/internal/headless TestBrowserReceiptFollowsReview
receipt: slow test 10.75s amadan.net/oficina/equipo/internal/headless TestBrowserAskAfterMerge
receipt: slow test 8.32s amadan.net/oficina/equipo/internal/headless TestBrowserTaskCard
machine: 32 CPUs, load 38.13, cpu waiting 19.03%, memory waiting 0.00%, io waiting 0.48%
--- 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
cache miss: amadan.net/oficina/equipo/internal/headless: its inputs changed

receipt: test step 1m44.976s 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 1m43.163s amadan.net/oficina/equipo/internal/headless
receipt: slow test 15.4s amadan.net/oficina/equipo/internal/headless TestBrowserConnectionsConversation
receipt: slow test 14.49s amadan.net/oficina/equipo/internal/headless TestBrowserConnectionsAdd
receipt: slow test 13.12s amadan.net/oficina/equipo/internal/headless TestBrowserConnectionsAddPage
receipt: slow test 10.42s amadan.net/oficina/equipo/internal/headless TestBrowserConnectionsMeteredLimitRequired
receipt: slow test 10.29s amadan.net/oficina/equipo/internal/headless TestBrowserConnectionsOpenCodeGoLimitRequired
machine: 32 CPUs, load 35.31, cpu waiting 17.29%, memory waiting 0.00%, io waiting 0.44%
--- 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|TestBrowserChat|TestBrowserChatSendStaysOnPage|TestBrowserComposer|TestBrowserComposerDock|TestBrowserComposerFocus|TestBrowserComposerReconcile|TestBrowserConnectionsAdd|TestBrowserConnectionsAddPage|TestBrowserConnectionsConversation|TestBrowserConnectionsCopyLink|TestBrowserConnectionsEndedNote|TestBrowserConnectionsMeteredLimitRequired|TestBrowserConnectionsOpenCodeGoLimitRequired|TestBrowserConnectionsSignIn|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
--- FAIL amadan.net/oficina/equipo/internal/headless TestBrowserThinkingAndCards
=== RUN   TestBrowserThinkingAndCards
time=2026-11-22T17:33:49.303Z level=INFO msg="startup phase" phase=state_lock
time=2026-11-22T17:33:49.303Z level=INFO msg="startup phase done" phase=state_lock took=80µs
time=2026-11-22T17:33:49.303Z level=INFO msg="startup phase" phase=claim_roots
time=2026-11-22T17:33:49.303Z level=INFO msg="startup phase done" phase=claim_roots took=102µs
time=2026-11-22T17:33:49.303Z level=INFO msg="startup phase" phase=sweep
time=2026-11-22T17:33:49.331Z level=INFO msg="startup phase done" phase=sweep took=28.175ms
time=2026-11-22T17:33:49.331Z level=INFO msg="startup phase" phase=credentials
time=2026-11-22T17:33:49.331Z level=INFO msg="startup phase done" phase=credentials took=105µs
time=2026-11-22T17:33:49.331Z level=INFO msg="startup phase" phase=open_state
time=2026-11-22T17:33:49.373Z level=INFO msg="startup phase done" phase=open_state took=41.157ms
time=2026-11-22T17:33:49.373Z level=WARN msg="no seal key: token connections cannot be added" err=*fs.PathError
time=2026-11-22T17:33:49.375Z level=INFO msg=connecting host=127.0.0.1:41175 protocol=28
time=2026-11-22T17:33:49.376Z level=INFO msg=connected host=127.0.0.1:41175 took=981µs
time=2026-11-22T17:33:49.376Z level=INFO msg="capabilities gathering"
time=2026-11-22T17:33:49.376Z level=INFO msg="capabilities gathered" took=483µs tags=linux,claude,go
time=2026-11-22T17:33:49.377Z level=INFO msg="hello sent" protocol=28
time=2026-11-22T17:33:49.382Z level=INFO msg=welcome protocol=28 role=primary generation=1
time=2026-11-22T17:33:50.640Z level=INFO msg="connection checked" connection=claude-1 state=healthy
    browser_cards_test.go:66: waiting for (()=>{const l=document.querySelector('[equipo-thinking] [equipo-activity]');return !!l && l.textContent==='Adding oficina/sample…'})(): context deadline exceeded (last evaluation: context deadline exceeded)
--- FAIL: TestBrowserThinkingAndCards (6.92s)

--- FAIL amadan.net/oficina/equipo/internal/headless TestBrowserEmptyExplore
=== RUN   TestBrowserEmptyExplore
time=2026-11-22T17:34:50.984Z level=INFO msg="startup phase" phase=state_lock
time=2026-11-22T17:34:50.984Z level=INFO msg="startup phase done" phase=state_lock took=74µs
time=2026-11-22T17:34:50.984Z level=INFO msg="startup phase" phase=claim_roots
time=2026-11-22T17:34:50.985Z level=INFO msg="startup phase done" phase=claim_roots took=94µs
time=2026-11-22T17:34:50.985Z level=INFO msg="startup phase" phase=sweep
time=2026-11-22T17:34:51.015Z level=INFO msg="startup phase done" phase=sweep took=30.403ms
time=2026-11-22T17:34:51.015Z level=INFO msg="startup phase" phase=credentials
time=2026-11-22T17:34:51.015Z level=INFO msg="startup phase done" phase=credentials took=146µs
time=2026-11-22T17:34:51.015Z level=INFO msg="startup phase" phase=open_state
time=2026-11-22T17:34:51.058Z level=INFO msg="startup phase done" phase=open_state took=42.328ms
time=2026-11-22T17:34:51.058Z level=WARN msg="no seal key: token connections cannot be added" err=*fs.PathError
time=2026-11-22T17:34:51.059Z level=INFO msg=connecting host=127.0.0.1:34269 protocol=28
time=2026-11-22T17:34:51.060Z level=INFO msg=connected host=127.0.0.1:34269 took=886µs
time=2026-11-22T17:34:51.060Z level=INFO msg="capabilities gathering"
time=2026-11-22T17:34:51.061Z level=INFO msg="capabilities gathered" took=1.123ms tags=linux,claude,go
time=2026-11-22T17:34:51.062Z level=INFO msg="hello sent" protocol=28
time=2026-11-22T17:34:51.069Z level=INFO msg=welcome protocol=28 role=primary generation=1
time=2026-11-22T17:34:52.186Z level=INFO msg="connection checked" connection=claude-1 state=healthy
    browser_receipts_test.go:169: waiting for [...document.querySelectorAll('[equipo-markdown]:not([data-stream-text])')].some(e=>e.textContent.includes("I'm your coordinator")): context deadline exceeded (last evaluation: context deadline exceeded)
--- FAIL: TestBrowserEmptyExplore (5.88s)

--- FAIL amadan.net/oficina/equipo/internal/headless (package output)
FAIL
rastrillo-budget/v1 ran 1m22.897s
FAIL	amadan.net/oficina/equipo/internal/headless	83.210s


receipt: test step 1m24.407s 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 1m22.897s amadan.net/oficina/equipo/internal/headless
receipt: slow test 11.94s amadan.net/oficina/equipo/internal/headless TestBrowserStalePageReloads
receipt: slow test 11.3s amadan.net/oficina/equipo/internal/headless TestBrowserMoveIn
receipt: slow test 10.65s amadan.net/oficina/equipo/internal/headless TestBrowserWaitingTurns
receipt: slow test 8.22s amadan.net/oficina/equipo/internal/headless TestBrowserRefreshRace
receipt: slow test 7.48s amadan.net/oficina/equipo/internal/headless TestBrowserNotebookLook
rastrillo: budget test: go test failed
exit status 1
+ go test -tags browser,testbuild -timeout 15m -run '^(TestBrowserAskAfterMerge|TestBrowserChat|TestBrowserChatSendStaysOnPage|TestBrowserComposer|TestBrowserComposerDock|TestBrowserComposerFocus|TestBrowserComposerReconcile|TestBrowserConnectionsAdd|TestBrowserConnectionsAddPage|TestBrowserConnectionsConversation|TestBrowserConnectionsCopyLink|TestBrowserConnectionsEndedNote|TestBrowserConnectionsMeteredLimitRequired|TestBrowserConnectionsOpenCodeGoLimitRequired|TestBrowserConnectionsSignIn|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 '^TestBrowserEmptyExplore$|^TestBrowserThinkingAndCards$' -count=1 ./internal/headless   (retry, once)
FAILED TWICE ./internal/headless:TestBrowserEmptyExplore browser-headless-rest
FAILED TWICE ./internal/headless:TestBrowserThinkingAndCards browser-headless-rest
=== RUN   TestBrowserThinkingAndCards
time=2026-11-22T17:35:13.586Z level=INFO msg="startup phase" phase=state_lock
time=2026-11-22T17:35:13.586Z level=INFO msg="startup phase done" phase=state_lock took=74µs
time=2026-11-22T17:35:13.586Z level=INFO msg="startup phase" phase=claim_roots
time=2026-11-22T17:35:13.586Z level=INFO msg="startup phase done" phase=claim_roots took=104µs
time=2026-11-22T17:35:13.586Z level=INFO msg="startup phase" phase=sweep
time=2026-11-22T17:35:13.620Z level=INFO msg="startup phase done" phase=sweep took=34.194ms
time=2026-11-22T17:35:13.620Z level=INFO msg="startup phase" phase=credentials
time=2026-11-22T17:35:13.620Z level=INFO msg="startup phase done" phase=credentials took=113µs
time=2026-11-22T17:35:13.620Z level=INFO msg="startup phase" phase=open_state
time=2026-11-22T17:35:13.662Z level=INFO msg="startup phase done" phase=open_state took=41.673ms
time=2026-11-22T17:35:13.662Z level=WARN msg="no seal key: token connections cannot be added" err=*fs.PathError
time=2026-11-22T17:35:13.663Z level=INFO msg=connecting host=127.0.0.1:35707 protocol=28
time=2026-11-22T17:35:13.665Z level=INFO msg=connected host=127.0.0.1:35707 took=2.056ms
time=2026-11-22T17:35:13.666Z level=INFO msg="capabilities gathering"
time=2026-11-22T17:35:13.666Z level=INFO msg="capabilities gathered" took=411µs tags=linux,claude,go
time=2026-11-22T17:35:13.667Z level=INFO msg="hello sent" protocol=28
time=2026-11-22T17:35:13.673Z level=INFO msg=welcome protocol=28 role=primary generation=1
time=2026-11-22T17:35:14.787Z level=INFO msg="connection checked" connection=claude-1 state=healthy
--- PASS: TestBrowserThinkingAndCards (15.07s)
=== RUN   TestBrowserEmptyExplore
time=2026-11-22T17:35:27.541Z level=INFO msg="startup phase" phase=state_lock
time=2026-11-22T17:35:27.541Z level=INFO msg="startup phase done" phase=state_lock took=73µs
time=2026-11-22T17:35:27.541Z level=INFO msg="startup phase" phase=claim_roots
time=2026-11-22T17:35:27.541Z level=INFO msg="startup phase done" phase=claim_roots took=80µs
time=2026-11-22T17:35:27.541Z level=INFO msg="startup phase" phase=sweep
time=2026-11-22T17:35:27.575Z level=INFO msg="startup phase done" phase=sweep took=33.586ms
time=2026-11-22T17:35:27.575Z level=INFO msg="startup phase" phase=credentials
time=2026-11-22T17:35:27.575Z level=INFO msg="startup phase done" phase=credentials took=130µs
time=2026-11-22T17:35:27.575Z level=INFO msg="startup phase" phase=open_state
time=2026-11-22T17:35:27.616Z level=INFO msg="startup phase done" phase=open_state took=40.655ms
time=2026-11-22T17:35:27.616Z level=WARN msg="no seal key: token connections cannot be added" err=*fs.PathError
time=2026-11-22T17:35:27.617Z level=INFO msg=connecting host=127.0.0.1:36901 protocol=28
time=2026-11-22T17:35:27.618Z level=INFO msg=connected host=127.0.0.1:36901 took=919µs
time=2026-11-22T17:35:27.618Z level=INFO msg="capabilities gathering"
time=2026-11-22T17:35:27.619Z level=INFO msg="capabilities gathered" took=397µs tags=linux,claude,go
time=2026-11-22T17:35:27.619Z level=INFO msg="hello sent" protocol=28
time=2026-11-22T17:35:27.623Z level=INFO msg=welcome protocol=28 role=primary generation=1
time=2026-11-22T17:35:28.530Z level=INFO msg="connection checked" connection=claude-1 state=healthy
    browser_receipts_test.go:169: waiting for [...document.querySelectorAll('[equipo-markdown]:not([data-stream-text])')].some(e=>e.textContent.includes("I'm your coordinator")): context deadline exceeded (last evaluation: context deadline exceeded)
--- FAIL: TestBrowserEmptyExplore (5.76s)
FAIL
rastrillo-budget/v1 ran 20.835s
FAIL	amadan.net/oficina/equipo/internal/headless	21.126s
FAIL
machine: 32 CPUs, load 35.45, cpu waiting 16.72%, memory waiting 0.00%, io waiting 0.42%
make: *** [Makefile:113: ci-shard] Error 1

amadan: step check shard 21 of 29 failed: exit status 2
--- 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)$' ./internal/equipo

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

receipt: test step 983ms against a 60s target (the gate's other steps are not in this figure)
receipt: 0 packages ran, 1 cached, 0 without tests, 0 failed
receipt: slow package 1.673s amadan.net/oficina/equipo/internal/idtest
receipt: slow test 1.67s 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 220ms against a 60s target (the gate's other steps are not in this figure)
receipt: 0 packages ran, 1 cached, 0 without tests, 0 failed
receipt: slow package 1.856s amadan.net/oficina/equipo/internal/plan3test
receipt: slow test 1.86s 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|TestBrowserPhoneIndex|TestBrowserPlacementQuestionAndPending|TestBrowserProjectPlacement|TestBrowserProjectsList|TestBrowserReportActionFeedback|TestBrowserReportNextSteps|TestBrowserReportThread|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 1.095s against a 60s target (the gate's other steps are not in this figure)
receipt: 0 packages ran, 1 cached, 0 without tests, 0 failed
receipt: slow package 3m20.199s amadan.net/oficina/equipo/internal/thintest
receipt: slow test 17.52s amadan.net/oficina/equipo/internal/thintest TestBrowserAccessRequest
receipt: slow test 14.35s amadan.net/oficina/equipo/internal/thintest TestBrowserSettingsTeams
receipt: slow test 12.02s amadan.net/oficina/equipo/internal/thintest TestBrowserThinkingCycles
receipt: slow test 10.55s amadan.net/oficina/equipo/internal/thintest TestBrowserPlacementQuestionAndPending
receipt: slow test 7.93s amadan.net/oficina/equipo/internal/thintest TestBrowserInnerScreens
machine: 32 CPUs, load 7.15, cpu waiting 1.90%, memory waiting 0.00%, io waiting 2.35%
--- 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   (55s)
ok ./internal/headless TestHeadlessConnections/A5_cancel_and_sign_out 5.50s
ok ./internal/headless TestHeadlessConnections/C4_claude_sign_in 1.43s
ok ./internal/headless TestHeadlessConnections/C5_engineering_failover 10.06s
ok ./internal/headless TestHeadlessConnections/C5_engineering_to_codex 10.86s
ok ./internal/headless TestHeadlessConnections/C5_engineering_waits 25.14s
+ 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   (76s)
ok ./internal/headless TestHeadlessConnections/C5_review_auth 22.28s
ok ./internal/headless TestHeadlessConnections/C5_review_failover 16.64s
ok ./internal/headless TestHeadlessConnections/C5_review_on_codex 21.29s
ok ./internal/headless TestHeadlessConnections/C5_review_other_family_first 13.93s
+ go test -tags testbuild -timeout 15m -v -run '^TestMixedVersions$' ./internal/headless   (23s)
ok ./internal/headless TestMixedVersions 21.51s
+ go test -tags testbuild -timeout 15m -v -run '^TestCheckSandboxDeniedPathsTampering$' ./internal/runner/checks   (1s)
ok ./internal/runner/checks TestCheckSandboxDeniedPathsTampering 0.77s
+ go test -tags testbuild -timeout 15m -v -run '^TestRunnerCancelAndSupersede$' ./internal/runner/thin   (0s)
ok ./internal/runner/thin TestRunnerCancelAndSupersede 0.05s
quarantine: 0 flaked (passed on the retry), 0 failed
machine: 32 CPUs, load 44.12, cpu waiting 24.18%, memory waiting 0.00%, io waiting 0.70%
--- 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 8.797s against a 60s target (the gate's other steps are not in this figure)
receipt: 4 packages ran, 0 cached, 3 without tests, 0 failed
receipt: slow package 7.614s amadan.net/oficina/equipo/internal/runner/checks
receipt: slow package 191ms amadan.net/oficina/equipo/internal/runner/provider/claude
receipt: slow package 93ms amadan.net/oficina/equipo/internal/runner/provider/codex
receipt: slow package 2ms amadan.net/oficina/equipo/internal/runner/provider
receipt: slow package 1ms amadan.net/oficina/equipo/internal/runner/provider/opencode
receipt: slow test 5.48s amadan.net/oficina/equipo/internal/runner/checks TestCheckSandboxDeniedPathsGoFixture
receipt: slow test 1.72s amadan.net/oficina/equipo/internal/runner/checks TestCheckSandboxDeniedPaths
receipt: slow test 320ms amadan.net/oficina/equipo/internal/runner/checks TestCheckSandboxDeniedPathsCache
receipt: slow test 190ms 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 EQUIPO_REQUIRE_USER_SESSION=1 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.569s 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 3.194s amadan.net/oficina/equipo/internal/runner/containment
receipt: slow test 370ms amadan.net/oficina/equipo/internal/runner/containment TestNamespaceReadOnlyScratch
receipt: slow test 210ms amadan.net/oficina/equipo/internal/runner/containment TestNamespaceRecoveryUnavailableProof
receipt: slow test 130ms amadan.net/oficina/equipo/internal/runner/containment TestNamespaceDirectPolicyAdmission
receipt: slow test 120ms amadan.net/oficina/equipo/internal/runner/containment TestNamespaceRecoveryReusedPID
receipt: slow test 120ms amadan.net/oficina/equipo/internal/runner/containment TestNamespaceRecoveryCleansScratch
machine: 32 CPUs, load 16.93, cpu waiting 5.04%, memory waiting 0.00%, io waiting 2.05%
--- 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 31.1%, load 24.43
shard 25: make runner-dead-references lanes-check build vet fmt-check budget migration-check
python3 scripts/runner-dead-references.py
reference scan: 2588 text files, 2854 matches, 0 failures
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 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.651s
machine: 32 CPUs, load 40.34, cpu waiting 21.52%, memory waiting 0.00%, io waiting 1.20%
--- 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 30.0%, load 24.43
shard 26: make staticcheck
go run honnef.co/go/tools/cmd/staticcheck@v0.7.0 -tags browser,perf,testbuild ./...
machine: 32 CPUs, load 31.20, cpu waiting 14.06%, memory waiting 0.00%, io waiting 1.47%
--- 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 30.0%, load 24.43
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 0 vulnerabilities in packages you import and 5
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 36.71, cpu waiting 17.01%, memory waiting 0.00%, io waiting 1.37%
--- 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 30.0%, load 24.43
shard 28: make gitleaks
5:34PM INF Unknown SCM platform. Use --platform to include links in findings. host=amadan.net
5:34PM INF 1120 commits scanned.
5:34PM INF scanned ~61698990 bytes (61.70 MB) in 14.8s
5:34PM INF no leaks found
machine: 32 CPUs, load 40.34, cpu waiting 21.52%, memory waiting 0.00%, io waiting 1.20%

amadan: job failed at step check shard 21 of 29 — its output is above, not at the tail of this log
diff --git a/docs/superpowers/plans/HOSTED-SLICE1-PROGRESS.md b/docs/superpowers/plans/HOSTED-SLICE1-PROGRESS.md
index 49464f74..0c6e01b6 100644
--- a/docs/superpowers/plans/HOSTED-SLICE1-PROGRESS.md
+++ b/docs/superpowers/plans/HOSTED-SLICE1-PROGRESS.md
@@ -385,7 +385,7 @@ Get, Stop with stop proof, unknown states and Refresh with restart reconciliatio
| M10 Ref-less proof without the 2-minute wait | `^TestStopIntentWithoutRef$` | `stop_test.go:411: proof {... "observed_at_ns":119999999999} from a list started under 2 minutes after the request` | yes, passes |
| M10b 2-minute wait measured from the list's end | `^TestStopIntentWithoutRef$` | same line as M10 | yes, passes |
| M11 Ref-less proof from an incomplete list | `^TestStopIntentWithoutRef$` | `stop_test.go:381: proof {...} from an incomplete list` | yes, passes |
-| M12 Ref-less check counts only live (not unknown) VMs | `^TestStopIntentWithoutRef$` | survives: the fake's List never reports `unknown` (FaultUnknownState is Get-only) | n/a |
+| M12 Ref-less check counts only live (not unknown) VMs | `^TestStopIntentWithoutRef$` | unreachable: the fake's List never reports `unknown` (FaultUnknownState is Get-only), so no test can tell the two checks apart; the code keeps the stricter non-terminal check | n/a |
| M13 re-base not once per process | `^TestRestartStopsWhenElapsedUnknown$` | `stop_test.go:633: provider stops = [vm-0001 vm-0001 vm-0002], want only vm-0001` | yes, passes |
| M14 pre-restart boundary `<` OpenedAt | `^TestRestartJobAtOpenTime$` | `stop_test.go:668: job launched at OpenedAt with no age: reason { false}, want elapsed_unknown` | yes, passes |
| M15 Refresh does not send the stop again | `^TestLostStopReplyRetries$` | `stop_test.go:306: provider stops after Refresh = [vm-0001], want a second one` | yes, passes |
@@ -393,3 +393,20 @@ Get, Stop with stop proof, unknown states and Refresh with restart reconciliatio
| M17 a VM that ended while down gets no reason `ended` | `^TestRestartFindsVMGone$` | `stop_test.go:496: att-a after Refresh: state "stopped" reason { false} requested {0 false}; want stopped, ended, no request` | yes, passes |
| M18 Stop does not abandon a waiting intent | `^TestStopIntentWithoutRef$` | `stop_test.go:354: after Stop: state "waiting" requested {60000000000 true} proof { false}; want abandoned at 60000000000, no proof` | yes, passes |
| M19 saving proof rewrites `stop_t` | `^TestStopProofNeedsTerminalState$` | `stop_test.go:211: after proof: state "stopped" reason {task done true} stop_t 0 ...; want ... times 6600000000000 7200000000000 unchanged` | yes, passes |
+
+### Task 11, controller ruling R17: confirm a missing VM twice
+
+GetMicrovm is eventually consistent, so one not-found is no longer proof. New nullable column `jobs.notfound_since_t` in `schema/0001_jobs.sql` (nothing released). `NotFoundConfirm = 60 * time.Second` (stop.go; equals Task 13's ReapInterval). Stop and Refresh share `notFound`: a not-found proves the VM gone only when `notfound_since_t` holds an earlier not-found that came after the stop request (if any) and is at least NotFoundConfirm before this Get began; otherwise the first not-found is recorded (audit `vm_not_found`) and the result is ErrStopPending. Any live Get clears it (`mirrorState`). A terminal state is still proof at once. The Ref-less path uses List, never a Get not-found, so it is unchanged. The M16 row above is superseded by N1 to N6; line numbers in the rows above are as of 9202c3d2.
+
+- RED (constant only, old behaviour): `stop_test.go:332: Stop on the first not-found = <nil>, want ErrStopPending`, `stop_test.go:388: after one not-found: proof {...} notfound_since_t {0 false}; want no proof and a since time`, `stop_test.go:578: att-a after one not-found: proof {...}; want no proof yet`.
+- GREEN: `go test ./internal/hostedctl -run 'TestStop|TestUnknownState|TestLostStop|TestRestart' -count=1` ok 3.0 s; whole package ok 3.7 s; the new tests once under `-race`: ok.
+
+| Mutation | Test | Observed failure | Restored |
+| --- | --- | --- | --- |
+| N1 accept a single not-found | `^TestStopNotFoundThenRunning$` | `stop_test.go:388: after one not-found: proof {{"attempt_id":"att-1",...,"state":"stopped",...} true} notfound_since_t {0 false}; want no proof and a since time` | yes, passes |
+| N1b same mutation | `^(TestStopOfGoneVMSucceeds\|TestRestartFindsVMGone)$` | `stop_test.go:332: Stop on the first not-found = <nil>, want ErrStopPending` and `stop_test.go:578: att-a after one not-found: proof {...}; want no proof yet` | yes, passes |
+| N2 a live Get does not clear `notfound_since_t` | `^TestStopNotFoundThenRunning$` | `stop_test.go:393: after a running Get: state "running" proof { false} notfound_since_t {0 true}; want running, no proof, since cleared` | yes, passes |
+| N3 a not-found from before the stop request counts | `^TestStopNotFoundThenRunning$` | `stop_test.go:414: Stop on a not-found with the earlier one before the request = <nil>, want ErrStopPending` | yes, passes |
+| N4 boundary `>` NotFoundConfirm | `^TestStopOfGoneVMSucceeds$` | `stop_test.go:353: Stop on a not-found 1m0s after the first = (..., ... VM vm-0001 not found once; proof needs a second not-found 1m0s later), want {... State:stopped ObservedAt:120000000000}` | yes, passes |
+| N5 gap measured to the second Get's end | `^TestStopOfGoneVMSucceeds$` | `stop_test.go:342: Stop on a second not-found under 1m0s later = <nil>, want ErrStopPending` | yes, passes |
+| N6 every not-found restarts the wait | `^TestStopOfGoneVMSucceeds$` | `stop_test.go:345: notfound_since_t moved to 119999999999 on a second not-found, want 60000000000 kept` | yes, passes |
diff --git a/internal/hostedctl/refresh.go b/internal/hostedctl/refresh.go
index 1c47d654..94584733 100644
--- a/internal/hostedctl/refresh.go
+++ b/internal/hostedctl/refresh.go
@@ -45,9 +45,11 @@ func (s *rebasedSet) add(attempt string) {
//
// Every job with a VM Ref and no proof is read with Runner.Get:
//
-// - a terminal state, or isolatedjob.ErrNotFound, is proof and is saved.
-// A job with no stop request ended on its own and gets the stop reason
-// "ended", so replacements may go ahead;
+// - a terminal state is proof and is saved. isolatedjob.ErrNotFound is
+// proof only when confirmed by a second not-found NotFoundConfirm later
+// with no live Get between (see notFound); the first is recorded and the
+// job left pending. A job with no stop request ended on its own and gets
+// the stop reason "ended", so replacements may go ahead;
// - after a restart, a job launched at or before Store.OpenedAt has an
// untrusted elapsed time (the wall delta Open used says nothing about
// the real downtime). Once per process, with a provider age, its
@@ -138,8 +140,7 @@ func (c *Controller) refreshOne(ctx context.Context, attempt string) error {
rec := context.WithoutCancel(ctx)
switch {
case errors.Is(gerr, isolatedjob.ErrNotFound):
- _, err := c.recordProof(rec, "", attempt, StopProof{AttemptID: attempt, VMRef: ref,
- State: isolatedjob.StateStopped, ObservedAt: at}, "refresh: provider holds no such VM")
+ _, _, err := c.notFound(rec, "", attempt, ref, before, at, "refresh: provider holds no such VM")
return err
case gerr != nil:
return fmt.Errorf("hostedctl: refresh %s: read VM %s: %w", attempt, ref, gerr)
diff --git a/internal/hostedctl/schema/0001_jobs.sql b/internal/hostedctl/schema/0001_jobs.sql
index 09aaafbc..71104f75 100644
--- a/internal/hostedctl/schema/0001_jobs.sql
+++ b/internal/hostedctl/schema/0001_jobs.sql
@@ -28,6 +28,7 @@ CREATE TABLE jobs (
stop_requested_t INTEGER, -- absent until a stop is asked for
stop_reason TEXT,
stop_proof_json TEXT, -- absent until a stop is proven
+ notfound_since_t INTEGER, -- first not-found from Get since the VM was last seen live; absent otherwise
revision INTEGER NOT NULL DEFAULT 0
);
diff --git a/internal/hostedctl/stop.go b/internal/hostedctl/stop.go
index 14e972b9..edc73eda 100644
--- a/internal/hostedctl/stop.go
+++ b/internal/hostedctl/stop.go
@@ -14,14 +14,21 @@ import (
var (
// ErrStopPending: the stop is recorded but the VM is not proven stopped
- // yet: it is still live, or the job has no VM Ref and the provider has
- // not yet been seen to hold no VM for it. Ask again later.
+ // yet: it is still live, the provider has answered not-found only once
+ // (NotFoundConfirm), or the job has no VM Ref and the provider has not
+ // yet been seen to hold no VM for it. Ask again later.
ErrStopPending = errors.New("hostedctl: stop asked for; the VM is not proven stopped yet")
// ErrStateUnknown: the provider reported a state this package does not
// know. It is never proof that the VM has stopped.
ErrStateUnknown = errors.New("hostedctl: the provider reports an unknown VM state; no stop proof")
)
+// NotFoundConfirm is how far apart, in controller time, two not-found
+// answers from Runner.Get must be before they prove a VM gone. The
+// provider's Get is eventually consistent, so one not-found proves nothing
+// (ruling R17). It equals the reaper's interval (Task 13's ReapInterval).
+const NotFoundConfirm = 60 * time.Second
+
// Stop reasons the controller writes itself.
const (
// reasonElapsedUnknown: after a restart the provider gave no age for the
@@ -41,11 +48,14 @@ const (
actionStopFailed = "stop_failed"
actionStopStateUnknown = "stop_state_unknown"
actionStopProven = "stop_proven"
+ actionVMNotFound = "vm_not_found"
actionRestartRebased = "restart_rebased"
)
-// StopProof says the provider reported the job's VM terminal, or held no
-// such VM once the stop was asked for. It gates replacement attempts.
+// StopProof says the provider reported the job's VM terminal, or answered
+// not-found twice, NotFoundConfirm apart, with the first after the stop
+// request (or, with no request, after the VM was last seen live). It gates
+// replacement attempts.
// VMRef is empty for a job that never had a Ref, and State is then
// isolatedjob.StateStopped. ObservedAt is controller time.
type StopProof struct {
@@ -134,8 +144,12 @@ func (c *Controller) Get(ctx context.Context, by hostedwire.KeyID, attemptID str
// such VM. Otherwise, outside any transaction, Runner.Stop and then
// Runner.Get:
//
-// - a terminal state, or isolatedjob.ErrNotFound from Get, is proof: it
-// is saved with state JobStopped in one transaction and returned;
+// - a terminal state is proof: it is saved with state JobStopped in one
+// transaction and returned;
+// - isolatedjob.ErrNotFound from Get is proof only when an earlier
+// not-found, recorded after the stop request, is at least
+// NotFoundConfirm older than this Get; otherwise the first one is
+// recorded in notfound_since_t and the result is ErrStopPending;
// - a live state (stopping included) gives ErrStopPending;
// - an unknown state gives ErrStateUnknown;
// - an error from Runner.Stop (a lost reply, a throttle) is returned. The
@@ -263,14 +277,18 @@ func (c *Controller) driveStop(ctx context.Context, actor hostedwire.KeyID, r st
"provider stop call failed; it is sent again on the next stop or refresh")
return StopProof{}, errors.Join(fmt.Errorf("hostedctl: stop %s: %w", r.attempt, perr), aerr)
}
+ before := c.store.Clock().Now()
job, gerr := c.runner.Get(ctx, r.ref)
at := c.store.Clock().Now()
// Record what the provider said even if the caller has gone.
rec := context.WithoutCancel(ctx)
switch {
case errors.Is(gerr, isolatedjob.ErrNotFound):
- return c.recordProof(rec, actor, r.attempt, StopProof{AttemptID: r.attempt, VMRef: r.ref,
- State: isolatedjob.StateStopped, ObservedAt: at}, "provider holds no such VM after the stop request")
+ p, proven, err := c.notFound(rec, actor, r.attempt, r.ref, before, at, "provider holds no such VM after the stop request")
+ if err != nil || proven {
+ return p, err
+ }
+ return StopProof{}, fmt.Errorf("%w: VM %s not found once; proof needs a second not-found %v later", ErrStopPending, r.ref, NotFoundConfirm)
case gerr != nil:
return StopProof{}, fmt.Errorf("hostedctl: read VM %s of %s after stop: %w", r.ref, r.attempt, gerr)
case job.State.Terminal():
@@ -294,6 +312,62 @@ func (c *Controller) auditStop(ctx context.Context, actor hostedwire.KeyID, r st
})
}
+// notFound handles a not-found answer from Runner.Get for attempt's VM ref,
+// read between controller times before and at. The answer is proof only
+// when notfound_since_t holds an earlier not-found that came after the stop
+// request (if any) and is at least NotFoundConfirm before this Get began;
+// any live Get in between has cleared it (mirrorState). Otherwise, when no
+// such first not-found is held, at is recorded as the first one. proven
+// reports whether p is proof; a job that already holds proof returns it.
+func (c *Controller) notFound(ctx context.Context, actor hostedwire.KeyID, attempt string, ref isolatedjob.Ref, before, at T, why string) (StopProof, bool, error) {
+ var out StopProof
+ proven := false
+ err := c.store.Tx(ctx, func(tx *sql.Tx) error {
+ out, proven = StopProof{}, false
+ j, found, err := loadJob(ctx, tx, attempt)
+ if err != nil {
+ return err
+ }
+ switch {
+ case !found:
+ return fmt.Errorf("hostedctl: not-found for %s: job is missing", attempt)
+ case j.stopProof.Valid:
+ out, err = decodeProof(j.stopProof.String, attempt)
+ proven = err == nil
+ return err
+ case !j.ref.Valid || isolatedjob.Ref(j.ref.String) != ref:
+ return fmt.Errorf("hostedctl: not-found for %s names VM %s, the job holds %q", attempt, ref, j.ref.String)
+ }
+ var since sql.NullInt64
+ if err := tx.QueryRowContext(ctx, `SELECT notfound_since_t FROM jobs WHERE attempt_id = ?`, attempt).Scan(&since); err != nil {
+ return fmt.Errorf("hostedctl: read notfound_since_t of %s: %w", attempt, err)
+ }
+ first := since.Valid && (!j.stopRequested.Valid || since.Int64 >= j.stopRequested.Int64)
+ if first && before-T(since.Int64) >= T(NotFoundConfirm) {
+ out, proven = StopProof{AttemptID: attempt, VMRef: ref, State: isolatedjob.StateStopped, ObservedAt: at}, true
+ return writeProof(ctx, tx, actor, j, out, fmt.Sprintf("%s; not found twice, %v apart",
+ why, time.Duration(before-T(since.Int64))))
+ }
+ if first {
+ return nil // waiting for the confirming not-found
+ }
+ res, err := tx.ExecContext(ctx, `UPDATE jobs SET notfound_since_t = ?, revision = revision + 1
+ WHERE attempt_id = ? AND stop_proof_json IS NULL`, int64(at), attempt)
+ if err != nil {
+ return fmt.Errorf("hostedctl: record not-found for %s: %w", attempt, err)
+ }
+ if n, err := res.RowsAffected(); err != nil || n != 1 {
+ return fmt.Errorf("hostedctl: record not-found for %s: %d rows (%v)", attempt, n, err)
+ }
+ return appendAudit(tx, Audit{Actor: actor, Account: j.account, Task: j.task, Attempt: attempt, Action: actionVMNotFound,
+ Reason: fmt.Sprintf("%s; proof waits for a second not-found %v later", why, NotFoundConfirm), At: at})
+ })
+ if err != nil {
+ return StopProof{}, false, err
+ }
+ return out, proven, nil
+}
+
// recordProof saves p for a job with a VM Ref in one transaction, with the
// job's state set to JobStopped, and returns it. A job that already holds
// proof keeps it and returns that one. A job with no stop request ended on
@@ -348,11 +422,13 @@ func writeProof(ctx context.Context, tx *sql.Tx, actor hostedwire.KeyID, j jobRo
}
// mirrorState saves a live VM state the provider reported as the job's
-// state, unless the job holds proof.
+// state, unless the job holds proof. A live VM was seen, so any first
+// not-found held in notfound_since_t no longer counts and is cleared.
func (c *Controller) mirrorState(ctx context.Context, attempt string, st isolatedjob.State) error {
return c.store.Tx(ctx, func(tx *sql.Tx) error {
- _, err := tx.ExecContext(ctx, `UPDATE jobs SET state = ?, revision = revision + 1
- WHERE attempt_id = ? AND vm_ref IS NOT NULL AND stop_proof_json IS NULL AND state <> ?`,
+ _, err := tx.ExecContext(ctx, `UPDATE jobs SET state = ?, notfound_since_t = NULL, revision = revision + 1
+ WHERE attempt_id = ? AND vm_ref IS NOT NULL AND stop_proof_json IS NULL
+ AND (state <> ? OR notfound_since_t IS NOT NULL)`,
string(st), attempt, string(st))
if err != nil {
return fmt.Errorf("hostedctl: save state of %s: %w", attempt, err)
diff --git a/internal/hostedctl/stop_test.go b/internal/hostedctl/stop_test.go
index 7fccc5ae..d3ab510b 100644
--- a/internal/hostedctl/stop_test.go
+++ b/internal/hostedctl/stop_test.go
@@ -5,6 +5,7 @@ import (
"database/sql"
"encoding/json"
"errors"
+ "fmt"
"slices"
"strings"
"testing"
@@ -17,7 +18,7 @@ import (
// stopCols are the jobs columns stop and refresh write.
type stopCols struct {
state string
- requested sql.NullInt64
+ requested, notFoundSince sql.NullInt64
reason, proof sql.NullString
launched, deadline, drain, stop int64
}
@@ -26,9 +27,9 @@ func (e *launchEnv) stopCols(attempt string) stopCols {
e.t.Helper()
var s stopCols
if err := e.store.Tx(e.ctx, func(tx *sql.Tx) error {
- return tx.QueryRowContext(e.ctx, `SELECT state, stop_requested_t, stop_reason, stop_proof_json,
+ return tx.QueryRowContext(e.ctx, `SELECT state, stop_requested_t, notfound_since_t, stop_reason, stop_proof_json,
launched_t, deadline_t, drain_t, stop_t FROM jobs WHERE attempt_id = ?`, attempt).Scan(
- &s.state, &s.requested, &s.reason, &s.proof, &s.launched, &s.deadline, &s.drain, &s.stop)
+ &s.state, &s.requested, &s.notFoundSince, &s.reason, &s.proof, &s.launched, &s.deadline, &s.drain, &s.stop)
}); err != nil {
e.t.Fatalf("read stop columns of %s = %v", attempt, err)
}
@@ -323,18 +324,105 @@ func TestStopOfGoneVMSucceeds(t *testing.T) {
ref := e.launchWith("att-1", 2*time.Hour)
e.fake.Tick()
e.fake.Vanish(ref)
+
+ // The provider's Get is eventually consistent: one not-found is no proof.
e.clk.AdvanceMono(time.Minute)
+ first := e.store.Clock().Now()
+ if _, err := e.c.Stop(e.ctx, "inst-1", instKey, "att-1", "task done"); !errors.Is(err, ErrStopPending) {
+ t.Fatalf("Stop on the first not-found = %v, want ErrStopPending", err)
+ }
+ if s := e.stopCols("att-1"); s.proof.Valid || !s.notFoundSince.Valid || T(s.notFoundSince.Int64) != first {
+ t.Fatalf("after one not-found: proof %v notfound_since_t %v; want no proof, since %d", s.proof, s.notFoundSince, first)
+ }
+ if err := e.replace("att-2", "att-1"); !errors.Is(err, ErrReplacementLive) {
+ t.Fatalf("replacement after one not-found = %v, want ErrReplacementLive", err)
+ }
+ e.clk.AdvanceMono(NotFoundConfirm - time.Nanosecond)
+ if _, err := e.c.Stop(e.ctx, "inst-1", instKey, "att-1", "task done"); !errors.Is(err, ErrStopPending) {
+ t.Fatalf("Stop on a second not-found under %v later = %v, want ErrStopPending", NotFoundConfirm, err)
+ }
+ if s := e.stopCols("att-1"); T(s.notFoundSince.Int64) != first {
+ t.Fatalf("notfound_since_t moved to %d on a second not-found, want %d kept", s.notFoundSince.Int64, first)
+ }
+
+ e.clk.AdvanceMono(time.Nanosecond)
at := e.store.Clock().Now()
p, err := e.c.Stop(e.ctx, "inst-1", instKey, "att-1", "task done")
want := StopProof{AttemptID: "att-1", VMRef: ref, State: isolatedjob.StateStopped, ObservedAt: at}
if err != nil || p != want {
- t.Fatalf("Stop of a VM the provider no longer holds = (%+v, %v), want %+v", p, err, want)
+ t.Fatalf("Stop on a not-found %v after the first = (%+v, %v), want %+v", NotFoundConfirm, p, err, want)
}
+ e.audit()
if err := e.replace("att-2", "att-1"); err != nil {
t.Fatalf("replacement after proof = %v", err)
}
}
+// notFoundOnce wraps the fake provider; its next n Gets answer not-found
+// whatever the VM's state, as an eventually consistent provider can.
+type notFoundOnce struct {
+ *isolatedjob.Fake
+ n int
+}
+
+func (p *notFoundOnce) Get(ctx context.Context, ref isolatedjob.Ref) (isolatedjob.Job, error) {
+ if p.n > 0 {
+ p.n--
+ return isolatedjob.Job{}, fmt.Errorf("%w: %s (stale read)", isolatedjob.ErrNotFound, ref)
+ }
+ return p.Fake.Get(ctx, ref)
+}
+
+func TestStopNotFoundThenRunning(t *testing.T) {
+ e := newLaunchEnv(t)
+ flaky := &notFoundOnce{Fake: e.fake}
+ e.run = flaky
+ e.newController()
+ e.audit()
+ e.launchWith("att-1", 2*time.Hour)
+ e.fake.Tick()
+
+ flaky.n = 1
+ e.refresh()
+ if s := e.stopCols("att-1"); s.proof.Valid || !s.notFoundSince.Valid {
+ t.Fatalf("after one not-found: proof %v notfound_since_t %v; want no proof and a since time", s.proof, s.notFoundSince)
+ }
+ e.clk.AdvanceMono(NotFoundConfirm)
+ e.refresh() // the VM shows running
+ if s := e.stopCols("att-1"); s.proof.Valid || s.notFoundSince.Valid || s.state != JobRunning {
+ t.Fatalf("after a running Get: state %q proof %v notfound_since_t %v; want running, no proof, since cleared",
+ s.state, s.proof, s.notFoundSince)
+ }
+
+ // A new not-found starts a new wait; the one before the running Get no
+ // longer counts.
+ e.clk.AdvanceMono(time.Minute)
+ flaky.n = 1
+ e.refresh()
+ e.clk.AdvanceMono(NotFoundConfirm / 2)
+ flaky.n = 1
+ e.refresh()
+ if s := e.stopCols("att-1"); s.proof.Valid {
+ t.Fatalf("proof %s from not-founds %v apart", s.proof.String, NotFoundConfirm/2)
+ }
+
+ // After a stop request, a not-found from before it does not count.
+ e.clk.AdvanceMono(NotFoundConfirm)
+ asked := e.store.Clock().Now()
+ flaky.n = 1
+ if _, err := e.c.Stop(e.ctx, "inst-1", instKey, "att-1", "task done"); !errors.Is(err, ErrStopPending) {
+ t.Fatalf("Stop on a not-found with the earlier one before the request = %v, want ErrStopPending", err)
+ }
+ if s := e.stopCols("att-1"); s.proof.Valid || T(s.notFoundSince.Int64) != asked {
+ t.Fatalf("after Stop: proof %v notfound_since_t %v; want no proof, since %d", s.proof, s.notFoundSince, asked)
+ }
+ e.clk.AdvanceMono(NotFoundConfirm)
+ flaky.n = 1
+ if p, err := e.c.Stop(e.ctx, "inst-1", instKey, "att-1", "task done"); err != nil || p.State != isolatedjob.StateStopped {
+ t.Fatalf("Stop on a second not-found after the request = (%+v, %v), want proof", p, err)
+ }
+}
+
func TestStopIntentWithoutRef(t *testing.T) {
t.Run("lost launch reply left a VM", func(t *testing.T) {
e := newLaunchEnv(t)
@@ -483,6 +571,17 @@ func TestRestartFindsVMGone(t *testing.T) {
e.clk.SetWall(testWall.Add(2 * time.Hour))
e.up()
+ e.refresh()
+ // B is terminal: proof at once. A is only not found: it waits for a
+ // second not-found NotFoundConfirm later.
+ if s := e.stopCols("att-a"); s.proof.Valid || !s.notFoundSince.Valid {
+ t.Fatalf("att-a after one not-found: proof %v notfound_since_t %v; want no proof yet", s.proof, s.notFoundSince)
+ }
+ e.audit()
+ if err := e.replace("att-a2", "att-a"); !errors.Is(err, ErrReplacementLive) {
+ t.Fatalf("replacement after one not-found = %v, want ErrReplacementLive", err)
+ }
+ e.clk.AdvanceMono(NotFoundConfirm)
e.refresh()
for _, c := range []struct {
attempt string
@@ -500,7 +599,6 @@ func TestRestartFindsVMGone(t *testing.T) {
if got := e.fake.StopsIssued(); len(got) != 0 {
t.Fatalf("Refresh stopped %v; both VMs had already ended", got)
}
- e.audit()
if err := e.replace("att-a2", "att-a"); err != nil {
t.Fatalf("replacement of a VM that ended while the controller was down = %v", err)
}