Skip to content

test(cloud): follow the Coderouter section and the Cloud sheet wrapper - #17448

Merged
teamleaderleo merged 1 commit into
mainfrom
fix/cloud-test-drift-1c84
Oct 5, 2026
Merged

teamleaderleo merged 1 commit into
mainfrom
fix/cloud-test-drift-1c84

Conversation

@teamleaderleo

@teamleaderleo teamleaderleo commented Oct 5, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Main's full CI at 1c84448 (run 37374680247) failed app-host shards 1, 2 and 7 on test drift. The window crash loop that #17433 fixed had been hiding these failures.

The other failures in that run were flakes or infra and are left alone:

  • shard 4 hung in xcresult accounting
  • shard 5 and the timing tests timed out under memory pressure
  • workflow-guard-history checkout hung, which then failed linux-preflight and release-admission

FileExplorerOpenedTabDragSourceTests.swift:251 failed once in shard 1. I'll recheck it on this PR's run.

Testing

  • The failing tests already exist on main and are red in run 37374680247; this PR changes only those tests (plus the one visibility change).
  • No local Swift build (this Mac is barred from Swift builds). This PR's CI runs the changed suites.

Resource check

None: test expectations and one visibility change.

Changelog

none

🤖 Generated with Claude Code


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


Summary by cubic

Fixes cloud test drift that main's CI caught at 1c84448, which the window crash-loop fix in #17433 had been hiding.

  • Updates tree tests so exact IDs and counts include the Coderouter section that feat: add Coderouter section to Cloud sidebar #17233 now always appends.
  • Updates CloudCreateTeamSheetPresenterTests to find the window by its cmux.cloudCreateTeam identifier and read the sheet through the CloudSheetContent wrapper, since fix: Cmd+Y crash and New Machine sheet layout #17422 hosts every Cloud sheet in it.
  • Makes CloudSheetContent internal (its size reporter stays fileprivate); the only Sources/ change is that visibility.
  • Leaves the run's other failures alone: flakes and infra timeouts.

Testing

  • The changed tests are red on main at run 37374680247; this PR changes only those tests plus the one visibility change.

Written for commit 2f1b813. Summary will update on new commits.

Review in cubic

Summary by CodeRabbit

  • Tests
    • Expanded coverage for cloud team creation, cancellation, reopening, and stale actions.
    • Updated checks for how sleeping, broken, and catalog-only machines appear in cloud trees and fleet lists.
    • No user-facing behavior changes are included.

Main's full CI at 1c84448 (run 37374680247) failed three suites on test
drift, which the window crash loop fixed in #17433 had been hiding:

- CloudTreeAvailabilityTests:23/:47 and
  MachineCreateOptimisticProjectionTests:89: #17233 always appends the
  Coderouter section, so exact tree IDs and node counts gained it.
- CloudCreateTeamSheetPresenterTests:101: #17422 hosts every Cloud sheet
  in CloudSheetWindow's CloudSheetContent wrapper, so the window no longer
  has an NSHostingController<CloudCreateTeamSheet>. Find the window by its
  cmux.cloudCreateTeam identifier and read the sheet through the wrapper,
  which is now internal (its size reporter stays fileprivate).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

All contributors have signed the CLA ✍️ ✅
Posted by the CLA Assistant Lite bot.

@coderabbitai

coderabbitai Bot commented Oct 5, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Repository: manaflow-ai/cmux/.coderabbit.yaml
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: 1d124ef1-e0f4-4485-9a19-05a8b5e1df63
📥 Commits

Reviewing files that changed from the base of the PR and between f4b3c1d and 2f1b813.

📒 Files selected for processing (4)
  • Sources/Cloud/CloudSheetWindow.swift
  • cmuxTests/CloudCreateTeamSheetPresenterTests.swift
  • cmuxTests/CloudTreeAvailabilityTests.swift
  • cmuxTests/MachineCreateOptimisticProjectionTests.swift

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 2 remain after this review.


📝 Walkthrough

Walkthrough

The changes expose CloudSheetContent to tests and update presenter tests to access the sheet through its sizing wrapper. Cloud tree tests now expect the Coderouter section in the relevant tree contents.

Changes

Cloud team sheet presenter tests

Layer / File(s) Summary
Access the sheet through its sizing wrapper
Sources/Cloud/CloudSheetWindow.swift, cmuxTests/CloudCreateTeamSheetPresenterTests.swift
CloudSheetContent is internal, and presenter tests retrieve the sheet from the wrapper. Tests invoke its actions directly and locate its window by identifier.

Cloud tree test expectations

Layer / File(s) Summary
Expect the Coderouter section in cloud trees
cmuxTests/CloudTreeAvailabilityTests.swift, cmuxTests/MachineCreateOptimisticProjectionTests.swift
Updated expectations include the Coderouter section, and the availability test also expects its provider entries.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Other

