Skip to content

fix: route command palette entities directly - #467

Merged
pedronauck merged 1 commit into
mainfrom
linear-eng-131
Aug 25, 2026
Merged

pedronauck merged 1 commit into
mainfrom
linear-eng-131

Conversation

@pedronauck

Copy link
Copy Markdown
Member

Summary

Linear ENG-131: [Web] Command palette actions should go direct.

Concrete rows in the OS command palette now open the entity's identity-bearing detail/action target in one selection. Catalog commands remain catalog commands, while root search and pushed domain views share the same landing behavior.

Root cause

Most domain row seeds used searchRoute or tasksRoute, which produced a catalog pathname with a q/query filter. The row therefore discarded the entity identity and made the operator select the same entity again. The two palette openers also had separate behavior, and foreign-workspace rows could be opened before the window-manager workspace fence was ready.

Implementation

  • Replaced catalog-plus-filter entity routes with explicit routes for Tasks, Loops, Jobs, Triggers, Bridges, Agents, Marketplace entries, Knowledge, Network channels, and existing session/tab targets.
  • Removed the obsolete searchRoute and tasksRoute helpers.
  • Added explicit row ownership and identifiers instead of parsing IDs back out of row keys.
  • Added a shared root-owned domain opener used by both root and pushed views. It waits until the runtime workspace and the live window-manager snapshot agree, switches to the owning workspace for global rows, and reports refused/unreachable opens instead of silently falling back.
  • Kept Worktree rows on the canonical scope-selection action, including the owning workspace.
  • Added Vault ref route state so a concrete secret opens in the existing master/detail surface and missing or rejected inventory resolution is shown as an unavailable target.
  • Routed installed Extensions through the existing Marketplace detail surface with entry and installed-name identity.
  • Added the headline browser scenario and focused unit coverage for identity, similar names, global workspace ownership, stale window-manager state, pushed-view persistence, coordinator refusal, Vault selection, and Vault inventory failure.

Review

A standalone GPT-5.6-Sol (high reasoning) review was run without the deep-review skill. All five actionable findings were addressed: root-owned pending state for pushed views, truthful QA scope, command/workspace readiness barriers, null coordinator results, and Vault rejected-inventory handling.

Verification

Passed:

  • bunx turbo run lint typecheck --filter=compozy-web (zero lint warnings/errors; typecheck and codegen-check passed).
  • bunx turbo run test --filter=compozy-web -- --run src/systems/os/components/__tests__/os-palette-view-stack.test.tsx src/systems/os/hooks/__tests__/use-os-palette-root.test.tsx src/systems/os/lib/__tests__/os-palette-domain-search.test.ts src/systems/vault/hooks/__tests__/use-vault-page.test.tsx src/systems/vault/lib/__tests__/vault-route-search.test.ts (5 files, 82 tests).
  • git diff --check.
  • Isolated browser walk recorded in docs/qa/reports/2026-08-24-eng-131-palette-direct.md, with clean QA teardown evidence. The workspace Loop route and an independent deep link both rendered the same detail page.

make gate was run as requested. Its lint, typecheck, codegen, and web execution started cleanly, but the full web lane ended with one unrelated failure in src/systems/os/hooks/__tests__/use-window-manager-stream.test.tsx (Should reconcile a removed workspace before opening the replacement stream); the other 10 tests in that file passed, and the same failure reproduced in isolation. No unrelated production or test changes were made. make verify and make gate-full were intentionally not run per the task instruction; CI is expected to provide the full gate.

Risks and follow-up

  • The direct route now depends on the entity identifier and, for global rows, the owning workspace being present in the source projection. Deleted or unavailable targets show an explicit failure instead of a catalog fallback.
  • The targeted QA scenario is marked pass only for the walked workspace-Loop journey; the adjacent broad palette scenarios remain explicitly untested rather than being over-claimed.
  • The new E2E coverage is in web/e2e/__tests__/os-shell.spec.ts and will run in CI.

