feat(agent-crew): add opt-in Explorer auto-open - #146
Conversation
Open the Agent Crew Explorer tab once per workspace without manual action. The client seeds and subscribes to the workspace directory, claims unseen workspace IDs through the agent-crew.auto-open.claim RPC, and opens the crew panel for newly claimed workspaces. Claims persist atomically in $PASEO_HOME/plugin-data/agent-crew/auto-open.json so a workspace is opened at most once across daemon restarts, reloads, and reconnects. Failed claim batches retry once after two seconds.
|
Hi @omercnet! Whenever you get a chance, I'd really appreciate a review of this when you have a spare moment. Happy to adjust anything — design, naming, docs — just say the word. Thanks! |
|
Updated in 21c374c. Auto-open is now an opt-in, host-scoped Agent Crew setting and defaults to off. Enabling seeds existing unclaimed workspaces and watches new ones; disabling stops queued/future chunks while allowing only the already-started claim chunk to finish. The update also adds complete pagination, a shared 1,000-ID RPC batch limit, chunk-specific one-time retries, stale-settings race protection, atomic claim persistence, and fail-closed validation for corrupt or malformed claim state. Existing README installation, update, usage, development, coverage, dependency, and release notes were preserved. Verified with |
|
Astra reviewed the implementation specifically for minimality. The settings UI, typed host settings, durable daemon claims, RPC batching, pagination, and registrations are necessary for the requested semantics and match existing plugin conventions. Applied Astra's actionable reduction in dbc4a10: I retained the small server/store helpers because they are direct test seams for persistence, corruption handling, and serialized claims; moving them into tests would reduce exported symbols but not the total change or runtime complexity. Reverified: |
|
Simplified further in a248b7a after clarifying the intended behavior: auto-open now applies only to workspace events observed while the setting is enabled. Removed the full workspace listing, pagination, cursor tracking, historical seed batching, and their tests. Enabling the setting no longer opens existing workspaces. Live-event batching, durable once-only claims, serialized retries, and disable/in-flight semantics remain. Net follow-up: 28 production lines removed. Reverified with |
|
Corrected the future-only implementation in 0b0a6c9.
This keeps the user-visible contract precise: enabling the setting does not open historical workspaces, while genuinely new live workspace IDs are opened once. Full verification remains green: |
What
Adds an optional Agent Crew Explorer auto-open preference. It is disabled by default.
When enabled, Agent Crew opens workspaces first observed as new after enablement. Existing workspaces are baselined only for exclusion and are never opened merely because the setting was turned on. Disabling stops queued and future opens; an RPC chunk already in flight is allowed to finish.
How
Open Agent Crew automaticallyswitch under the plugin settings screen.workspaces.list({ subscribe: {} }), ignores its initial subscription snapshot, and releases the owned subscription during cleanup.upsertevents for existing workspaces. Live updates received while the baseline is built are buffered and filtered against it.agent-crew.auto-open.claimin schema-aligned batches of at most 1,000 IDs.$PASEO_HOME/plugin-data/agent-crew/auto-open.json.Verification
npm run checknpm run typechecknpm test— 30 tests passingThe automated suite covers default-off behavior, existing-workspace exclusion, owned subscription lifecycle, disable/re-enable behavior, serialized in-flight claims, batch boundaries, chunk-specific retries, stale settings reads, claim serialization, persistence, and malformed stored state.