Skip to content

CL-6362: Routines becomes a global-only surface - #119

Merged
TheGreatAxios merged 2 commits into
mainfrom
cl-6362-routines-global
Aug 20, 2026
Merged

TheGreatAxios merged 2 commits into
mainfrom
cl-6362-routines-global

Conversation

@TheGreatAxios

Copy link
Copy Markdown
Contributor

Summary

  • Routines moves from per-workbench chrome to one global page (/routines), added to the shell rail beside Files/Skills/Agents/Plugins/Insights. Every row: name, workbench attribution, running-or-not state, humanized schedule + next run, inline enable/disable, Run now, and an inline-expandable detail (recent runs + its delivery workbench).
  • Visibility resolves through bench membership (useBench().memberships, the /api/me/principals principal model) — aggregates across every bench the account belongs to, not just the currently selected one, and is never creator-scoped (GET /routines already lists every routine a bench's own grant covers). Data stays workbench-scoped; this is UI consolidation only.
  • Removed, not hidden: the workbench header's Routines and Insights buttons, the composer's /run command, and the canvas routine panel's list/runs views. The panel is editor-only now (create/edit), reached from the composer's /routine command, "New routine in this space", and the global page's own New/Edit actions.
  • In-room routine cards (created-routine notices, run-now approval cards) are untouched — "visible where it was made" stays true. The routine-created/enabled notice's copy no longer points to the retired "Routines panel".
  • check:ui-vocabulary passes; consumer language throughout (no raw cron strings — cadenceLabel/approximateNextRun are the only source).

Known gap (named, not half-built)

Run outcome delivery (a routine's own result messages landing in its delivery workbench) already exists via apps/hub/src/routine-launcher.ts's joinDeliveryWorkbench, covered by apps/hub/src/routine-launcher.test.ts — this PR surfaces that fact in the row ("Run updates post into ") but does not add new hub-level wiring or tests for it, since the mechanism predates this PR and lives outside apps/web/packages/chat-ui/packages/routines' scope here.

Creation-path polish beyond what already exists (in-room /routine create, "assign a workflow as a routine" from the library) was not in this box — the page, rail entry, and membership-based visibility are the complete slice; a richer creation flow is a follow-up.

Test plan

  • bun run typecheck (apps/web, packages/chat-ui, packages/routines)
  • bun test — apps/web (565 pass), packages/chat-ui (581 pass), packages/routines (228 pass)
  • bun run lint (prettier + eslint) — clean on all touched files
  • bun run check:ui-vocabulary — ok
  • New test: a second bench's routine (not the selected one, not created by the viewer's own principal) renders on /routines, proving membership-based aggregation

Covers CL-6362: GlobalRoutinesList rendering (workbench attribution,
state chips, schedule, inline enable/disable, Run now, inline-expandable
run detail), membership-based aggregation across every bench a signed-in
account belongs to (not just the selected one, never creator-scoped), the
Routines rail row, and removal of the per-workbench header buttons, the
`/run` slash command, and the canvas panel's list/runs views.
Routines moves from per-workbench chrome to a global page in the shell
rail, listing every routine across every workbench the account is a
member of (membership-resolved, never just the selected one or
creator-scoped) as rows: name, workbench attribution, running-or-not
state, humanized schedule + next run, inline enable/disable, Run now,
and an inline-expandable detail with recent runs and its delivery
workbench.

Data stays workbench-scoped (`GET /routines` is unchanged, tenant-scoped)
- this is UI consolidation only, aggregated client-side across bench
memberships the cheapest correct way.

Removed, not hidden: the workbench header's Routines and Insights
buttons, the composer's `/run` command, and the canvas routine panel's
list/runs views (`RoutineListPanel`, `RunsCanvasPanel`) - the panel is
editor-only now (create/edit), reached from the composer's `/routine`
command, "New routine in this space", and the global page's own actions.
In-room routine cards (created-routine notices, run-now approval cards)
are untouched - they stay "visible where it was made".

The routine-created/enabled in-room notice's copy no longer points to
the retired "Routines panel".
@TheGreatAxios
TheGreatAxios force-pushed the cl-6362-routines-global branch from 8a993c5 to 47f88d8 Compare August 20, 2026 13:52
@TheGreatAxios
TheGreatAxios merged commit 0e048f1 into main Aug 20, 2026
0 of 2 checks passed
@TheGreatAxios
TheGreatAxios deleted the cl-6362-routines-global branch August 25, 2026 15:28
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