Skip to content

Pipe connected worker hosts into client host selectors#11226

Open
dmichelin wants to merge 1 commit into
masterfrom
dan/remote-1644-known-workers-client
Open

Pipe connected worker hosts into client host selectors#11226
dmichelin wants to merge 1 commit into
masterfrom
dan/remote-1644-known-workers-client

Conversation

@dmichelin
Copy link
Copy Markdown
Contributor

@dmichelin dmichelin commented May 18, 2026

Description

This change adds connected worker hosts into the warp host selector chip. This query done every time the card pops up, so if a worker disconnects after startup or the hostname crashes the selector will not expose dead worker hosts.

Linked Issue

REMOTE-1644

Testing

  • cargo fmt --check --manifest-path /Users/dan/Development/warp/app/Cargo.toml

  • Also loom

  • I have manually tested my changes locally with ./script/run

Loom

https://www.loom.com/share/556238f3dee649ab929c5550aec7b2f5

Agent Mode

  • Warp Agent Mode - This PR was created via Warp's AI Agent Mode

Co-Authored-By: Oz oz-agent@warp.dev

@cla-bot cla-bot Bot added the cla-signed label May 18, 2026
@oz-for-oss
Copy link
Copy Markdown
Contributor

oz-for-oss Bot commented May 18, 2026

@dmichelin

I'm starting a first review of this pull request.

You can view the conversation on Warp.

I completed the review and no human review was requested for this pull request.

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

Copy link
Copy Markdown
Contributor

@oz-for-oss oz-for-oss Bot left a comment

Choose a reason for hiding this comment

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

Overview

This PR adds a connected self-hosted workers model backed by the public API and wires those worker host names into the orchestration config UI, run-agents confirmation card, and Cloud Mode host selector.

Concerns

  • ⚠️ [IMPORTANT] The connected-worker cache is not cleared when authentication is unavailable, so stale host slugs can remain visible/selectable after auth loss.
  • ⚠️ [IMPORTANT] The orchestration host picker no longer preserves the local-channel local-dev option for fresh selections.
  • ⚠️ [IMPORTANT] For this user-facing change, please include screenshots or a screen recording demonstrating it working end to end.

Security

  • Stale connected-worker host slugs can leak from one authenticated state into logged-out or next-user UI state unless the cache is cleared when auth is unavailable.

Verdict

Found: 0 critical, 3 important, 0 suggestions

Request changes

Comment /oz-review on this pull request to retrigger a review (up to 3 times on the same pull request).

Powered by Oz

}

pub fn refresh(&self, ctx: &mut ModelContext<Self>) {
if !AuthStateProvider::as_ref(ctx).get().is_logged_in() {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ [IMPORTANT] [SECURITY] Returning while logged out leaves the previous account's worker list in memory, and the selectors still read from that cache. Clear workers and emit Changed when auth is unavailable so private host slugs are not shown after logout or auth loss.

} else {
&["warp"]
};
let mut hosts = ConnectedSelfHostedWorkersModel::as_ref(ctx_dropdown)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

⚠️ [IMPORTANT] This rebuilds the picker only from connected workers/current selection and drops the previous local-channel local-dev option. Local builds opening a fresh picker can no longer choose local-dev; preserve that local fallback when constructing the host list.

@dmichelin dmichelin force-pushed the dan/remote-1644-known-workers-client branch 2 times, most recently from 2b5408d to 5381c4d Compare May 18, 2026 21:02
Co-Authored-By: Oz <oz-agent@warp.dev>
@dmichelin dmichelin force-pushed the dan/remote-1644-known-workers-client branch from 5381c4d to 9a00284 Compare May 18, 2026 21:26
@dmichelin dmichelin requested a review from a team May 18, 2026 23:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant