Repository navigation
Cloud cap card: Pause frees a slot (CloudDO pause on the app-server link; classic Pause only where it frees room) - #32866
Conversation
…assic offers Pause only where it frees room
cmux#32708: the app-server link's Pause (the cap card's and the sidebar's) sent the classic /api/vm/{id}/pause,
which cannot pause a CloudDO machine. It now sends cloud.machine.pause (and Resume cloud.machine.start) through
the app server. CloudDO answers once the provider paused it, so the slot is free when the create goes again; a
pause longer than its wait (mutation.indeterminate) is asked again with the same key, at most 3 times.
cmux#32710: the classic allowance counts paused machines (web/services/vms/repository.ts), so a Pause there frees
nothing. The classic card offers Pause only for the vCPU/memory pool refusal (vm_resource_pool_exceeded), which
counts running machines alone; the allowance refusal keeps Upgrade and Run on This Mac.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Agent-Session: https://cmux.com/deeplink/agent?id=aid-3bab30503f0b9a7059e5
|
cmux status (one comment, edited in place; each line is updated by the job that owns it) Review App of this head (app.zip, kept 1 day)
web and size checks: green Shipped in:
|
|
Owned by an agent session · session |
|
Found 7 test failures on Blacksmith runners: Failures
|
|
Review (codex, router-review): SHIP at 13b0385 Reviewer: codex gpt-6.1-sol xhigh, fast tier. Follow-ups: 1. Each lands as an issue in this repo that links this receipt; the lane that opened the PR fixes it forward. SHIP at 13b0385
No correctness findings. Swift tests could not run because this box lacks a Swift toolchain. Follow-ups:
|
…ncy gate) Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Agent-Session: https://cmux.com/deeplink/agent?id=aid-3bab30503f0b9a7059e5
|
Review (codex, router-review): SHIP at a1ab06d Reviewer: codex gpt-6.1-sol xhigh, fast tier. Follow-ups: 1. Each lands as an issue in this repo that links this receipt; the lane that opened the PR fixes it forward. SHIP at a1ab06d No correctness regressions found in backend contracts, error handling, or retry paths. Swift tests could not run: no Swift toolchain is installed.
Follow-ups:
|
|
HQ brief 09 follow-up, checked against |
![Fix with [code]smith](https://pr-comments-assets.blacksmith.sh/codesmith/fix-with-codesmith-light-3x.png)
Leo, on a Cloud create past the plan's machine cap: "you try to create a new workspace/machine past the cap, what do we wanna do? reuse exisitng or ask upgrade or". The card #32679 shipped (Pause one / Upgrade / Run on This Mac) has two gaps; this fixes both. Fixes #32708, fixes #32710.
#32708, app-server link. The cap card's Pause, and the sidebar's Pause and Resume, called the classic
/api/vm/{id}/pause, which cannot pause a CloudDO machine. On the app-server linkCloudService.pauseMachine/resumeMachinenow sendcloud.machine.pause/cloud.machine.startthrough the app server (CloudMachinePower, CmuxNextCloud). CloudDO already answers a person's pause only once the provider call landed (CloudCoresubmitAs, its 25 s wait), so the slot is free when the card's create goes again. A pause longer than that wait answersmutation.indeterminate; it is asked again with the same key (it joins the call in flight), at most 3 times. No backend change is needed: the Mac relay's install may pause without an approval (cmux-platformdomain/Cloud.tsauthorize), and the Rust app server already declaresmutation.indeterminatefor pause.#32710, classic link. The classic allowance counts paused machines (
web/services/vms/repository.tsactiveLimitExceededInTx,LIVE_VM_RESOURCE_STATUSES), so a Pause there frees nothing. The classic card now offers Pause only for the shared vCPU/memory pool refusal (vm_resource_pool_exceeded,activePoolUsagecounts provisioning and running only), mapped to a newCloudUpgradeReason.pool; the allowance refusal and the local plan gate keep Upgrade and Run on This Mac. Classic's backend is untouched.CmuxNextApp lines do not rise (in-place edits only).
Tests:
CloudMachineCapTests(the classic card offers Pause only where pausing frees room; the app-server pause sendscloud.machine.pausewith one key and origin user, retriesindeterminateup to 3 calls, stops at once on any other error),CloudCreateWithoutAskingTests(a 402vm_resource_pool_exceededthrows.pool).Design: leo-workspace design/cloud.md, "At the machine cap".
Agent session: agent session
🤖 Generated with Claude Code
Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.Summary by cubic
Fixes two gaps in the Cloud cap card's Pause so that pausing actually frees a slot before the create retries (cmux#32708, cmux#32710).
Bug Fixes
cloud.machine.pause/cloud.machine.startthrough the app server, since the classic/api/vmcannot pause a CloudDO machine.mutation.indeterminateand is retried with the same key, up to 3 times.vm_resource_pool_exceeded), which counts running machines alone; the allowance counts paused machines, so its refusal keeps Upgrade and Run on This Mac.Written for commit a1ab06d. Summary will update on new commits.