Skip to content

Fix resize-pane for remote tmux mirror panes#7837

Merged
austinywang merged 35 commits into
mainfrom
issue-7831-mirror-resize-pane
Jul 10, 2026
Merged

Fix resize-pane for remote tmux mirror panes#7837
austinywang merged 35 commits into
mainfrom
issue-7831-mirror-resize-pane

Conversation

@austinywang

@austinywang austinywang commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Closes #7831

Root cause

Remote-tmux panes are projected into the control-plane tree with stable pane IDs, but pane.resize treated every advertised pane as a local Bonsplit pane. It explicitly rejected a successful mirror lookup before entering the Bonsplit-only path, so IDs listed by cmux tree and pane.list were reported as Pane not found.

Fix

  • Resolve the target once through the authoritative workspace projection and dispatch it to the layout provider that owns it.
  • Model resize requests as a typed ControlPaneResizeIntent, so native points, exact tmux cells, percentages, and tmux adjustment semantics cannot be silently reinterpreted later.
  • Keep regular panes on the existing Bonsplit mutation path.
  • For public border-oriented mirror resizes, resolve the exact tmux command target for the selected split boundary, including asymmetric leading/trailing behavior in n-ary layouts, then convert native points to cells.
  • For tmux compatibility, preserve the original target and native -L/-R/-U/-D, exact-cell, or percentage semantics; positional adjustments default to one cell. pane.list now carries calibrated cell sizes in native points so local Bonsplit fallbacks remain unit-correct on Retina displays.
  • The remote Go shim deliberately keeps height-only -y probes inert for historical OMX HUD compatibility.
  • Route swift-package-tests through the repository dual-Xcode runner so the SDK-15 helper build and SDK-26 package tests can both execute; the prior single-Xcode Tart runner failed before tests.
  • Keep remote tmux authoritative: commands are forwarded over control mode and local mirror geometry updates only from tmux layout publications.
  • Return localized, honest unavailable/invalid-parameter errors instead of misreporting a projected pane as missing. This non-focus command preserves the user focus context.

Tests

The PR retains red/green regression provenance:

  • The original failing commit drives pane.resize through the real ControlCommandCoordinator path for a projected pane and captures the exact control-mode command.
  • 698b100f94 / 4c14f292ec cover and implement typed intent validation, percentage forwarding, positional/default adjustments, and daemon compatibility behavior.
  • 74758e91e2 / df6d07e9db cover and implement four-pane n-ary border targeting plus calibrated point fallbacks for both Swift and Go compatibility adapters.

Protocol-seam tests assert emitted resize-pane commands; no live remote is required. An isolated tmux 3.6a four-pane check also verified that targeting B with -R moves B/C, while targeting C moves C/D.

Local static validation (no local Xcode build/tests, per issue instructions):

  • git diff --check
  • ./scripts/lint-pbxproj-test-wiring.sh
  • ./scripts/check-pbxproj.sh
  • python3 scripts/swift_file_length_budget.py --base-ref origin/main
  • python3 scripts/check-package-resolved-policy.py
  • python3 scripts/check-workspace-package-groups.py --check
  • parsed Resources/Localizable.xcstrings and verified en/ja translations for every added key

View with Codesmith Autofix with Codesmith
Need help on this PR? Tag /codesmith with what you need. Autofix is disabled.


Note

Medium Risk
Touches core pane layout control for both local Bonsplit and remote tmux mirrors; incorrect border targeting or unit conversion could mis-apply layouts, though behavior is heavily regression-tested.

Overview
Fixes #7831 by letting projected remote tmux pane IDs resize instead of failing as “pane not found.” pane.resize now resolves the layout owner first: local panes still mutate Bonsplit; mirror panes forward resize-pane over tmux control mode and return remote: true (surfaced as pane.resize_requested).

The handler is refactored around ControlPaneResizeIntent so tmux-compat requests carry exact cells, percentages, or directional cell counts (tmux_compat) without later reinterpretation. pane.list adds cell_*_points for calibrated point fallbacks; CLI and cmuxd-remote tmux shims build target_pixels from those metrics and omit unsafe pixel fallbacks when geometry is missing. Remote routing picks the correct tmux target pane for n-ary/nested borders and converts outer layout points to cells (chrome-aware).

Directional tmux compat defaults to 1 cell, supports attached flags like -L7, and keeps height-only -y a deliberate no-op for OMX HUD probes. Localized unavailable / invalid_params errors replace silent misrouting.

Reviewed by Cursor Bugbot for commit 5b51ea2. Bugbot is set up for automated code reviews on this repo. Configure here.


Summary by cubic

Fixes remote tmux mirror pane resizing by dispatching projected pane IDs to the remote tmux owner and using layout points end-to-end with chrome-aware conversion. Preserves tmux cell/percentage semantics, distinguishes applied vs requested resize events, and avoids unsafe pixel fallbacks.

  • Bug Fixes
    • Route mirror targets via Workspace.remoteTmuxControlPane/controlRemoteTmuxPaneResize; move pane.resize to ControlCommandCoordinator+PaneResize.swift with typed ControlPaneResizeIntent.
    • tmux‑compat: forward exact target_cells/target_percentage (or calibrated target_pixels); clamp deltas to ≥1 cell; honor -L/-R/-U/-D/-x; keep height‑only -y a no‑op in cmuxd-remote.
    • Local/Bonsplit: require a split ancestor with an adjacent border across n‑ary, nested, and compact layouts; convert points→cells by subtracting pane chrome; return invalid_state when metrics/borders are missing.
    • CLI and cmuxd-remote: for -x, compute target_pixels strictly from cell_*_points on pane.list and preserve percentages; divider sync uses the standard resize path; fix remote resize RPC assignment.
    • Events and errors: emit pane.resized for local and pane.resize_requested for remote (remote: true); add socket.pane.resize.invalidParameters and socket.pane.resize.localMetricsUnavailable; pane.list now includes cell_*_points.
    • CI: install Node 22 for CLI no‑socket regressions; run Swift package tests on a dual‑Xcode macOS runner.

Written for commit 5b51ea2. Summary will update on new commits.

Review in cubic

Summary by CodeRabbit

  • New Features
    • Added support for remote tmux pane resizing via pane.resize, including relative (direction/amount) and absolute (axis/target pixels) modes, returning richer pane and geometry details.
    • Introduced pane.resize_requested for accepted remote resize requests.
  • Bug Fixes
    • Remote tmux control panes are now resolved and resized correctly (not treated as missing).
    • Divider synchronization now drives tmux resizing through the standard resize command path.
  • Documentation
    • Updated pane resize event catalog entries/descriptions (including pane.resized and pane.resize_requested).
  • Tests
    • Added/expanded coverage for remote and projected resize routing, event mapping, and observability, plus CLI compatibility assertions.

@vercel

vercel Bot commented Jul 10, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
cmux Canceled Canceled Jul 10, 2026 5:04pm
cmux-staging Building Building Preview, Comment Jul 10, 2026 5:04pm

@coderabbitai

coderabbitai Bot commented Jul 10, 2026

Copy link
Copy Markdown

Review Change Stack

Note

Reviews paused

It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.

Use the following commands to manage reviews:

  • @coderabbitai resume to resume automatic reviews.
  • @coderabbitai review to trigger a single review.

Use the checkboxes below for quick actions:

  • ▶️ Resume reviews
  • 🔍 Trigger review
📝 Walkthrough

Walkthrough

pane.resize handling was moved into a dedicated coordinator extension, remote resize routing and resolutions were added, tmux cell metadata is propagated, resize events were differentiated, and regression tests cover projected-pane resizing and layout validation.

Changes

Remote tmux pane resizing

Layer / File(s) Summary
Resize command contract and response mapping
Packages/macOS/CmuxControlSocket/Sources/CmuxControlSocket/Coordinator/Pane/*
The command handler validates absolute and relative parameters, accepts cell-space values, and maps local and remote resize resolutions into control responses.
Remote resize routing and tmux emission
Sources/TerminalController+*.swift, Sources/RemoteTmux*.swift
Remote pane targets, split borders, and native-to-cell conversions are resolved before shared helpers emit tmux resize commands.
CLI cell metadata and control transport
CLI/*, daemon/remote/cmd/cmuxd-remote/*, cmuxTests/RemoteTmuxMirrorCLIObservabilityTests.swift
CLI and daemon resize requests include cell metadata, and observability tests configure connected control-pipe transport.
Resize events and regression coverage
Sources/CmuxSocketEventMapper.swift, cmuxTests/*Resize*, cmuxTests/CmuxSocketEventMapperTests.swift, docs/events.md, cmux.xcodeproj/project.pbxproj
Local and remote resize events are distinguished, with tests covering routing, conversions, boundaries, invalid states, payloads, and project registration.

Estimated code review effort: 4 (Complex) | ~60 minutes

Sequence Diagram(s)

sequenceDiagram
  participant CLI
  participant ControlCommandCoordinator
  participant TerminalController
  participant RemoteTmuxWindowMirror
  participant RemoteTmux
  participant CmuxSocketEventMapper
  CLI->>ControlCommandCoordinator: pane.resize request with cell metadata
  ControlCommandCoordinator->>TerminalController: controlPaneResize(inputs)
  TerminalController->>RemoteTmuxWindowMirror: requestResizePane(...)
  RemoteTmuxWindowMirror->>RemoteTmux: resize-pane command
  RemoteTmux-->>RemoteTmuxWindowMirror: command result
  RemoteTmuxWindowMirror-->>ControlCommandCoordinator: resize response
  ControlCommandCoordinator->>CmuxSocketEventMapper: map local or remote result
Loading

Possibly related issues

  • manaflow-ai/cmux-dev-artifacts#3180 — Concerns failures in the remote pane resize observability tests modified by this change.
  • manaflow-ai/cmux-dev-artifacts#3185 — Concerns failures in the remote pane resize observability tests extended by this change.
  • manaflow-ai/cmux-dev-artifacts#3145 — Concerns compilation failures in the test target containing the updated resize-routing tests.

Suggested reviewers: lawrencecchen


Important

Pre-merge checks failed

Please resolve all errors before merging. Addressing warnings is optional.

❌ Failed checks (1 error, 1 warning)

Check name Status Explanation Resolution
Cmux Full Internationalization ❌ Error FAIL: socket.pane.resize.remoteUnavailable was added with only en/ja in a catalog that supports 20 locales, and docs/events.md adds English-only user-facing copy. Add translations for all 20 catalog locales, and localize or remove the new docs/event descriptions if they are user-facing.
Docstring Coverage ⚠️ Warning Docstring coverage is 27.27% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (23 passed)
Check name Status Explanation
Linked Issues check ✅ Passed The PR fixes #7831 by routing mirror panes to remote resize handling and returning a clear availability error instead of not_found.
Out of Scope Changes check ✅ Passed The additional docs, tests, event mapping, and wiring changes support the resize fix and do not appear unrelated.
Cmux Swift Actor Isolation ✅ Passed New production code stays on @MainActor UI/coordinator types or pure Sendable value models; no implicit MainActor models/protocols or unsafe shared mutable Sendable refs were introduced.
Cmux Swift Blocking Runtime ✅ Passed Changed production Swift files add remote resize routing and control commands, but no semaphores, sleeps, sync waits, polling, or manual locks were introduced.
Cmux Browser Automation Off-Main ✅ Passed PR changes only remote tmux resize plumbing; no browser.*/WebKit/AppKit routing or socket-worker changes appear in the diff, so the rule isn’t implicated.
Cmux Expensive Synchronous Load ✅ Passed No touched production Swift path adds/moves agent-history loads; the new resize code only routes pane.resize and sends tmux control commands.
Cmux Cache Substitution Correctness ✅ Passed No persistence/history/undo/snapshot cache substitution: the resize path uses live workspace/mirror lookups, and lastDividerPositions is only a transient dedupe cache.
Cmux No Hacky Sleeps ✅ Passed No changed files are in the rule’s covered TS/JS/shell/runtime-script scope; the diff only touches Swift, Go, and Xcode project files.
Cmux Algorithmic Complexity ✅ Passed PASS: The new resize path uses single linear tree/lookups and fixed-size mappings; no nested rescans, repeated sorts/filters, or batch per-target rescans were introduced.
Cmux Swift Concurrency ✅ Passed The Swift diff adds synchronous @MainActor routing and no new DispatchQueue/Combine/Task/completion-handler patterns; any such uses are pre-existing or test-only.
Cmux Swift @Concurrent ✅ Passed No changed Swift file adds @concurrent or nonisolated async work; the resize path is synchronous and the new helpers are plain sync/@mainactor methods.
Cmux Swift File And Package Boundaries ✅ Passed PASS: The PR adds small focused Swift files, moves pane.resize into a dedicated package file, and only incidentally touches oversized app files.
Cmux Swiftpm Lockfiles ✅ Passed PR touches cmux.xcodeproj/project.pbxproj only for source/test file wiring; there are no .gitignore or Package.resolved diffs, so the SwiftPM lockfile rule isn’t violated.
Cmux Swift Logging ✅ Passed No added print/debugPrint/dump/NSLog/Logger/os_log in production diffs; changes are routing, payload, and event mapping only. CLI output code is unchanged/allowed.
Cmux User-Facing Error Privacy ✅ Passed The only new user-facing copy is a generic remote-tmux availability message; no vendor/provider secrets, raw upstream errors, or sensitive payloads appear in the changed production code.
Cmux Swiftui State Layout ✅ Passed No changed files introduce SwiftUI state/layout patterns; the PR is backend/control-socket and test code, not view hierarchy or render-time state.
Cmux Architecture Rethink ✅ Passed Remote resize stays behind one owner (controlRemoteTmuxPaneResize) and tmux layout publication remains authoritative; no sleeps, caches, or split lifecycle ownership were added.
Cmux Swift Auxiliary Window Close Shortcuts ✅ Passed PASS: The diff only touches control-socket, remote-tmux, tests, and docs; no NSWindow/WindowGroup or cmuxAuxiliaryWindowIdentifiers changes, so the rule isn’t implicated.
Cmux Source Artifacts ✅ Passed All changed paths are intentional source/config/test/localization files; none are artifact directories or generated outputs.
Cmux No Test Or Debug Seam In Production Source ✅ Passed Touched Sources files add production resize plumbing only; no #if DEBUG, ForTesting, TestHook, or similar test/debug seam appears in the diff.
Cmux No Ambient Global State ✅ Passed PASS: added behavior stays on existing types/extensions; no new file-scope funcs, mutable globals, or singletons were introduced.
Title check ✅ Passed The title is concise and accurately describes the main change: fixing resize-pane for remote tmux mirror panes.
Description check ✅ Passed The description covers the core summary and testing sections, though it omits the demo video, review trigger block, and checklist details.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch issue-7831-mirror-resize-pane

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.

@greptile-apps

greptile-apps Bot commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

This PR fixes remote tmux mirror pane resizing through the control socket. The main changes are:

  • Routes projected remote pane IDs to the owning tmux mirror.
  • Adds typed resize intents for native points, tmux cells, percentages, and relative cell moves.
  • Keeps local Bonsplit panes on the existing mutation path.
  • Adds calibrated cell sizes to pane.list for unit-correct fallbacks.
  • Adds localized resize error messages and remote resize events.
  • Updates CLI, daemon, tests, docs, and CI wiring for the resize path.

Confidence Score: 5/5

This looks safe to merge.

  • No blocking issues found in the changed code.

Important Files Changed

Filename Overview
Packages/macOS/CmuxControlSocket/Sources/CmuxControlSocket/Coordinator/Pane/ControlCommandCoordinator+PaneResize.swift Adds typed parsing and response shaping for local and remote pane.resize requests.
Sources/TerminalController+RemoteTmuxControlMutations.swift Routes remote tmux pane resize intents to the mirror that owns the projected pane.
Sources/RemoteTmuxNativeLayoutMetrics.swift Adds native point to tmux cell conversion helpers for remote resize requests.
CLI/CMUXCLI+TmuxCompatResizePane.swift Adds CLI tmux-compatible resize helpers for exact cells, percentages, and calibrated point fallbacks.
Resources/Localizable.xcstrings Adds English and Japanese strings for the new pane resize messages.
daemon/remote/cmd/cmuxd-remote/tmux_compat.go Updates the remote shim to forward typed tmux-compatible resize parameters.

Reviews (21): Last reviewed commit: "Merge origin/main into issue-7831-mirror..." | Re-trigger Greptile

Comment thread Sources/TerminalController+RemoteTmuxControlMutations.swift Outdated
@austinywang

austinywang commented Jul 10, 2026

Copy link
Copy Markdown
Contributor Author

Update after CodeRabbit inline review: refined triage supersedes the earlier rejection. Although the %0 fallback predates this PR (origin/main blame 48643bc), #7831 centralizes this exact resize-forwarding line, so 118bfe2 now fails closed unless the measured subtree has an authoritative pane ID. The change is limited to command targeting and does not alter mirror topology or #7833 lifecycle behavior.

@austinywang austinywang enabled auto-merge (squash) July 10, 2026 09:49

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 5

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@cmuxTests/RemoteTmuxMirrorCLIFailClosedTests.swift`:
- Around line 176-182: Update
unsupportedBonsplitOnlyPaneMutationsRejectProjectedPaneIDs to retain the
disconnected-transport resize regression: invoke pane.resize using the projected
pane ID from the harness, assert it returns the unavailable failure contract,
and verify it does not return pane_not_found or mutate local Bonsplit state.
- Around line 161-172: Update the command decoding in the test to use strict
UTF-8 validation: replace String(decoding:as:) with String(bytes:encoding:),
require the result to be non-nil, then perform the existing command assertion on
the validated string.
- Around line 135-174: Add a complementary test near
paneResizeRoutesProjectedPaneToRemoteTmux that sends an absolute pane.resize
request, verifying pixel dimensions are converted to cells, the correct axis is
selected, the response payload reflects the converted resize, and the remote
tmux stream contains the expected resize-pane command using -x or -y.

In `@Sources/RemoteTmuxWindowMirror`+DividerSizing.swift:
- Around line 47-51: Replace the `first.paneIDsInOrder.first ?? 0` fallback in
the `requestResizePane` call with guarded extraction of an authoritative pane ID
from `first.paneIDsInOrder`; only issue the resize when that ID exists,
otherwise return or skip the operation without sending a tmux command.

In `@Sources/TerminalController`+RemoteTmuxControlMutations.swift:
- Around line 252-276: Prevent zero-cell absolute resizes in the absolute resize
branch of the remote mutation handler. After computing targetCells from
targetPixels and cellPixels, guard that targetCells is greater than zero and
return unavailable before calling location.mirror.requestResizePane; only
forward the request and emit remoteAbsoluteResizeRequested for valid positive
cell counts.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: e89058f4-8e00-49e7-9dcc-4a517324266c

📥 Commits

Reviewing files that changed from the base of the PR and between 667cc43 and 880abba.

📒 Files selected for processing (10)
  • Packages/macOS/CmuxControlSocket/Sources/CmuxControlSocket/Coordinator/Pane/ControlCommandCoordinator+Pane.swift
  • Packages/macOS/CmuxControlSocket/Sources/CmuxControlSocket/Coordinator/Pane/ControlCommandCoordinator+PaneResize.swift
  • Packages/macOS/CmuxControlSocket/Sources/CmuxControlSocket/Coordinator/Pane/ControlPaneResizeResolution.swift
  • Resources/Localizable.xcstrings
  • Sources/RemoteTmuxWindowMirror+ControlMutations.swift
  • Sources/RemoteTmuxWindowMirror+DividerSizing.swift
  • Sources/TerminalController+ControlPaneContext.swift
  • Sources/TerminalController+RemoteTmuxControlMutations.swift
  • cmuxTests/RemoteTmuxMirrorCLIFailClosedTests.swift
  • cmuxTests/RemoteTmuxMirrorCLIObservabilityTests.swift
💤 Files with no reviewable changes (1)
  • Packages/macOS/CmuxControlSocket/Sources/CmuxControlSocket/Coordinator/Pane/ControlCommandCoordinator+Pane.swift

Comment thread cmuxTests/RemoteTmuxMirrorCLIFailClosedTests.swift Outdated
Comment thread cmuxTests/RemoteTmuxMirrorCLIFailClosedTests.swift Outdated
Comment thread cmuxTests/RemoteTmuxMirrorCLIFailClosedTests.swift
Comment thread Sources/RemoteTmuxWindowMirror+DividerSizing.swift Outdated
Comment thread Sources/TerminalController+RemoteTmuxControlMutations.swift Outdated
@austinywang

austinywang commented Jul 10, 2026

Copy link
Copy Markdown
Contributor Author

CodeRabbit i18n pre-merge note: reasoned rejection. The governing repo instructions explicitly define the currently supported locales as English and Japanese. socket.pane.resize.remoteUnavailable has both en and ja entries with stringUnit.state = translated, and python3 -m json.tool Resources/Localizable.xcstrings passes. Adding speculative translations for historical catalog locales is outside the repository localization contract for #7831; CI remains authoritative.

Comment thread Sources/TerminalController+RemoteTmuxControlMutations.swift Outdated
Comment thread Sources/TerminalController+RemoteTmuxControlMutations.swift Outdated
@austinywang

Copy link
Copy Markdown
Contributor Author

CodeRabbit privacy note: reasoned rejection. “Remote tmux” is the explicit user-facing feature and CLI surface (ssh-tmux), not a hidden provider/service identifier; naming it tells users which pane owner rejected the request. The copy contains no host, session, credential, path, command output, or other private data. The governing localization contract remains English/Japanese, and both entries are translated and JSON-validated.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@Sources/TerminalController`+RemoteTmuxControlMutations.swift:
- Line 260: In the split-orientation handling near the remote tmux mutation
logic, replace the ternary fallback with an exhaustive axis switch that maps
"horizontal" and "vertical" explicitly and immediately returns the unavailable
result for any unrecognized axis, before split-ancestor/border checks or cell
computation; keep behavior aligned with
requestResizePane(absoluteAxis:targetCells:).
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: 5f959f37-9c67-42c5-b400-e174e5b6cd28

📥 Commits

Reviewing files that changed from the base of the PR and between bf158b4 and aa3a1a4.

📒 Files selected for processing (11)
  • Packages/macOS/CmuxControlSocket/Sources/CmuxControlSocket/Coordinator/Pane/ControlPaneResizeInputs.swift
  • Resources/Localizable.xcstrings
  • Sources/CmuxSocketEventMapper.swift
  • Sources/RemoteTmuxNativeLayoutMetrics.swift
  • Sources/RemoteTmuxNativeSplitTree.swift
  • Sources/RemoteTmuxWindowMirror+ControlMutations.swift
  • Sources/TerminalController+RemoteTmuxControlMutations.swift
  • cmux.xcodeproj/project.pbxproj
  • cmuxTests/RemoteTmuxMirrorCLIFailClosedTests.swift
  • cmuxTests/RemoteTmuxMirrorCLIObservabilityTests.swift
  • cmuxTests/RemoteTmuxMirrorResizeRoutingTests.swift
💤 Files with no reviewable changes (1)
  • cmuxTests/RemoteTmuxMirrorCLIFailClosedTests.swift

Comment thread Sources/TerminalController+RemoteTmuxControlMutations.swift Outdated
Comment thread Sources/TerminalController+RemoteTmuxControlMutations.swift Outdated
Comment thread Sources/TerminalController+RemoteTmuxControlMutations.swift Outdated

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@Packages/macOS/CmuxControlSocket/Sources/CmuxControlSocket/Coordinator/Pane/ControlCommandCoordinator`+PaneResize.swift:
- Around line 13-16: Update the parameter parsing in the pane resize coordinator
so explicitly supplied invalid values are rejected instead of treated as absent:
validate `target_cells`, `amount`, and `amount_cells` based on key presence,
requiring parseable positive integers where applicable, and return
`invalid_params` before resize or pixel-conversion fallback when validation
fails. Preserve defaults only when the keys are omitted.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

Run ID: fc7445b6-22c8-4477-a794-e18c9bb10caf

📥 Commits

Reviewing files that changed from the base of the PR and between aa3a1a4 and 3d265c3.

📒 Files selected for processing (12)
  • CLI/CMUXCLI+TmuxCompatSupport.swift
  • CLI/cmux.swift
  • Packages/macOS/CmuxControlSocket/Sources/CmuxControlSocket/Coordinator/Pane/ControlCommandCoordinator+PaneResize.swift
  • Packages/macOS/CmuxControlSocket/Sources/CmuxControlSocket/Coordinator/Pane/ControlPaneResizeInputs.swift
  • Sources/RemoteTmuxNativeSplitTree.swift
  • Sources/TerminalController+RemoteTmuxControlMutations.swift
  • cmux.xcodeproj/project.pbxproj
  • cmuxTests/CLITmuxCompatRemoteSplitTests.swift
  • cmuxTests/CLITmuxCompatResizePaneTests.swift
  • cmuxTests/RemoteTmuxMirrorResizeRoutingTests.swift
  • daemon/remote/cmd/cmuxd-remote/tmux_compat.go
  • daemon/remote/cmd/cmuxd-remote/tmux_corpus_behavior_test.go

Comment thread Sources/TerminalController+RemoteTmuxControlMutations.swift
Comment thread CLI/CMUXCLI+TmuxCompatResizePane.swift Outdated
Comment thread CLI/CMUXCLI+TmuxCompatResizePane.swift Outdated

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 11c9a2a. Configure here.

Comment thread CLI/CMUXCLI+TmuxCompatResizePane.swift
@austinywang austinywang merged commit 2eeac82 into main Jul 10, 2026
35 of 37 checks passed
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.

ssh-tmux mirror: cmux resize-pane returns "Pane not found" for panes that cmux tree lists in the mirror workspace

2 participants