Skip to content

v1.64.0

Choose a tag to compare

@github-actions github-actions released this 15 Oct 22:31
· 64 commits to main since this release
Immutable release. Only release title and notes can be modified.
faff683

1.64.0 (2026-10-15)

🟨πŸŸͺπŸŸ§πŸŸ¦β¬›πŸŸ₯ Generated clients, and operations is admin only (#57)

Generated clients

  • ⬛ trax client --target react --manifest <file> --out <dir> writes a frontend's typed client:
    each machine's twin and typed hooks, a typed function per train, the GraphQL types they use and
    run-progress hooks. --check exits 1 when the committed client is out of date. It deletes only files it wrote,
    and refuses to write through a link under --out.
  • πŸŸͺ🟦 Hosts call await app.RunTraxAsync(args); --trax-export-client <path> writes the client
    manifest without serving or opening a database.
  • 🟦 Every [TraxMutation]/[TraxQuery] train gets a persisted document the host registers. A
    client of an older shape gets CLIENT_OUTDATED, not a validation error.

Following a run

  • 🟨🟦 [TraxRunProgress] lets the caller who started a run read and follow it with
    runProgress(runId); nobody else can. ScheduleOptions.StartedBy carries the starter to every run
    of a manifest, and a retried run answers retriedAs. A queued run the host cannot read ends its stream with a
    problem after repeated failures; subscribe again.
  • β¬›πŸŸ¦ useRunProgress follows nothing after another user signs in until it is given a run id again, and
    followRunProgress ends with CONNECTION_CHANGED when configureTrax closes its socket.
  • πŸŸͺ🟦 A machine waiting on a run it invoked answers its owner invokedRun { runId }.

Breaking for clients

  • πŸŸͺ🟦 machineChanged is replaced by <machine>Changed(id), typed per machine.
  • πŸŸͺ🟦 Refusal codes are one enum, spelled GUARD_FAILED everywhere, extensions.code included.
  • πŸŸͺ🟦 Context and input enums of a machine are spelled as stored (HighPriority).
  • πŸŸͺ @traxsharp/state-machine drops useMachine, createSnapshotClient and createHttpExecutor;
    createMachineExecutor requires each machine's documents.
  • πŸŸͺ The IR's effect edge no longer carries the server's type name.
  • πŸŸͺ Generated code is client format 2: configureTrax({ url, headers, user }) re-renders mounted hooks onto the
    new connection, and useRemembered<Machine>() keeps each user's instance under its own key for that user. The
    runtime still serves format 1.
  • πŸŸͺ An effect-bound trigger takes no input in the generated send. Install graphql-ws beside the package.
  • πŸŸͺ A trigger bound with RunsOnce may not also be used on another edge; the build says so.
  • πŸŸͺ A request on a generated server made before the last configureTrax stops its controller with
    CONNECTION_CHANGED instead of failing as a retryable transport error.
  • 🟦πŸŸͺ A machine may not hold one of Trax's own enums; give it an enum of its own.
  • πŸŸͺ @traxsharp/state-machine has no runtime dependencies: valibot, which nothing used, is gone.

Operations is admin only

  • 🟦 Persisted-operation management moved to a root persistedOperations { ... } behind its own gate,
    GateManagement(policy, roles), in GraphQL and both dashboards. It is not served until a host declares that gate,
    and UsePersistedOperations no longer exposes the operations namespace. ExposeOperationsNamespace is removed.
  • 🟦πŸŸ₯ The management gate is checked on every dashboard read too, its policies run in the caller's scope, and a
    store registration that declares a different gate from UsePersistedOperations is refused at startup.
  • 🟦 operations holds only what the operations dashboard does: machineDocuments, declaredChain, and the
    execution(id), manifest(id) and workQueue(id) reads are removed in favour of the client manifest export,
    runGraph and the detail reads. Monitors read /trax/health.

See the machine wire changes migration guide for the upgrade.

All changes

Features

  • 🟨πŸŸͺπŸŸ§πŸŸ¦β¬›πŸŸ₯ generated clients, and operations is admin only (#57) (faff683)