Compozy Impact Audit

  • Native tools: no impact. compozy__cmd_palette_list, compozy__cmd_palette_invoke, descriptors, schemas, capability gates, and digests are unchanged; only web row projection and routing changed.
  • Extensibility and hooks: no runtime extension/config lifecycle change. Extension-contributed palette commands retain their existing dispatch path; installed extensions reuse the existing Marketplace detail surface. No config.toml, registry, hook, skill, resource, or bridge SDK changes.
  • Workspace data isolation: in scope and covered. Global rows carry workspaceId; the shared opener switches to the owner and waits for both runtime and window-manager workspace identity before opening. Loop routes carry the workspace search parameter, Network/Knowledge keep their workspace parameters, and tests cover foreign-workspace routing and stale command snapshots.
  • Official Compozy skill: no impact. No public tool ID, CLI path, hook event, capability, memory, or network contract changed, so skills/compozy/ remains unchanged.

@vercel

vercel Bot commented Aug 25, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
compozy-site Ready Ready Preview Aug 25, 2026 1:53am

Request Review

@coderabbitai

coderabbitai Bot commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

Next included review available in 57 seconds.

View limit details

Limit details: You’ve used all 8 included reviews currently available.

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro Plus

Run ID: e15889bc-d9f8-49b0-aeb6-0f93c06ef579

📥 Commits

Reviewing files that changed from the base of the PR and between b386cd5 and 41fda69.

