Skip to content

fix(mobile): Home lists only directly paired desktops' agents again, as in v1.4.279 - #50787

Merged
AmethystLiang merged 1 commit into
mainfrom
AmethystLiang/home-relayed-agents-release-parity
Nov 27, 2026
Merged

AmethystLiang merged 1 commit into
mainfrom
AmethystLiang/home-relayed-agents-release-parity

Conversation

@AmethystLiang

@AmethystLiang AmethystLiang commented Nov 27, 2026 •

Copy link
Copy Markdown
Contributor

ELI5

Home's agent lists go back to showing only the agents on desktops the phone is paired with, as they did in v1.4.279. Agents on servers that a desktop relays to no longer appear on Home. Those servers' workspaces and bots are still reachable as before.

Files Added Deleted Net
Test 3 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​49 $\color{#cf222e}{\Huge{\mathbf{−}}}$​257 $\color{#cf222e}{\Huge{\mathbf{−}}}$​208
Prod 12 $\color{#1a7f37}{\Huge{\mathbf{+}}}$​24 $\color{#cf222e}{\Huge{\mathbf{−}}}$​446 $\color{#cf222e}{\Huge{\mathbf{−}}}$​422

What Changed

This is a scoped rollback of Home's relayed-agent integration from #49357, plus the follow-ups that only that integration used. It is not a revert of #49357 as a whole.

Removed (Home-only):

Home now: agentList reads each desktop's own worktreeInfo again. Agents, Feed, Active and Needs You counts, and the empty state match v1.4.279. use-agent-list-row-actions.tsx, home-worktree-info.ts and home-query-restore.ts are back to their v1.4.279 contents. agent-list-rows.ts and MobileAgentListRows.tsx keep the later unrelated changes from #48765 and #48822.

Kept unchanged:

  • the shared MOBILE_RELAY_HOST_ROWS_CHANGED_EVENT_RUNTIME_CAPABILITY (only its comment is updated);
  • relayHostSchema.rowChanges;
  • every desktop handler and protocol;
  • Home Bots' relay list read and its relayHostsChanged signal;
  • workspace lists' relayed reads through ServerRowSnapshots.read/retain.

No data migration. An unused prerelease cache entry for relayHosts.homeServers is left as is.

Why

A relayed server's row notice could trigger a Home rows read. The desktop refreshed that server's full workspace list (worktree.ps) and, for snapshot-capable clients, hashed every returned row to compute the delta.

On blur, Home also sent unwatchRows, which releases every row hold on the phone connection, including holds that a workspace screen still needs. This returns Home's agent lists to their behavior in v1.4.279.

Linked Issue

Partially rolls back #49357 (Home relayed agents) and the Home parts of #49478 and #49472.

Visual Proof

Home shows fewer rows. Relay-only agents no longer appear, and the layout, copy and empty state are unchanged from v1.4.279. I haven't attached captures.

Testing

  • I manually tested these changes locally

  • Automated tests added/updated, or explained why not below

  • Every added test fails without this change and avoids the test anti-patterns

  • The retired-server eviction test that fix(mobile): evict retired servers from Home private row snapshots (STA-18544) #49469 added for Home's private snapshots now lives in mobile/src/worktree/execution-hosts/server-workspaces.test.ts. It covers the shared ServerRowSnapshots.read path: a dropped and re-added server starts a fresh read, and the server that stays listed keeps its snapshot. This preserves coverage, so it also passes without this change.

  • Source checks against the base and PR head show that the Home agent row observer, persisted restore wiring, and Home blur unwatch caller are gone. The desktop handlers, Home Bots and ordinary workspace query paths are unchanged.

  • Mobile verify passed lint, typechecks, formatting and tests. Other GitHub checks are reported on this PR.

Performance

These figures are source-derived, not measured. For a phone with Home open and a relayed server with N workspaces:

  • Before the rollback, coalesced Home row notices could trigger a refresh at the three-second floor per server. A refresh fetched or joined a full worktree.ps inventory read of up to 10,000 rows, with additional host listing and row processing. Snapshot-capable reads also serialized and hashed each returned row, then decoded the reply on the phone.
  • After: Home sends zero relayed-agent reads. Home Bots' relay list reads and workspace screens' own relayed reads are unchanged.
  • Still running: a workspace or folder screen that read a server's rows can keep the desktop's row watch for that server while connected. That watch does no polling and no per-notice fetch or hash; it costs only its event subscription and notices.

Risk

Level: Medium.

Users who used Home's "All desktops" list to watch agents on relayed servers no longer see those agents on Home. They can still reach them from the server's workspace screens. Phones and desktops stay protocol-compatible in both directions, because the desktop is unchanged and the phone keeps advertising the same capability.

To back out, revert this PR.

AI Disclosure

Review

Agent skill upstream boundary

  • Not applicable, or this change copies or mechanically translates no upstream skill-installer source, tests, fixtures, registry entries, path tables, comments, or documentation.

Notes

Ensure no issues in: Security, Cross-platform support (Linux, Windows, Mac), Remote SSH, Mobile, general backwards compatibility, performance

Checklist

  • This PR is small and focused
  • I explained what changed and why (ELI5, the user-facing before/after, the mechanism, and why over the alternatives)
  • I stated the risk: what could break, for whom, and how to back it out
  • Before/after screenshots or videos attached for UI changes, or N/A with reason
  • Self-reviewed for correctness, security, and performance
  • Cross-platform, SSH/remote, and path/shortcut impact considered (or N/A)
  • pnpm lint, pnpm typecheck, pnpm test, and pnpm build pass (or CI will cover; local preferred)

…as in v1.4.279

Home's Agents and Feed stop merging in agents from servers a desktop relays to.
Home no longer reads a relayed server's rows whenever its row notice fires, which
made each such desktop refetch the server's whole workspace list and hash every
row. Its blur release, which dropped every row hold on the phone connection, goes
with it.

Kept: the shared relay capability, the relay host schema and the desktop protocol.
Home Bots still reads the relay list and listens for relayHostsChanged, and
workspace lists still read relayed rows through ServerRowSnapshots.

The retired-server eviction test now covers the shared ServerRowSnapshots.read
path rather than Home's private snapshots.
@coderabbitai

coderabbitai Bot commented Nov 27, 2026 •

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The change removes the Mobile Home relayed-server queries, selection, row watches, and agent merging. Home now passes worktree information directly to the agent list. Agent-row lookup and lineage no longer use execution-host grouping, and execution-host labels and session options are removed. The change also removes server workspace operations and adds a test for snapshot handling when a server is re-added.

Merge Risk: Minimal · up to d079e

Mobile Home returns to listing agents only from directly paired desktops, as in v1.4.279, and no longer shows agents from servers reached through relays. Those servers' workspaces and bots stay reachable. No concrete defect was found, and the change removes work rather than adding it. Wait for CI (lint, typecheck, tests) to finish before merging.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title names the main change: Home's agent lists again show only directly paired desktops' agents, matching v1.4.279. The raw summary confirms the removal of relayed-server agent reads, rows, and r…
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.
Description check Passed The description follows the repository template and fills in most required sections. It has a clear ELI5, a detailed What Changed section that lists removed and kept components, a Why section that exp…
Full details: Title check

Explanation

The title names the main change: Home's agent lists again show only directly paired desktops' agents, matching v1.4.279. The raw summary confirms the removal of relayed-server agent reads, rows, and related code from Home, so the title fits the changeset. It uses the fix() prefix and stays under one line, though at 83 characters it is slightly long.

Full details: Description check

Explanation

The description follows the repository template and fills in most required sections. It has a clear ELI5, a detailed What Changed section that lists removed and kept components, a Why section that explains the blur unwatchRows problem and the performance cost, a Risk section with level Medium and a backout plan, and a Performance section with source-derived figures. The Testing section has partial content but leaves the manual testing box unchecked and says no manual testing was reported. Gaps: the Linked Issue section has 'Fixes #' left blank and gives only partial references to #49357, #49478 and #49472 rather than an actual issue link. The Visual Proof section says no captures are attached and does not use the required N/A form, even though the change alters visible Home rows. The AI Disclosure section is empty. The pnpm lint, typecheck, test and build checkbox is unchecked. These gaps are non-critical to the core change description, so the check passes.

  • 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

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: a12e8bed-f0fe-4f31-8145-7382881fbcf6
Commits

Reviewing files that changed from the base of the PR and between 5d7f06c and d079ef2.

Files selected for processing: 15

  • mobile/src/agents/MobileAgentListRows.tsx
  • mobile/src/agents/agent-list-rows.ts
  • mobile/src/agents/use-agent-list-row-actions.tsx
  • mobile/src/home/home-query-restore.ts
  • mobile/src/home/home-relayed-server-queries.test.ts
  • mobile/src/home/home-relayed-server-queries.ts
  • mobile/src/home/home-relayed-servers.test.ts
  • mobile/src/home/home-relayed-servers.ts
  • mobile/src/home/use-home-server-agents.ts
  • mobile/src/home/use-mobile-home-data.ts
  • mobile/src/transport/connection/mobile-runtime-client-capabilities.ts
  • mobile/src/worktree/catalog/home-worktree-info.ts
  • mobile/src/worktree/execution-hosts/server-workspace-operations.ts
  • mobile/src/worktree/execution-hosts/server-workspaces.test.ts
  • mobile/src/worktree/execution-hosts/server-workspaces.ts
Files with no reviewable changes: 10

  • mobile/src/agents/MobileAgentListRows.tsx
  • mobile/src/agents/use-agent-list-row-actions.tsx
  • mobile/src/home/home-query-restore.ts
  • mobile/src/home/home-relayed-server-queries.test.ts
  • mobile/src/home/home-relayed-server-queries.ts
  • mobile/src/home/home-relayed-servers.test.ts
  • mobile/src/home/home-relayed-servers.ts
  • mobile/src/home/use-home-server-agents.ts
  • mobile/src/worktree/execution-hosts/server-workspace-operations.ts
  • mobile/src/worktree/execution-hosts/server-workspaces.ts

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

@AmethystLiang
AmethystLiang merged commit c508766 into main Nov 27, 2026
28 checks passed
saltyfireball pushed a commit to saltyfireball/orca that referenced this pull request Nov 27, 2026
…as in v1.4.279 (stablyai#50787)

Home's Agents and Feed stop merging in agents from servers a desktop relays to.
Home no longer reads a relayed server's rows whenever its row notice fires, which
made each such desktop refetch the server's whole workspace list and hash every
row. Its blur release, which dropped every row hold on the phone connection, goes
with it.

Kept: the shared relay capability, the relay host schema and the desktop protocol.
Home Bots still reads the relay list and listens for relayHostsChanged, and
workspace lists still read relayed rows through ServerRowSnapshots.

The retired-server eviction test now covers the shared ServerRowSnapshots.read
path rather than Home's private snapshots.

(cherry picked from commit c508766)
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