Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS
JavaScript ai-agentsdashboarddeveloper-toolsdigital-twinquantified-selfsecond-brainself-hostedtailscale
fix: gate fal and Runway backend pins on commission and FableLoom sync versions (#12431)
[._.]/ Adam Eivybdd5fb02de59
diff --git a/server/lib/creativeCommissionSpec.js b/server/lib/creativeCommissionSpec.jsindex 57652dfc38..c6a7208204 100644--- a/server/lib/creativeCommissionSpec.js+++ b/server/lib/creativeCommissionSpec.js@@ -32,15 +32,18 @@ export const COMMISSION_RENDER_BACKEND_AUTO = RENDER_TARGET_BACKEND_AUTO;// Image backends a commission may pin: the queueable image modes (local /// codex / grok / agy — `external` never queues) plus the auto sentinel.-// Derived from QUEUEABLE_IMAGE_MODES so a new backend needs no edit here.+// Derived from QUEUEABLE_IMAGE_MODES so a new backend needs no edit here, but it+// still needs a wire-version bump in every sync category that stores it+// (creativeCommissions, fableLoom) — see schemaVersions.test.js.export const CREATIVE_COMMISSION_IMAGE_MODES = Object.freeze([COMMISSION_RENDER_BACKEND_AUTO, ...QUEUEABLE_IMAGE_MODES,]);// Video backends a commission may pin: local (MLX runtimes), grok, fal, or// reactor, plus auto. Derived from VIDEO_GEN_MODES so a new backend needs no-// edit here — this enum is exactly what drifted client-side when fal (#6213)-// and reactor (#6214) shipped with no matching form edit.+// enum edit here (it does need a sync wire-version bump, see above) — this+// enum is exactly what drifted client-side when fal (#6213) and reactor (#6214)+// shipped with no matching form edit.export const CREATIVE_COMMISSION_VIDEO_MODES = Object.freeze([COMMISSION_RENDER_BACKEND_AUTO, ...VIDEO_GEN_MODES,]);diff --git a/server/lib/schemaVersions.js b/server/lib/schemaVersions.jsindex 2737b0fa4c..3af598eb6f 100644--- a/server/lib/schemaVersions.js+++ b/server/lib/schemaVersions.js@@ -478,7 +478,12 @@ export const PORTOS_SCHEMA_VERSIONS = Object.freeze({// author brief. A <=v8 peer would strip it during an unrelated whole-record// edit, so newer transfers are gated and legacy omissions restore the local// value through `preserveLegacySeriesDesign`.- fableLoom: 9,+ // v10 = `renderSettings.imageMode`/`videoMode` may name the fal image and+ // fal/Runway video backends. A <=v9 peer's `sanitizeFableLoomRenderSettings`+ // nulls an unknown mode on receive, and its next edit would LWW that lost pin+ // back onto the newer peer. Backend values in `IMAGE_GEN_MODES` /+ // `VIDEO_GEN_MODES` are pinned in schemaVersions.test.js to move with this.+ fableLoom: 10,// v1 = Creative Director projects (PostgreSQL `creative_director_projects`)// federated via the per-record peer-sync push pipeline (record kind// `creativeDirectorProject`, sync category `creativeDirectorProjects`, #1564).@@ -734,7 +739,12 @@ export const PORTOS_SCHEMA_VERSIONS = Object.freeze({// would reconstruct the brief without it and could push that downgrade back// through the brief-scoped LWW merge. Per-run recipes remain local because// syncWire already strips `runs[]`.- creativeCommissions: 4,+ // v5 = `generation.imageMode`/`videoMode` may pin the fal image and fal/Runway+ // video backends. A <=v4 peer's `coerceGenerationValue` turns an unknown enum+ // value into `auto`, and its next edit would LWW that un-pinned downgrade back+ // onto the newer peer. Any new `IMAGE_GEN_MODES`/`VIDEO_GEN_MODES` value needs+ // another bump (guarded in schemaVersions.test.js).+ creativeCommissions: 5,// v1 = standalone media-library federation (#1566). NOT a record kind — it's// the wire contract for the library-level asset manifest a full-sync peer// advertises at GET /api/peer-sync/library-manifest. The receiver-pull sweepdiff --git a/server/lib/schemaVersions.test.js b/server/lib/schemaVersions.test.jsindex 71b70b1a71..390fd6d0d5 100644--- a/server/lib/schemaVersions.test.js+++ b/server/lib/schemaVersions.test.js@@ -1,4 +1,5 @@import { describe, it, expect } from 'vitest';+import { IMAGE_GEN_MODES, VIDEO_GEN_MODES } from './generationModes.js';import {PORTOS_SCHEMA_VERSIONS,RECORD_KIND_SCHEMA_CATEGORIES,@@ -55,11 +56,28 @@ describe('PORTOS_SCHEMA_VERSIONS', () => {// adds the shared finite/renewable series-design brief.// Older peers stay behind the full render contract until they advertise// support for the additive fields.- expect(PORTOS_SCHEMA_VERSIONS.fableLoom).toBe(9);+ expect(PORTOS_SCHEMA_VERSIONS.fableLoom).toBe(10);});it('version-gates the additive Creative Commission taste brief shape', () => {- expect(PORTOS_SCHEMA_VERSIONS.creativeCommissions).toBe(4);+ expect(PORTOS_SCHEMA_VERSIONS.creativeCommissions).toBe(5);+ });++ it('moves the render-backend alphabets and their sync versions together', () => {+ // Older receivers coerce an unknown imageMode/videoMode to auto/null, then+ // LWW the lost pin back. Adding a backend means: update this snapshot AND+ // bump creativeCommissions + fableLoom (and their pins above).+ expect({+ image: [...IMAGE_GEN_MODES],+ video: [...VIDEO_GEN_MODES],+ creativeCommissions: PORTOS_SCHEMA_VERSIONS.creativeCommissions,+ fableLoom: PORTOS_SCHEMA_VERSIONS.fableLoom,+ }).toEqual({+ image: ['external', 'local', 'codex', 'grok', 'agy', 'fal'],+ video: ['local', 'grok', 'fal', 'reactor', 'runway'],+ creativeCommissions: 5,+ fableLoom: 10,+ });});});