Skip to content

Cache desktop server renderers - #618

Merged
SawyerHood merged 1 commit into
mainfrom
bb/cache-desktop-switcher-servers-thr_dpsuff3tk9
Jul 11, 2026
Merged

SawyerHood merged 1 commit into
mainfrom
bb/cache-desktop-switcher-servers-thr_dpsuff3tk9

Conversation

@SawyerHood

Copy link
Copy Markdown
Collaborator

Summary

  • keep one live renderer per visited desktop server so switching preserves navigation and UI state
  • scope native browser views and desktop IPC to the owning cached renderer, with cleanup when servers or windows close
  • make Cmd+R reload the active server and Cmd+Shift+R force-reload it
  • inherit tooltip foreground color so server URL/status text stays readable across themes

Test plan

  • pnpm exec turbo run typecheck test --filter=@bb/app --filter=@bb/desktop --force
  • pnpm exec turbo run build --filter=@bb/desktop
  • signed production package plus pnpm exec turbo run smoke:packaged --filter=@bb/desktop --force

Risk

Cached renderers intentionally retain their server connection and state until the server is removed or the desktop window closes.

@SawyerHood
SawyerHood merged commit 4396198 into main Jul 11, 2026
10 checks passed
@SawyerHood
SawyerHood deleted the bb/cache-desktop-switcher-servers-thr_dpsuff3tk9 branch July 11, 2026 15:20
SawyerHood added a commit that referenced this pull request Jul 12, 2026
…628)

## Summary

- remove the desktop multi-server feature now that multi-machine covers
it: ServerRail sidebar switcher, Settings › Servers, server tiles, the
`bbDesktop.servers` preload API/IPC, the multi-entry `servers.json`
registry, per-window active-server state, the per-server renderer view
cache (reverts the #618 rescoping of browser views/IPC/reload
shortcuts), status/attention polling, and the `autoConnectToLocalServer`
setting
- server targeting now lives entirely in the native **Window ▸ Server**
menu: "This Mac", the bb Connect account servers (synced
main-process-side from the local server's connect plugin, authenticated
with the existing Connect session-cookie handshake), and an optional
custom URL entered through a native "Set Server URL…" dialog
- the target is global (switching reloads all windows), persisted to
`server-target.json`; the local runtime always starts, with
popout/system-config sync/auto-update pinned to it

## Test plan

- `pnpm exec turbo run typecheck` (whole workspace, 45/45)
- `pnpm exec turbo run test --filter=@bb/app --force` (1379 tests)
- `pnpm exec turbo run typecheck test --filter=@bb/desktop --force` (196
tests, incl. new server-target and reworked connect-sync coverage)
- `pnpm run package && pnpm run smoke:packaged` in `apps/desktop`
(packaged app boots, preload bridge answers)

## Risk

- old `servers.json` entries are not migrated; previously added
manual/connect servers reset to "This Mac" and can be re-picked from the
menu
- entering a custom URL no longer probes reachability; an unreachable
server shows a load error and you switch back via the menu
- the menu-open freshness trigger for the Connect list is best-effort
(`menu-will-show`); the list also refreshes on runtime start and every
10 minutes

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
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