⛔ Files ignored due to path filters (6)
  • docs/qa/reports/2026-08-24-eng-131-palette-direct.md is excluded by !**/*.md
  • docs/qa/scenarios/ET-palette-action-panel.md is excluded by !**/*.md
  • docs/qa/scenarios/ET-palette-direct-entity-routes.md is excluded by !**/*.md
  • docs/qa/scenarios/ET-palette-domain-views.md is excluded by !**/*.md
  • docs/qa/scenarios/ET-palette-nested-views.md is excluded by !**/*.md
  • web/e2e/__tests__/os-shell.spec.ts is excluded by !web/e2e/**
📒 Files selected for processing (17)
  • web/src/systems/os/components/__tests__/os-palette-view-stack.test.tsx
  • web/src/systems/os/components/os-command-palette.tsx
  • web/src/systems/os/components/os-palette-view-stack.tsx
  • web/src/systems/os/hooks/__tests__/use-os-palette-root.test.tsx
  • web/src/systems/os/hooks/use-os-palette-domain-open.ts
  • web/src/systems/os/hooks/use-os-palette-domain-search.ts
  • web/src/systems/os/hooks/use-os-palette-domain-view.tsx
  • web/src/systems/os/hooks/use-os-palette-root.ts
  • web/src/systems/os/lib/__tests__/os-palette-domain-search.test.ts
  • web/src/systems/os/lib/cmd-palette-row-actions.ts
  • web/src/systems/os/lib/os-palette-domain-search.ts
  • web/src/systems/os/lib/os-palette-worktree-selection.ts
  • web/src/systems/vault/hooks/__tests__/use-vault-page.test.tsx
  • web/src/systems/vault/hooks/use-vault-page.ts
  • web/src/systems/vault/lib/__tests__/vault-route-search.test.ts
  • web/src/systems/vault/lib/vault-route-search.ts
  • web/src/systems/vault/routes/vault-page.tsx

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

Comment @coderabbitai help to get the list of available commands.

@github-actions

Copy link
Copy Markdown
Contributor

React Doctor found no new issues. 🎉

Reviewed by React Doctor for commit 41fda69.

@pedronauck pedronauck changed the title [Web] Command palette actions should go direct fix: route command palette entities directly Aug 25, 2026
@greptile-apps

greptile-apps Bot commented Aug 25, 2026

Copy link
Copy Markdown

Greptile Summary

The PR changes command-palette entity rows to open identity-bearing domain routes directly and introduces a shared workspace-aware opener for root and pushed views.

  • Adds direct routes for tasks, loops, jobs, triggers, bridges, agents, marketplace entries, knowledge, network channels, and Vault secrets.
  • Coordinates foreign-workspace rows with runtime and window-manager readiness.
  • Adds Vault route-driven secret selection and targeted unit, browser, and QA coverage.

Confidence Score: 4/5

The PR should not merge until deferred palette opens are cancelled or expired when the operator moves on, preventing stale navigation after readiness recovery.

The new opener retains a selected row across palette dismissal without cancellation and can execute that old navigation much later when workspace and window-manager readiness align.

Files Needing Attention: web/src/systems/os/hooks/use-os-palette-domain-open.ts

Important Files Changed

Filename Overview
web/src/systems/os/hooks/use-os-palette-domain-open.ts Adds shared deferred workspace-aware opening, but pending requests can survive indefinitely and navigate after the operator changes intent.
web/src/systems/os/hooks/use-os-palette-domain-search.ts Projects concrete domain identities, ownership, and worktree actions into command-palette rows.
web/src/systems/os/lib/os-palette-domain-search.ts Replaces catalog-filter helpers with explicit identity-bearing routes for supported domains.
web/src/systems/vault/hooks/use-vault-page.ts Synchronizes exact Vault secret selection with route state and distinguishes unavailable inventory from missing secrets.
web/src/systems/vault/routes/vault-page.tsx Presents direct-selection failures instead of silently falling back to the Vault catalog.
web/e2e/tests/os-shell.spec.ts Adds an isolated browser scenario proving a seeded loop row opens its detail route.

Sequence Diagram

sequenceDiagram
  participant User
  participant Palette
  participant Opener
  participant Workspace
  participant WindowManager
  User->>Palette: Select concrete domain row
  Palette->>Opener: openDomainRow(row)
  Opener->>Palette: Dismiss
  alt Workspace and commands ready
    Opener->>WindowManager: userOpen(app, identity route)
  else Foreign or stale workspace
    Opener->>Workspace: setActiveWorkspaceId(owner)
    Opener->>Opener: Store pending row
    Workspace-->>Opener: Runtime workspace becomes ready
    WindowManager-->>Opener: Live matching snapshot
    Opener->>WindowManager: userOpen(pending row)
  end
Loading

Reviews (1): Last reviewed commit: "fix: route command palette entities dire..." | Re-trigger Greptile

Comment on lines +55 to +67
useEffect(() => {
const pending = pendingRef.current;
if (pending === null) return;
if (
pending.workspaceId !== runtimeWorkspaceId?.trim() ||
!commandAvailable ||
pending.workspaceId !== commandWorkspaceId
) {
return;
}
pendingRef.current = null;
openDomainRoute(coordinator, pending.row);
}, [commandAvailable, commandWorkspaceId, coordinator, runtimeWorkspaceId]);

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

P1 Stale pending navigation remains armed

When a workspace-owned row is selected while its window-manager commands are unavailable, pendingRef survives palette dismissal without cancellation or expiry. If readiness returns after the operator has moved on, the old row opens unexpectedly and interrupts the operator's current view.

@pedronauck

Copy link
Copy Markdown
Member Author

CI watch complete (run 32799116684, attempt 2): all frontend, desktop, Go format/lint/build/boundaries, Darwin peer identity, Preflight, PR title, React Doctor (100/100), Vercel, and Greptile checks passed. The two Go race shards still fail on unchanged out-of-scope suites after one retry: shard 2 has 2 failures in internal/daemon TestBootLoopReconciliationBarrier (the daemon never entered the Loop neutralization barrier); shard 1 has 952 internal/store/globaldb failures caused by SQLite migration/checkpoint context deadlines (including checkpoint sqlite wal and migration statements). Verify only propagates GO_TEST_RESULT=failure. No daemon/store files were changed. CodeRabbit was queried in both allowed rounds; it returned no reviews, threads, or actionable issues because the repository hit its included-review rate limit.

@pedronauck
pedronauck merged commit 1fd1c9a into main Aug 25, 2026
40 of 47 checks passed
@pedronauck
pedronauck deleted the linear-eng-131 branch August 25, 2026 13:06
This was referenced Aug 25, 2026
This was referenced Sep 1, 2026
This was referenced Sep 27, 2026

This branch was successfully deployed

1 active deployment
Preview — 41fda69f Deployed Aug 25, 2026 by vercel[bot]
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