Skip to content

Cloud: update outdated machines before opening no-folder chats - #31145

Merged
teamleaderleo merged 1 commit into
feat-cmux-nextfrom
lane/cloud-home-start-update
Nov 1, 2026
Merged

teamleaderleo merged 1 commit into
feat-cmux-nextfrom
lane/cloud-home-start-update

Conversation

@teamleaderleo

Copy link
Copy Markdown
Collaborator

Leo asked for no-project Cloud chats to start immediately: “I want us to be able to do this too.”

When a Cloud chat had no folder and its selected machine was running an older cmux-tui, startup attempted to open the chat tab before updating the machine. The daemon lacked agent-session-tabs-v1, so the start failed with the existing unsupported-machine refusal.

This change reuses the package-level Cloud outdated-machine relink wait before opening a chat tab. If the machine does not advertise the capability, Cloud updates it, waits up to 90 seconds for the new handshake, and then lets the existing tab-opening path re-anchor and perform its normal capability check. Folder and no-folder starts share this path. If the update cannot complete or times out, the existing refusal remains. Package tests cover update-and-capability arrival, bounded relink timeout, and already-current machines.

Validation: python3 scripts/cmux-next/prepush-gate.py

agent-identity footer --repo manaflow-ai/cmux
Agent session: agent session

@github-actions

github-actions Bot commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

cmux status (one comment, edited in place; each line is updated by the job that owns it)

Review a4acbac: HQ feed card · gallery before/after runs · checks

App of this head (app.zip, kept 1 day)

gh workflow run reload-build.yml -R manaflow-ai/cmux --ref feat-cmux-next -f tag=pr31145 -f ref=lane/cloud-home-start-update -f platform=macos -f backend_mode=local

red: cmux-next checks (god files, concurrency, crash safety, l10n); no finished base run on 4d50df9 to compare; do not merge until green; see lane-rules

Shipped in:

The feat-cmux-next push run https://github.com/manaflow-ai/cmux/actions/runs/41330433296 at e0fa06f failed: cmux-next crash ends the app.
Those jobs last passed at 45b916e. This pull request is one of 5 merged since: #31133, #30400, #31145, #31066, #31069.
If the failure is in your change, fix forward on feat-cmux-next. Pull requests run only the tiers their paths reach (docs/ci/cmux-next-tiers.md); label a batch PR full-ci to run them all before merging.

@github-actions github-actions Bot added the risk:normal Risk tier (docs/ci/risk-tiers.md) label Nov 1, 2026
@blacksmith-sh

blacksmith-sh Bot commented Nov 1, 2026

Copy link
Copy Markdown

Found 6 test failures on Blacksmith runners:

Failures

Test View Logs
/tmp/tmp9ab1xbxk/summary-missing.json (live):/summary-missing.json (live): View Logs
/tmp/tmpt_9oeiph/summary-fail.json (live):/summary-fail.json (live): View Logs
[new_workspaces] debug.new_workspace timed 0 of 50 new workspace rows/
[new_workspaces] debug.new_workspace timed 0 of 50 new workspace rows
View Logs
[new_workspaces] the window draws no frames/[new_workspaces] the window draws no frames View Logs
[tabs] debug.tab_switch timed 0 of 40 switches/
[tabs] debug.tab_switch timed 0 of 40 switches
View Logs
[tabs] the window draws no frames/[tabs] the window draws no frames View Logs

Fix with [code]smith
Need help on this PR? Tag @codesmith-bot with what you need.

@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Review (subagent claude-opus-5-5 medium): SHIP at a4acbac

The fix works: open() updates the machine and waits for the relink (CloudWait.holds, a 90 s deadline, Observation rather than a poll) before it re-anchors and opens the tab. This covers both start paths. It composes with #31087 without a double update. An already-current machine skips the update, and a timeout refuses as before. No as!, try! or force unwraps.

Follow-ups:

  • CmuxNextApp +4 lines in CloudStartChat.swift: take the delta to zero.
  • An unreachable (disconnected) machine now waits up to 90 s for an update before the same refusal. Skip the update unless it is connected and its handshake lacks the capability.
  • Tests: add a relink that arrives after update returns, and an update that returns false.
  • The updateNow log text is wrong for the pre-emptive update.

@teamleaderleo
teamleaderleo merged commit ba2bb4a into feat-cmux-next Nov 1, 2026
137 of 142 checks passed
@teamleaderleo
teamleaderleo deleted the lane/cloud-home-start-update branch November 1, 2026 17:10
cmux-bot Bot pushed a commit that referenced this pull request Nov 1, 2026
…1147, #31145) (#31182)

arch-ratchet at the feat tip 2aaed54: [app_lines] CmuxNextApp +5, from #31147 (AgentTabRemoteHost.swift) on top of
#31145's +4. HandshakeFollower and its Handshake and Snapshot types hold only value logic and no app state; they move
from CmuxNextApp/Cloud/CloudMachineUpdates.swift to CmuxNextCloud/Link/HandshakeFollower.swift, and their four tests
move to CmuxNextCloudTests. No behavior change; the app calls the same API.

(cherry picked from commit 1d78bf5; prepared earlier today, fleet compile 10238882589a and suites 0a0c418e4823 green at its first base)
teamleaderleo added a commit that referenced this pull request Nov 2, 2026
…ability itself (#31995)

The no-folder start's update-before-open (#31145) waited only for the
machine's link to change. A new link can come up before its handshake
carries agent-session-tabs-v1, so the open was refused although the
update had worked: a DEV capture at a799d97 failed its first start with
"cannot hold agent chat tabs yet" and the next send's retry succeeded.
Wait, bounded by the same 90 s, for the capability.


Agent-Session: https://cmux.com/deeplink/agent?id=aid-b3ddf8ea0a5ba6fad749

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>

This branch was previously deployed

1 inactive deployment
ci-routing-agent — a4acbaca Deployed Nov 1, 2026 by teamleaderleo via namespace autofix #11465
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

risk:normal Risk tier (docs/ci/risk-tiers.md)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant