Skip to content

feat(platform): give each automation a Versions tab - #4795

Merged
yannickmonney merged 4 commits into
mainfrom
feat/automation-versions-page
Oct 11, 2026
Merged

yannickmonney merged 4 commits into
mainfrom
feat/automation-versions-page

Conversation

@yannickmonney

Copy link
Copy Markdown
Contributor

What

An automation's history gets its own tab, Versions: what is live, every version saved, every time one went live — and deploying, rolling back and restoring in one click each.

  • The live card names the live version, since when, who put it live and through which door and client (in the app, with Claude Code through MCP), and how many of its runs are still going (they finish on their version). Roll back to vN puts back the version it replaced; with nothing live, it offers the latest.
  • Versions: every version, newest first, a page at a time — the Live badge or when it last went live, its message and lineage (Restores v3, Based on v1), who saved it and through what (Tale for the platform), what it changed against the version before (counts and parts, First version, or Not recorded for older versions), and its tests word. A row opens the version in the editor; its menu deploys or rolls back to it, restores it as the newest, or downloads its YAML.
  • Deployments (?tab=deployments): when, which version, deploy or rollback, what it replaced, who — and a version found live before the history began, marked as such.
  • One-click deploy (card and menus): the deploy names the live version on screen (expectedDeployedVersion); a success toast says runs already started keep their version and offers Undo; a raced deploy changes nothing and says who put which version live and when, with Show deployments; a version whose tests fail or that fails today's checks is refused in a dialog listing the problems, with Open vN in the editor. A trigger left off is said under the card, with Turn on the trigger.
  • Restore dialog: saves a copy of an older version on top of the latest (message prefilled, editable), the versions between stay; optional Make vN live right away; a version saved meanwhile is named and restored on top of; nothing saved when the latest already matches.
  • Who acted reads through one useActorLabel (you, a member, a former member once the directory answered, Tale, not recorded); useRunStarterLabel is a thin wrapper of it now.
  • The list's version count and a new row-menu item Version history open the tab; the version picker stays on every other tab. The old /versions link now opens the tab instead of redirecting.

Also

  • The version history read pages through the shared infinite-query lane; the deployments table gets a paged twin; the live card keeps the single read.
  • useTestStatusLabel (@tale/ui/test-results) returns the same function across renders — a fresh one rebuilt a table's columns every render, remounting every row (and dropping a row menu's button ref).
  • An empty version message reads No message in the picker too.
  • downloadYaml and an editorVersionLink helper are shared instead of copied; the door guard isAutomationWriteVia lives with the vocabulary.

Divergences from the design

  • "Was live until {date}" is not derivable from the history row (it carries when a version last went live) — the caption says Last went live {date}; the Deployments view tells the full timeline.
  • No result instead of "Not run" for a version without a test verdict (it may have no tests at all).
  • The compare page (Graph/Changes/YAML, "What changed", "Compare with live") is the next PR; until then a row opens the editor at that version.
  • Tables keep the shared DataTable's sideways scroll on phones (no card layout exists); the card's button stacks under its text.

Verification (local)

  • Platform tsc, oxlint on the changed files, platform i18n guards, server tests of the touched areas, UI suites (automations, settings, notifications, projects, components, hooks), the automations browser tests; @tale/ui tsc + unit; docs tests (EN/DE/FR parity); format check, lint:links, lint:manual, knip.
  • New unit tests: actor label, author words, live card, deploy hook (Undo, race, refusals, trigger, one at a time), both tables, restore dialog (stale, invalid, unchanged, deploy now), the page (views, download, restore), adapters (pages, cursors, caps), stale-refusal readers, link helpers, the shell's fourth tab.
  • Live on a local stack (own DB/ports): the page at 1440 and 390 px, deploy from the card → toast → Undo, a deploy raced behind the page's back (refused, named, Show deployments), restore v3 → v5 "Restores v3", a version with a failing test refused in the dialog, focus back on the row's menu button after the dialog and on the card's button after a deploy, Download YAML (ops__weekly-digest-v3.yml), and the trigger-off notice after a deploy from the Versions tab and from the editor (the feat(platform): answer version and deployment history in the app #4790 fix, now seen working).

The app reads a door from a refusal too (who put another version live,
through what), so the guard that tells a known door from an unknown one
lives beside the six doors in the shared schema, and the backend's
parseWriteVia reads through it instead of a second set.
useTestStatusLabel answered a new function every render. A table whose
columns depend on it rebuilt them on every render, and TanStack renders a
function cell as a component, so every row remounted: a row menu lost the
button a dialog returns focus to. The function now holds while the
language does.
An automation's history gets a fourth tab beside Editor, General and Runs:

- A card says which version is live, since when, who put it live and
  through which door and client, and how many of its runs are still
  going; it rolls back to the version that one replaced in one click, or
  offers the latest while nothing is live.
- Versions lists every version, newest first, a page at a time: live or
  when it last was, its message and lineage, who saved it and through
  what, what it changed against the one before, and its tests. A row opens
  it in the editor; its menu deploys it or rolls back to it, restores it
  as the newest version, or downloads its YAML.
- Deployments (`?tab=deployments`) lists every time a version went live.
- Every deploy names the live version on screen, so a deploy made
  meanwhile is refused and named rather than undone; a success offers
  Undo; a version that no longer passes the checks or whose tests fail is
  refused in a dialog with its problems; a trigger left off is said.
- Restore saves a copy of an older version on top of the latest, asks
  again on top of a version saved meanwhile, and can put it live at once.

Who acted reads through one useActorLabel, which the run starter label now
wraps. The list's version count and a row-menu item open the tab; the
version picker stays on every other tab. The version history pages through
the infinite-query lane; the deployments table gets a paged twin.
The workflow editor page in English, German and French gains "Versions
and deployments": the live card, the two lists and their columns, deploy
or roll back in one click with Undo, what a raced or refused deploy says,
and restoring an older version. Rolling back points there; the list page
names the version count and Version history.

The automations suite's tab-strip box names the new tab; AUTO-F139–F147,
AUTO-B24 and AUTO-A21 cover the live card, one-click deploy and Undo, the
race between two sessions, the refusal dialog, restore, the Deployments
view, the download, the list's links, read failures, and keyboard and
phone use. The automation reference names what unit tests own.
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