Pipe connected worker hosts into client host selectors#11226
Conversation
|
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 Powered by Oz |
There was a problem hiding this comment.
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-channellocal-devoption 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() { |
There was a problem hiding this comment.
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) |
There was a problem hiding this comment.
local-dev option. Local builds opening a fresh picker can no longer choose local-dev; preserve that local fallback when constructing the host list.
2b5408d to
5381c4d
Compare
Co-Authored-By: Oz <oz-agent@warp.dev>
5381c4d to
9a00284
Compare
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.tomlAlso loom
I have manually tested my changes locally with
./script/runLoom
https://www.loom.com/share/556238f3dee649ab929c5550aec7b2f5
Agent Mode
Co-Authored-By: Oz oz-agent@warp.dev