Suggested reviewers: austinywang

Merge Risk: ⚪ Minimal · up to 2f1b8

The changes align the presenter tests and cloud-tree expectations with their current source contracts. No merge-blocking risk was identified in the inspected changes.

🚥 Pre-merge checks | ✅ 24 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 33.33% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 9 functions across 4 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (24 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the Cloud test updates for the Coderouter section and Cloud sheet wrapper.
Description check ✅ Passed The description explains the test failures and changes, reports testing limits and planned CI coverage, and marks the changelog as none. A demo is not needed because the changes are test-focused and o…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Cmux Cloud Persistent Session And Early Input ✅ Passed The check does not apply to this pull request. The diff changes three test files and adjusts CloudSheetContent visibility in CloudSheetWindow.swift; it does not change Cloud terminal creation or t…
Cmux Swift Actor Isolation ✅ Passed The only production change makes CloudSheetContent internal and report fileprivate in Sources/Cloud/CloudSheetWindow.swift. CloudSheetContent is a SwiftUI View, which the actor-isolation rul…
Cmux Swift Blocking Runtime ✅ Passed The production Swift diff only changes CloudSheetContent from private to internal and makes report fileprivate. It adds no blocking or timing-based synchronization. The test diffs update expec…
Cmux Browser Automation Off-Main ✅ Passed The check passes. The pull request changes four Cloud source and test files, and none are the browser socket automation files named by the rule. The diff changes Cloud sheet visibility and test expect…
Cmux Expensive Synchronous Load ✅ Passed The only production Swift change is in Sources/Cloud/CloudSheetWindow.swift: CloudSheetContent changes from private to internal, and report changes from internal to fileprivate. Its view bod…
Cmux Cache Substitution Correctness ✅ Passed The production diff only changes CloudSheetContent from private to internal and makes report fileprivate. The other changes update tests. The PR does not replace an authoritative read with a cac…
Cmux No Hacky Sleeps ✅ Passed The diff changes only Swift production and test files. The custom check applies to production non-Swift app/runtime changes, so no changed code falls within its scope.
Cmux Algorithmic Complexity ✅ Passed The diff adds no algorithmic work on scalable production collections. The only production change in Sources/Cloud/CloudSheetWindow.swift changes CloudSheetContent from private to internal and its …
Cmux Swift Concurrency ✅ Passed The diff changes CloudSheetContent visibility, updates test access through the sizing wrapper, and revises tree expectations. It adds no legacy async pattern. The existing DispatchQueue.main.async…
Cmux Swift @Concurrent ✅ Passed The Swift diff adds no nonisolated async or @concurrent declarations and no changed calls to CPU-, file-, parsing-, or network-heavy async helpers. Its only new helper, teamSheet(in:), is synchr…
Cmux Swift Package Boundaries ✅ Passed The only production change makes CloudSheetContent internal so tests can inspect the wrapped sheet; report remains fileprivate. This is a SwiftUI sizing wrapper used by CloudSheetWindow, and the…
Cmux Swiftpm Lockfiles ✅ Passed The SwiftPM lockfile check is not triggered. The PR changes one Swift source file and three Swift test files. The diff contains no Package.swift, Xcode project, .gitignore, workflow, dependency, or Pa…
Cmux Swift Logging ✅ Passed The only production Swift change is in Sources/Cloud/CloudSheetWindow.swift. Its diff changes CloudSheetContent and report visibility and updates a comment; it adds or materially changes no logg…
Cmux User-Facing Error Privacy ✅ Passed The diff does not introduce or change user-facing error text. The only Sources change makes CloudSheetContent internal and report fileprivate; its implementation sizes the sheet, and the new comment e…
Cmux Full Internationalization ✅ Passed The PR changes one production declaration only: CloudSheetContent becomes internal, and report becomes fileprivate. The added source comment is developer-only. All other changes are test code or t…
Cmux Swiftui State Layout ✅ Passed The diff changes CloudSheetContent access control and updates tests. It adds no SwiftUI state, layout measurement, lazy-row store reference, or render-time mutation. The existing onGeometryChange …
Cmux Architecture Rethink ✅ Passed The diff changes one production declaration from private to internal and makes its reporter fileprivate. The other changes update test expectations and access the sheet through its sizing wrapper. The…
Cmux Swift Auxiliary Window Close Shortcuts ✅ Passed The diff does not add or materially change a user-visible window. Its only production change makes CloudSheetContent internal and its reporter fileprivate; the remaining changes update tests. The …
Cmux Source Artifacts ✅ Passed All four changed paths are Swift source or test files. The diff updates sheet visibility and test access, and adjusts test expectations. It adds no local tool output, generated artifacts, caches, buil…
Cmux No Test Or Debug Seam In Production Source ✅ Passed No production test/debug seam was added. The only changed production file is Sources/Cloud/CloudSheetWindow.swift; it widens CloudSheetContent from private to internal and narrows report to …
  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
🧰 Additional context used
📚 Code guidelines (3)
.github/review-bot-rules/test-determinism.md — configured
.github/review-bot-rules/swift-architectural-rethink.md — configured
.github/review-bot-rules/source-control-artifacts.md — configured

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Subagent review at 2f1b813: approve, with no blocking issues. It checked:

  • Swift 6.0 access control: a fileprivate report with a fileprivate type, and the memberwise init used in the same file.
  • That the expectations match the CI log's actual values in order (Coderouter is appended unconditionally last).
  • That the identifier lookup can't pick up a stale window.
  • That no other Cloud sheet hosting-controller casts or exact tree-ID tests are affected.

This PR's CI still has to show the Create Team assertions passing, since main's run never got past the window lookup.

@teamleaderleo
teamleaderleo merged commit 615a103 into main Oct 5, 2026
77 of 79 checks passed
@teamleaderleo
teamleaderleo deleted the fix/cloud-test-drift-1c84 branch October 5, 2026 22:22
@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

Merge receipt for 2f1b813cba, merged 2026-10-05 22:22:15 UTC

  • Not verified at merge: Reverse test impact (report only) (cancelled)
  • Verified: backend migrations applied, ci-status, macOS compile admission, CI fast guards, CI timing, Fast static checks, GhosttyKit release check, guards (18), late-placement, linux-preflight, macOS admission gate, macOS status, and 4 more
  • Skipped by policy: app-host unit tests, admission-placement, apply-production, apply-staging, browser, Claude wrapper regressions, CLI product tests, Dogfood build #​${{ github.event.pull_request.number }}, full-suite-coverage, release-admission, release-build, remote-daemon, and 8 more
  • Full suite: runs on main after merge.

@github-actions

github-actions Bot commented Oct 5, 2026

Copy link
Copy Markdown
Contributor

Dogfood tours of 2f1b813c

cloud-machine-author-tour at 2f1b813c, on its merge 5b176678 that CI built: failure (run)

cloud-machine-author-tour at 2f1b813c

Key frames of cloud-machine-author-tour at 2f1b813 04-10-right-sidebar-cloud 07-20-lab-compact 15-30-lab-aero

Tours are picked by the paths globs in dogfood/scenarios/*.json; a Dogfood-tours: a, b line in the description picks them instead (none turns this off). Look at every frame before merging: a green tour only means no step failed.

rustybret pushed a commit to rustybret/bmux that referenced this pull request Oct 5, 2026
615a103 test(cloud): follow the Coderouter section and the Cloud sheet wrapper (manaflow-ai#17448)
5fe7ca2 ci: propose removing dormant TUI nightly workflow (manaflow-ai#17419)
fbf762a ci: harden hosted queue rescue permissions (manaflow-ai#17449)
3c37fe0 ci: rescue hosted jobs cancelled in queue (manaflow-ai#17447)
f4b3c1d fix: reattach live agent views after relaunch (manaflow-ai#17435)
6c7d3a9 ci: route backend-migrations and web-complexity through CI_TRUSTED_RUNNER (manaflow-ai#17445)
0b20768 ci: publish meaningful nightly release notes (manaflow-ai#17434)
2fd61ee ci: say whose failure it is in the CI attribution comment (manaflow-ai#17443)
1adaf63 ci: route read-only Linux lanes through Blacksmith (manaflow-ai#17438)
1c84448 fix: repair main's red full CI (window crash loop, Cloud port and team regressions and test drift) (manaflow-ai#17433)

# Conflicts:
#	.github/workflows/backend-migrations.yml
#	.github/workflows/ci-cloud-overflow-probe.yml
#	.github/workflows/ci-compile-attribution.yml
#	.github/workflows/ci-failure-attribution.yml
#	.github/workflows/ci-fast-guards.yml
#	.github/workflows/ci-guard-attribution.yml
#	.github/workflows/ci-guards.yml
#	.github/workflows/ci-health-report.yml
#	.github/workflows/ci-hosted-queue-rescue.yml
#	.github/workflows/ci-repo-variables.yml
#	.github/workflows/cmux-tui-sdks.yml
#	.github/workflows/labels-sync.yml
#	.github/workflows/merge-group-policy-checks.yml
#	.github/workflows/nightly.yml
#	.github/workflows/tui-publish-npm.yml
#	.github/workflows/web-complexity-trusted.yml
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant