Skip to content

fix(cmux-next): pending New Tab access chip is a live menu at the start mode - #21272

Merged
teamleaderleo merged 18 commits into
feat-cmux-nextfrom
fix/composer-spacing-access-current
Oct 19, 2026
Merged

teamleaderleo merged 18 commits into
feat-cmux-nextfrom
fix/composer-spacing-access-current

Conversation

@teamleaderleo

@teamleaderleo teamleaderleo commented Oct 17, 2026 •

Copy link
Copy Markdown
Collaborator

Problem

A New Tab chat that has not reported its modes yet shows its access mode (the start mode acpmux answered) as an inert pending chip, so you can't change it before the first send.

Change

  • While the chat is pending, the start mode shows as a real access menu. The rows come from the harness's last mode catalog, the checked row is acpmux's start mode, and a pick goes through the normal chat.mode setter.
  • The checked row is never the mode the harness's last chat showed. An earlier head of this PR read the profile's last current mode, so a chat starting in full access could show "Ask before edits". There is now a test for that.
  • A borrowed answer (another folder's) still shows the unnamed inert chip, as before.

Scope was cut at the base merge (2026-10-19). The spacing, checkmark-column and pill-outline changes are dropped, because later base work chose differently: #21645, #21744 and #21816 changed the same rules. The regenerated protocol files are also dropped.

Validation

  • bun test test/access-chip-pending-warning.test.tsx (jsdom) discriminates: 2 of its 8 tests ("first frame" and "names acpmux's start mode") fail with the base ComposerPickers.tsx/App.tsx, and all 8 pass at this head. It drives ComposerPickers with holdsModePick set directly.
  • CMUX_BROWSER_TESTS=1 bun test test/agent-pane-start-mode-chip.test.ts passes, but its new assertions also pass with base sources (they cover a shown harness switch, where the live access menu already draws), so they are not coverage of this change.
  • Not covered by a test: the New Tab gate (holdsModePick in DefaultComposerChips) and a pending-menu pick reaching session/set_mode after the first send. A review traced that path by hand: chat.new {deferred} runs before chat.mode, pickMode holds the mode with its gesture ticket, and run() applies it when the chat opens.
  • After merging feat-cmux-next (73740a8): bun test over the access-chip, model-picker, New Tab and markdown-link tests: 103 pass, 11 skip (browser lane), 0 fail. bun run typecheck clean.

Known follow-ups (low): the menu has only the checked row when the harness has never reported its modes; a held New Tab pick doesn't refresh other pending chats' kept start mode until acpmux announces the change; holdsModePick reads window.cmuxAcpmuxActions during render.

🤖 Generated with Claude Code

@coderabbitai

coderabbitai Bot commented Oct 17, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration
  • Configuration used: Repository: manaflow-ai/cmux/.coderabbit.yaml
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: ad03361a-57dc-4c39-bd23-9c2812c4b6eb

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

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.

@github-actions

github-actions Bot commented Oct 17, 2026 •

Copy link
Copy Markdown
Contributor

red: web / Web status; do not merge until green; see lane-rules
red: web / react-apps-check; do not merge until green; see lane-rules
red: web / react-apps-check (1); do not merge until green; see lane-rules
red: web / react-apps-check (2); do not merge until green; see lane-rules

@github-actions

github-actions Bot commented Oct 17, 2026 •

Copy link
Copy Markdown
Contributor

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

Unclear: web / react-apps-check failed: no known signature; failed step: Check webview test shards.

CI failed on 19e438ab08 (run 39219313520 attempt 1): 2 code, 1 unknown.

Job Verdict Why
web / react-apps-check (2) code a web test failed
web / react-apps-check (1) code a web test failed
web / react-apps-check unknown no known signature; failed step: Check webview test shards

Failures:

  • seen on other PRs agent-pane-mode-keys.test.ts the trigger and every menu row draw the mode's own shield: failed (job)
  • seen on other PRs check-system-blue.test.ts check-system-blue > this checkout is within its baseline: failed (job)
  • seen on other PRs composer-footer-plain.test.ts at 760 px (light): off, the chips draw as today: failed (job)
  • seen on other PRs composer-footer-plain.test.ts at 760 px (light): on, plain text at rest, same labels, no overlap: failed (job)
  • seen on other PRs composer-footer-plain.test.ts at 760 px (dark): off, the chips draw as today: failed (job)
  • seen on other PRs composer-footer-plain.test.ts at 760 px (dark): on, plain text at rest, same labels, no overlap: failed (job)
  • seen on other PRs composer-footer-plain.test.ts at 480 px (light): off, the chips draw as today: failed (job)
  • seen on other PRs composer-footer-plain.test.ts at 480 px (light): on, plain text at rest, same labels, no overlap: failed (job)
  • seen on other PRs composer-footer-plain.test.ts at 480 px (dark): off, the chips draw as today: failed (job)
Matched log lines
web / react-apps-check (2): (fail) the trigger and every menu row draw the mode's own shield [669.08ms]
web / react-apps-check (1): (fail) check-system-blue > this checkout is within its baseline [1351.26ms]

Not re-run automatically: web / react-apps-check (2), web / react-apps-check (1), web / react-apps-check are not machine failures.

Written by scripts/ci/classify_failures.py (ci-failure-attribution.yml); signatures are its SIGNATURES table. A machine verdict is the runner's fault, not this PR's; yours means the failing file is one this PR changes, also red on main that main's latest full suite fails the same way, seen on other PRs that it failed on another pull request's run lately.

CI fast guards failed on 19e438ab08 (https://github.com/manaflow-ai/cmux/actions/runs/39219313520). It does not block the merge; a red guard merged into main breaks it for every open PR.
The log named no failed step; see the run.

Agents: python3 scripts/ci/guard_attribution.py fix applies the mechanical fixes locally.

@github-actions

github-actions Bot commented Oct 17, 2026 •

Copy link
Copy Markdown
Contributor

CI fast guards failed on 83b74e5791 (https://github.com/manaflow-ai/cmux/actions/runs/39012058304). It does not block the merge; a red guard merged into main breaks it for every open PR.
The log named no failed step; see the run.

Agents: python3 scripts/ci/guard_attribution.py fix applies the mechanical fixes locally. This comment is updated in place on each push.

@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Bead cx-qb8e5 created for this PR by the cmux coordinator.

@cursor

cursor Bot commented Oct 17, 2026

Copy link
Copy Markdown

Bugbot needs on-demand usage enabled

Bugbot uses usage-based billing for this team and requires on-demand usage to be enabled.

A team admin can enable on-demand usage in the Cursor dashboard.

@teamleaderleo
teamleaderleo force-pushed the fix/composer-spacing-access-current branch from 453a1f5 to d34e60c Compare October 17, 2026 04:21
@github-actions

Copy link
Copy Markdown
Contributor

Gallery

Review in feed

355 states changed: agent-pane.transcript/long-code, agent-pane.chat-width/wide-blocks, agent-pane.artifact-panel/markdown, agent-pane.new-tab/calm-default, agent-pane.new-tab/split-open-tabs-context-menu, ... · 75 play checks failed

Diff page and renders (the run's gallery-pr artifact)

State Before · after
agent-pane.transcript/long-code (Apple System Colors, webkit)
agent-pane.transcript/long-code (Apple System Colors, webkit)
agent-pane.chat-width/wide-blocks (Apple System Colors, chromium)
agent-pane.artifact-panel/markdown (Apple System Colors Light, webkit)
agent-pane.artifact-panel/markdown (Apple System Colors, webkit)
agent-pane.new-tab/calm-default (Apple System Colors Light, chromium)

349 more on the diff page.

Live preview (follows this branch; start it with scripts/gallery-live.sh up <branch> from an hq checkout):

  • agent-pane.transcript/long-code: /wt/fix-composer-spacing-access-current/?entry=agent-pane.transcript#/agent-pane.transcript/long-code
  • agent-pane.chat-width/wide-blocks: /wt/fix-composer-spacing-access-current/?entry=agent-pane.chat-width#/agent-pane.chat-width/wide-blocks
  • agent-pane.artifact-panel/markdown: /wt/fix-composer-spacing-access-current/?entry=agent-pane.artifact-panel#/agent-pane.artifact-panel/markdown
  • agent-pane.new-tab/calm-default: /wt/fix-composer-spacing-access-current/?entry=agent-pane.new-tab#/agent-pane.new-tab/calm-default
  • agent-pane.new-tab/split-open-tabs-context-menu: /wt/fix-composer-spacing-access-current/?entry=agent-pane.new-tab#/agent-pane.new-tab/split-open-tabs-context-menu
  • agent-pane.new-tab/split-open-tabs: /wt/fix-composer-spacing-access-current/?entry=agent-pane.new-tab#/agent-pane.new-tab/split-open-tabs
  • 111 more on the diff page

Play checks failed (0 px anchor movement, 0 layout shift, no frame over 33 ms unless the entry gives a reason):

  • agent-pane.artifact-panel/markdown (Apple System Colors Light, webkit): play: no element for button "Open preview"
  • agent-pane.artifact-panel/markdown (Apple System Colors, webkit): play: no element for button "Open preview"
  • agent-pane.artifact-panel/versions (Apple System Colors Light, webkit): play: no element for button "Open preview"
  • agent-pane.artifact-panel/markdown (Apple System Colors Light, chromium): play: no element for button "Open preview"
  • agent-pane.new-tab/typed-red-duplicates (Apple System Colors, chromium): step 1 type "red": layout shift 0.0226 (limit 0.02)
  • agent-pane.new-tab/typed-red-duplicates (Apple System Colors Light, chromium): step 1 type "red": layout shift 0.0226 (limit 0.02)
  • 360 more on the diff page

442 nondeterministic states differed from a second render of the same head (a clock or fixture leak) and are not counted as changes.

2475 unchanged · base b38e00f · head 2655325

@teamleaderleo
teamleaderleo force-pushed the fix/composer-spacing-access-current branch from d34e60c to 617e6b8 Compare October 17, 2026 04:50
@blacksmith-sh

blacksmith-sh Bot commented Oct 17, 2026 •

Copy link
Copy Markdown

Found 10 test failures on Blacksmith runners:

Failures

Test View Logs
/tmp/tmp8ujtxobe/summary-missing.json (live):/summary-missing.json (live): View Logs
/tmp/tmpv1nj84ac/summary-fail.json (live):/summary-fail.json (live): View Logs
test/agent-pane-mode-keys.test.ts/agent-pane-mode-keys.test View Logs
test/agent-pane-mode-keys.test.ts/agent-pane-mode-keys.test View Logs
test/check-system-blue.test.ts/check-system-blue.test View Logs
test/check-system-blue.test.ts/check-system-blue.test View Logs
test/composer-footer-plain.test.ts/composer-footer-plain.test View Logs
test/composer-footer-plain.test.ts/composer-footer-plain.test View Logs
test/theme-colors.test.ts/theme-colors.test View Logs
test/theme-colors.test.ts/theme-colors.test View Logs

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

Remove the duplicate title tooltip from the interactive pending access button and assert that the remembered access mode is a usable menu while the session is pending.
@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Evidence for this PR's area from a click-through on cmux16 (tagged build of feat-cmux-next c25d784 plus #21677, #21685 and #21688):

  • The first New Tab after launch draws no access chip at all: model and reasoning only. The New Tab after a relaunch does the same. Before the chat starts, chat_state.composer has no access entry. After the chat starts, the chip reads "Full access" (real Claude Code) or "Bypass Permissions" (the fake agent).
  • In one manual pass, a later New Tab drew an icon-only shield.
  • The page's first _acpmux/start_mode for cwd ~ was refused with transport.path_outside_roots, so no answer was kept for that first frame.

scripts/cmux-next/clickthrough-live.py (#21729) checks this case: "first New Tab after launch draws model, reasoning and access chips". It fails on the current tip.

This PR conflicts with feat-cmux-next right now (styles.css). Once it's rebased, the check above should go green if it covers this case.

teamleaderleo and others added 3 commits October 18, 2026 23:40
…r-spacing-access-current

# Conflicts:
#	scripts/cmux-next/type-scale-baseline.tsv
#	webviews/src/agent-session/acpmux/ComposerPickers.tsx
#	webviews/src/agent-session/acpmux/composerLocation.css
#	webviews/src/agent-session/acpmux/newtab/screen.css
#	webviews/src/agent-session/acpmux/protocol/generated/methods.ts
#	webviews/src/agent-session/acpmux/protocol/generated/types.ts
#	webviews/src/agent-session/acpmux/styles.css
…e, not the last chat's

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… the last chat's

The pending menu used the harness profile's last current mode, so a chat
starting in full access could show Ask before edits. Rows come from the
profile's catalog; the check is the start mode.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@teamleaderleo teamleaderleo changed the title fix(cmux-next): restore pending access picker and tighten New Tab spacing fix(cmux-next): pending New Tab access chip is a live menu at the start mode Oct 19, 2026
@github-actions

github-actions Bot commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

Receipt for 19e438a (this PR's head; a new push replaces it)

  • Visual review: HQ feed card · gallery before/after runs
  • Checks: this head
  • 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=pr21272 -f ref=fix/composer-spacing-access-current -f platform=macos -f backend_mode=local

teamleaderleo and others added 4 commits October 18, 2026 23:49
…n is never an access row

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…tays an inert chip

Review findings: in a pane with no New Tab start and no harness switch a
pick reached no session and the chip could name a mode the chat would
not start in. The start mode's row keeps acpmux's name.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…is connected and a harness is set

Re-review findings: before the handshake chat.mode posts to native, which
drops it; with no harness start() sends nothing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- vp fmt webviews/src/agent-session/acpmux/replyHref.ts
- vp fmt webviews/src/pages/markdown/README.md
- vp fmt webviews/src/pages/markdown/links.ts
- vp fmt webviews/test/markdown-cmux-app-links.test.ts

Autofix-Run: https://github.com/manaflow-ai/cmux/actions/runs/39212532636
…r-spacing-access-current

# Conflicts:
#	webviews/src/agent-session/acpmux/replyHref.ts
#	webviews/src/pages/markdown/links.ts
@teamleaderleo

Copy link
Copy Markdown
Collaborator Author

Merging at 19e438ab08. None of the reds come from this PR's four files:

  • cmux-next checks: only "Motion tokens" fails, and it fails on the feat-cmux-next tip 6c4456b7 (TerminalSizedForChip, HibernationRing, HoverCardPanel).
  • react-apps-check:

Review: a subagent review found two blocking bugs. Both are fixed with tests that fail first:

  • The access menu could name the last chat's mode instead of the start mode.
  • A pick could reach no session.

The re-review's two low gaps (a pick before the acpmux handshake, and a New Tab with no harness) are closed in 2ada973.

@github-actions

Copy link
Copy Markdown
Contributor

The feat-cmux-next push run https://github.com/manaflow-ai/cmux/actions/runs/39312344912 at 3888f63 failed: cmux-next web bundles (source-keyed cache).
Those jobs last passed at a79d2d7. This pull request is one of 4 merged since: #21932, #21111, #21729, #21272.
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

Copy link
Copy Markdown
Contributor

The feat-cmux-next push run https://github.com/manaflow-ai/cmux/actions/runs/39312688402 at 016dffb failed: cmux-next web bundles (source-keyed cache).
Those jobs last passed at a79d2d7. This pull request is one of 5 merged since: #21932, #21111, #21729, #21272, #22012.
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 commented Oct 19, 2026 •

Copy link
Copy Markdown
Contributor

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