@kky42/pievo-server 4.2.0 → 5.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (38) hide show
  1. package/.output/nitro.json +1 -1
  2. package/.output/public/assets/{MarkdownView-C9-AzIkl.js → MarkdownView-T28pBEgh.js} +1 -1
  3. package/.output/public/assets/{actionUi-D47jwMfh.js → actionUi-CY207nNM.js} +1 -1
  4. package/.output/public/assets/app-Cye1TgwS.css +2 -0
  5. package/.output/public/assets/index-BxXrF3gW.js +10 -0
  6. package/.output/public/assets/loops._loopId-DuSEcu38.js +2 -0
  7. package/.output/public/assets/{loops._loopId_.runs._runId-DW2HPjtj.js → loops._loopId_.runs._runId-vjQaPXEe.js} +2 -2
  8. package/.output/public/assets/{preload-helper-CbYqBpY9.js → preload-helper-B7p1iHUP.js} +2 -2
  9. package/.output/public/assets/routes-BUMEAWuS.js +1 -0
  10. package/.output/public/assets/routes-BrqOpUEi.js +1 -0
  11. package/.output/server/_ssr/{MachinesModal-DwHy2cis.mjs → MachinesModal-CB8rpDG2.mjs} +24 -12
  12. package/.output/server/_ssr/{actionUi-CszQXDSN.mjs → actionUi-CPYgZIr7.mjs} +40 -62
  13. package/.output/server/_ssr/{artifactFiles-DJiK99sF.mjs → artifactFiles-DLfSRhrV.mjs} +3 -3
  14. package/.output/server/_ssr/{artifactKind-DYMU0q3N.mjs → artifactKind-C0oXLA23.mjs} +2 -2
  15. package/.output/server/_ssr/{boot-CecCDRoH.mjs → boot-jtVCf_pN.mjs} +27 -91
  16. package/.output/server/_ssr/{loopApi-uEiBQ5YX.mjs → loopApi-0nR35Kh2.mjs} +8 -8
  17. package/.output/server/_ssr/{loopProjection-Bo54jjGd.mjs → loopProjection-ZNfSmA5e.mjs} +2 -2
  18. package/.output/server/_ssr/{loops._loopId-c1oRP7cr.mjs → loops._loopId-CcJ3rxCU.mjs} +9 -65
  19. package/.output/server/_ssr/{loops._loopId_.runs._runId-czMVvNsk.mjs → loops._loopId_.runs._runId-DFlrV3dJ.mjs} +2 -2
  20. package/.output/server/_ssr/{loops._loopId_.runs._runId-Dl0SwOlC.mjs → loops._loopId_.runs._runId-XkGF7HKo.mjs} +4 -4
  21. package/.output/server/_ssr/{machineFns-aw9xe5oz.mjs → machineFns-D-97a_hz.mjs} +2 -2
  22. package/.output/server/_ssr/{router-3OQ849sN.mjs → router-CZ9CFWS2.mjs} +15 -15
  23. package/.output/server/_ssr/{routes-CL4y6AEv.mjs → routes-BBmuVs6n.mjs} +2 -2
  24. package/.output/server/_ssr/{routes-nU2PDK3W.mjs → routes-JxTh5mbj.mjs} +2 -2
  25. package/.output/server/_ssr/{routes-CT5IdoiP.mjs → routes-fHRtSpkH.mjs} +5 -5
  26. package/.output/server/_ssr/ssr.mjs +22 -22
  27. package/.output/server/{_tanstack-start-manifest_v-_nMS2ozp.mjs → _tanstack-start-manifest_v-C9JsxlwC.mjs} +8 -8
  28. package/.output/server/drizzle/0003_run_status_ok.sql +13 -0
  29. package/.output/server/drizzle/meta/_journal.json +7 -0
  30. package/.output/server/index.mjs +47 -47
  31. package/drizzle/0003_run_status_ok.sql +13 -0
  32. package/drizzle/meta/_journal.json +7 -0
  33. package/package.json +1 -1
  34. package/.output/public/assets/app-C5xfpeJe.css +0 -2
  35. package/.output/public/assets/index-BgNjFXWE.js +0 -10
  36. package/.output/public/assets/loops._loopId-Bo63FXPQ.js +0 -2
  37. package/.output/public/assets/routes-C88oSApK.js +0 -1
  38. package/.output/public/assets/routes-CTCh8xYm.js +0 -1
@@ -1,13 +1,13 @@
1
1
  import { o as __toESM } from "../_runtime.mjs";
2
- import { Y as validateLoopTags, h as CODING_AGENTS } from "./boot-CecCDRoH.mjs";
2
+ import { Y as validateLoopTags, h as CODING_AGENTS } from "./boot-jtVCf_pN.mjs";
3
3
  import { g as require_react, h as require_jsx_runtime } from "../_libs/@base-ui/react+[...].mjs";
4
4
  import { d as useNavigate, u as Link } from "../_libs/@tanstack/react-router+[...].mjs";
5
5
  import { _ as runLoop, a as deriveLoopLifecycle, g as pauseLoop, h as patchLoop, i as deleteLoop, l as getLoopDetail, o as getArtifact, p as loadOlderRuns, r as daemonStopSupport, s as getArtifacts, t as DAEMON_UPGRADE_REQUIRED, v as startLoop, y as stopLoop } from "./lifecycleUi-Bd7_sthp.mjs";
6
- import { A as sectionHeadCls, C as labelCls, E as rel, M as tsShort, O as runPulseStyle, P as useFlash, S as inputCls, _ as dur, a as LoadErrorCard, b as focusRing, d as btnPrimary, f as btnQuiet, h as dotLabel, i as FlashLine, j as selectCls, l as btn, m as dotColor, n as ConfirmBar, o as Loading, r as ErrorBanner, u as btnDanger, v as fmt, x as humanBytes } from "./actionUi-CszQXDSN.mjs";
7
- import { a as Timeline, l as mergeRuns, n as MachinesModal, t as LoopOverview } from "./MachinesModal-DwHy2cis.mjs";
8
- import { n as artifactKind, t as Route } from "./artifactKind-DYMU0q3N.mjs";
6
+ import { A as tsShort, E as runSwatch, M as useFlash, O as sectionHeadCls, T as runPulseStyle, a as LoadErrorCard, b as inputCls, d as btnPrimary, f as btnQuiet, g as fmt, h as dur, i as FlashLine, k as selectCls, l as btn, m as dotLabel, n as ConfirmBar, o as Loading, r as ErrorBanner, u as btnDanger, v as focusRing, w as rel, x as labelCls, y as humanBytes } from "./actionUi-CPYgZIr7.mjs";
7
+ import { a as Timeline, l as mergeRuns, n as MachinesModal, t as LoopOverview } from "./MachinesModal-CB8rpDG2.mjs";
8
+ import { n as artifactKind, t as Route } from "./artifactKind-C0oXLA23.mjs";
9
9
  import { t as MarkdownView } from "./MarkdownView-BOe75tli.mjs";
10
- //#region node_modules/.nitro/vite/services/ssr/assets/loops._loopId-c1oRP7cr.js
10
+ //#region node_modules/.nitro/vite/services/ssr/assets/loops._loopId-CcJ3rxCU.js
11
11
  var import_react = /* @__PURE__ */ __toESM(require_react());
12
12
  var import_jsx_runtime = require_jsx_runtime();
13
13
  /** Download URL for one loop file. Each path segment is encoded independently so
@@ -301,9 +301,6 @@ function initState(initial) {
301
301
  model: initial?.model ?? "",
302
302
  reasoningEffort: initial?.reasoningEffort ?? "",
303
303
  prompt: initial?.prompt ?? "",
304
- keep: initial?.statusDefinitions?.keep ?? "",
305
- noChange: initial?.statusDefinitions?.noChange ?? "",
306
- block: initial?.statusDefinitions?.block ?? "",
307
304
  artifacts: (initial?.artifacts ?? []).join("\n")
308
305
  };
309
306
  }
@@ -405,10 +402,7 @@ var LoopForm = (0, import_react.forwardRef)(function LoopForm({ initial }, ref)
405
402
  const missing = [
406
403
  ["Name", form.name],
407
404
  ["Working directory", form.workdir],
408
- ["Prompt", form.prompt],
409
- ["Keep definition", form.keep],
410
- ["No-change definition", form.noChange],
411
- ["Block definition", form.block]
405
+ ["Prompt", form.prompt]
412
406
  ].find(([, value]) => !value.trim());
413
407
  if (missing) {
414
408
  setError(`${missing[0]} is required.`);
@@ -445,11 +439,6 @@ var LoopForm = (0, import_react.forwardRef)(function LoopForm({ initial }, ref)
445
439
  model: form.model.trim() || null,
446
440
  reasoningEffort: form.reasoningEffort.trim() || null,
447
441
  prompt: form.prompt,
448
- statusDefinitions: {
449
- keep: form.keep,
450
- noChange: form.noChange,
451
- block: form.block
452
- },
453
442
  artifacts: form.artifacts.split(/\r?\n/).filter((name) => name.length > 0)
454
443
  };
455
444
  } }));
@@ -654,28 +643,6 @@ var LoopForm = (0, import_react.forwardRef)(function LoopForm({ initial }, ref)
654
643
  onChange: (value) => set("prompt", value),
655
644
  rows: 10
656
645
  }),
657
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Section, {
658
- title: "Status definitions",
659
- hint: "All three definitions are required and are appended to every run."
660
- }),
661
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TextArea, {
662
- label: "keep",
663
- value: form.keep,
664
- onChange: (value) => set("keep", value),
665
- rows: 2
666
- }),
667
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TextArea, {
668
- label: "no-change",
669
- value: form.noChange,
670
- onChange: (value) => set("noChange", value),
671
- rows: 2
672
- }),
673
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(TextArea, {
674
- label: "block",
675
- value: form.block,
676
- onChange: (value) => set("block", value),
677
- rows: 2
678
- }),
679
646
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Section, {
680
647
  title: "Artifacts",
681
648
  hint: "Optional text/code file names such as .md, .html, .sh, .py, .json, or .csv (up to 4, 256 KB each) that runs update and the dashboard renders. One name per line. Every loop also has MEMORY.md."
@@ -1042,29 +1009,6 @@ function LoopDetailView({ id }) {
1042
1009
  children: loop.prompt
1043
1010
  })
1044
1011
  }),
1045
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Config, {
1046
- label: "Status definitions",
1047
- children: /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("ul", {
1048
- className: "space-y-1",
1049
- children: [
1050
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("li", { children: [
1051
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("b", { children: "keep:" }),
1052
- " ",
1053
- loop.statusDefinitions.keep
1054
- ] }),
1055
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("li", { children: [
1056
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("b", { children: "no-change:" }),
1057
- " ",
1058
- loop.statusDefinitions.noChange
1059
- ] }),
1060
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("li", { children: [
1061
- /* @__PURE__ */ (0, import_jsx_runtime.jsx)("b", { children: "block:" }),
1062
- " ",
1063
- loop.statusDefinitions.block
1064
- ] })
1065
- ]
1066
- })
1067
- }),
1068
1012
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Config, {
1069
1013
  label: "Artifacts",
1070
1014
  children: loop.artifacts.length ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)("ul", {
@@ -1127,7 +1071,7 @@ function EditHead({ name, onBack }) {
1127
1071
  }),
1128
1072
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)("p", {
1129
1073
  className: "mt-1.5 text-meta text-secondary",
1130
- children: "Edit tags, schedule, execution settings, prompt, status definitions, and artifact files."
1074
+ children: "Edit tags, schedule, execution settings, prompt, and artifact files."
1131
1075
  })
1132
1076
  ] });
1133
1077
  }
@@ -1176,7 +1120,7 @@ function RunsSection({ loopId, summary, runs, older, onMore, onPickRun }) {
1176
1120
  className: "flex items-start gap-2.5 py-2.5 hover:bg-raised",
1177
1121
  children: [/* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
1178
1122
  className: "mt-1 inline-block size-2.5 shrink-0 rounded-[2px]",
1179
- style: { background: dotColor(run) },
1123
+ style: runSwatch(run),
1180
1124
  title: dotLabel(run)
1181
1125
  }), /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
1182
1126
  className: "min-w-0 flex-1",
@@ -1198,7 +1142,7 @@ function RunsSection({ loopId, summary, runs, older, onMore, onPickRun }) {
1198
1142
  style: runPulseStyle
1199
1143
  }), "Running"]
1200
1144
  }) : run.attention ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("span", {
1201
- className: "font-medium text-running",
1145
+ className: "font-medium text-attention",
1202
1146
  children: ["! ", run.attention]
1203
1147
  }) : run.error || run.message || dotLabel(run)
1204
1148
  })]
@@ -1,6 +1,6 @@
1
1
  import { c as createFileRoute, s as lazyRouteComponent } from "../_libs/@tanstack/react-router+[...].mjs";
2
- //#region node_modules/.nitro/vite/services/ssr/assets/loops._loopId_.runs._runId-czMVvNsk.js
3
- var $$splitComponentImporter = () => import("./loops._loopId_.runs._runId-Dl0SwOlC.mjs");
2
+ //#region node_modules/.nitro/vite/services/ssr/assets/loops._loopId_.runs._runId-DFlrV3dJ.js
3
+ var $$splitComponentImporter = () => import("./loops._loopId_.runs._runId-XkGF7HKo.mjs");
4
4
  /** The trailing `_` on `$loopId` opts the run page out of the loop page's component,
5
5
  * so a run gets its own deep-linkable, back-button-friendly page. */
6
6
  var Route = createFileRoute("/loops/$loopId_/runs/$runId")({
@@ -2,10 +2,10 @@ import { o as __toESM } from "../_runtime.mjs";
2
2
  import { g as require_react, h as require_jsx_runtime } from "../_libs/@base-ui/react+[...].mjs";
3
3
  import { u as Link } from "../_libs/@tanstack/react-router+[...].mjs";
4
4
  import { b as stopRun, l as getLoopDetail, p as loadOlderRuns, u as getRunDiff } from "./lifecycleUi-Bd7_sthp.mjs";
5
- import { A as sectionHeadCls, O as runPulseStyle, _ as dur, a as LoadErrorCard, c as StatusPill, l as btn, o as Loading, s as Pill, u as btnDanger, v as fmt, x as humanBytes, y as fnum } from "./actionUi-CszQXDSN.mjs";
5
+ import { O as sectionHeadCls, T as runPulseStyle, _ as fnum, a as LoadErrorCard, c as StatusPill, g as fmt, h as dur, l as btn, o as Loading, s as Pill, u as btnDanger, y as humanBytes } from "./actionUi-CPYgZIr7.mjs";
6
6
  import { t as MarkdownView } from "./MarkdownView-BOe75tli.mjs";
7
- import { t as Route } from "./loops._loopId_.runs._runId-czMVvNsk.mjs";
8
- //#region node_modules/.nitro/vite/services/ssr/assets/loops._loopId_.runs._runId-Dl0SwOlC.js
7
+ import { t as Route } from "./loops._loopId_.runs._runId-DFlrV3dJ.mjs";
8
+ //#region node_modules/.nitro/vite/services/ssr/assets/loops._loopId_.runs._runId-XkGF7HKo.js
9
9
  var import_react = /* @__PURE__ */ __toESM(require_react());
10
10
  var import_jsx_runtime = require_jsx_runtime();
11
11
  /**
@@ -496,7 +496,7 @@ function RunDetailView({ loopId, runId }) {
496
496
  run.attention && /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Card, {
497
497
  label: "Needs attention",
498
498
  children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", {
499
- className: "break-words text-body font-medium text-running",
499
+ className: "break-words text-body font-medium text-attention",
500
500
  children: run.attention
501
501
  })
502
502
  }),
@@ -1,7 +1,7 @@
1
- import { F as machineIdFromToken, J as updateMachine, L as mintDeviceToken, P as loopsForMachine, S as getMachine, U as sha256, _ as createMachine$1, k as listMachines$1, o as daemonNeedsUpdate, s as ensureServer, t as MIN_DAEMON_VERSION, y as forceDeleteMachine } from "./boot-CecCDRoH.mjs";
1
+ import { F as machineIdFromToken, J as updateMachine, L as mintDeviceToken, P as loopsForMachine, S as getMachine, U as sha256, _ as createMachine$1, k as listMachines$1, o as daemonNeedsUpdate, s as ensureServer, t as MIN_DAEMON_VERSION, y as forceDeleteMachine } from "./boot-jtVCf_pN.mjs";
2
2
  import { r as createServerFn } from "./ssr.mjs";
3
3
  import { t as createServerRpc } from "./createServerRpc-BD8Xn_0_.mjs";
4
- //#region node_modules/.nitro/vite/services/ssr/assets/machineFns-aw9xe5oz.js
4
+ //#region node_modules/.nitro/vite/services/ssr/assets/machineFns-D-97a_hz.js
5
5
  /**
6
6
  * Latest published @kky42/pievo version for the dashboard's update hint: a plain
7
7
  * GET of the npm `latest` dist-tag. Fail-silent with a bounded timeout and a ~1h
@@ -1,12 +1,12 @@
1
- import { d as validOptionalPollString, f as validPollCurrentRun, l as readByteBody, n as POLL_HTTP_BODY_FIELDS, p as validPollWireId, s as ensureServer, u as readJsonBody } from "./boot-CecCDRoH.mjs";
1
+ import { d as validOptionalPollString, f as validPollCurrentRun, l as readByteBody, n as POLL_HTTP_BODY_FIELDS, p as validPollWireId, s as ensureServer, u as readJsonBody } from "./boot-jtVCf_pN.mjs";
2
2
  import { h as require_jsx_runtime } from "../_libs/@base-ui/react+[...].mjs";
3
3
  import { c as createFileRoute, i as HeadContent, l as createRootRoute, o as createRouter, r as Scripts } from "../_libs/@tanstack/react-router+[...].mjs";
4
- import { r as imageMime, t as Route$9 } from "./artifactKind-DYMU0q3N.mjs";
5
- import { t as Route$10 } from "./loops._loopId_.runs._runId-czMVvNsk.mjs";
6
- import { n as Route$11 } from "./routes-CT5IdoiP.mjs";
7
- //#region node_modules/.nitro/vite/services/ssr/assets/router-3OQ849sN.js
4
+ import { r as imageMime, t as Route$9 } from "./artifactKind-C0oXLA23.mjs";
5
+ import { t as Route$10 } from "./loops._loopId_.runs._runId-DFlrV3dJ.mjs";
6
+ import { n as Route$11 } from "./routes-fHRtSpkH.mjs";
7
+ //#region node_modules/.nitro/vite/services/ssr/assets/router-CZ9CFWS2.js
8
8
  var import_jsx_runtime = require_jsx_runtime();
9
- var app_default = "/assets/app-C5xfpeJe.css";
9
+ var app_default = "/assets/app-Cye1TgwS.css";
10
10
  var Route$8 = createRootRoute({
11
11
  head: () => ({
12
12
  meta: [
@@ -59,7 +59,7 @@ var Route$7 = createFileRoute("/machine/report")({ server: { handlers: { POST: a
59
59
  invalidBody: {},
60
60
  parseBody: (value) => value && typeof value === "object" ? value : {},
61
61
  handle: async (token, body) => {
62
- const { getGateway } = await import("./boot-CecCDRoH.mjs").then((n) => n.r).then((n) => n.t);
62
+ const { getGateway } = await import("./boot-jtVCf_pN.mjs").then((n) => n.r).then((n) => n.t);
63
63
  const r = await (await getGateway()).report(token, body);
64
64
  return Response.json(r.body, { status: r.status });
65
65
  }
@@ -84,7 +84,7 @@ var Route$4 = createFileRoute("/api/machine/status")({ server: { handlers: { GET
84
84
  const auth = request.headers.get("authorization") ?? "";
85
85
  const token = auth.startsWith("Bearer ") ? auth.slice(7) : "";
86
86
  if (!token) return Response.json({ error: "missing device token" }, { status: 401 });
87
- const { getGateway } = await import("./boot-CecCDRoH.mjs").then((n) => n.r).then((n) => n.t);
87
+ const { getGateway } = await import("./boot-jtVCf_pN.mjs").then((n) => n.r).then((n) => n.t);
88
88
  const r = await (await getGateway()).status(token);
89
89
  return Response.json(r.body, { status: r.status });
90
90
  } } } });
@@ -122,7 +122,7 @@ var Route$3 = createFileRoute("/api/machine/poll")({ server: { handlers: { POST:
122
122
  invalidJsonError: "invalid JSON body",
123
123
  parseBody: parsePollBody,
124
124
  handle: async (token, body) => {
125
- const { getGateway } = await import("./boot-CecCDRoH.mjs").then((n) => n.r).then((n) => n.t);
125
+ const { getGateway } = await import("./boot-jtVCf_pN.mjs").then((n) => n.r).then((n) => n.t);
126
126
  const r = await (await getGateway()).pollV4Wait(token, gatewayPollRequest(body));
127
127
  return Response.json(r.body, { status: r.status });
128
128
  }
@@ -150,7 +150,7 @@ var Route$2 = createFileRoute("/api/machine/cli")({ server: { handlers: { POST:
150
150
  invalidBodyError: "body must be exactly {argv:string[]}",
151
151
  parseBody: parseCliBody,
152
152
  handle: async (token, body) => {
153
- const { getCliGateway } = await import("./boot-CecCDRoH.mjs").then((n) => n.r).then((n) => n.t);
153
+ const { getCliGateway } = await import("./boot-jtVCf_pN.mjs").then((n) => n.r).then((n) => n.t);
154
154
  const r = await (await getCliGateway()).cli(token, body.argv);
155
155
  return Response.json(r.body, { status: r.status });
156
156
  }
@@ -192,7 +192,7 @@ var Route$1 = createFileRoute("/api/machine/run-files/$name")({ server: { handle
192
192
  if (!token) return Response.json({ error: "missing run token" }, { status: 401 });
193
193
  const name = fileName(request);
194
194
  if (name === null) return Response.json({ error: "bad file name" }, { status: 400 });
195
- const { getGateway } = await import("./boot-CecCDRoH.mjs").then((n) => n.r).then((n) => n.t);
195
+ const { getGateway } = await import("./boot-jtVCf_pN.mjs").then((n) => n.r).then((n) => n.t);
196
196
  const r = await (await getGateway()).readRunFile(token, name);
197
197
  if (r.status !== 200 || !r.bytes || !r.hash) return Response.json(r.body, { status: r.status });
198
198
  return new Response(new Uint8Array(r.bytes), {
@@ -210,12 +210,12 @@ var Route$1 = createFileRoute("/api/machine/run-files/$name")({ server: { handle
210
210
  if (!token) return Response.json({ error: "missing run token" }, { status: 401 });
211
211
  const name = fileName(request);
212
212
  if (name === null) return Response.json({ error: "bad file name" }, { status: 400 });
213
- const { LOOP_FILE_BYTE_CAP } = await import("./boot-CecCDRoH.mjs").then((n) => n.N).then((n) => n.Ht);
213
+ const { LOOP_FILE_BYTE_CAP } = await import("./boot-jtVCf_pN.mjs").then((n) => n.N).then((n) => n.Ht);
214
214
  const body = await readByteBody(request, LOOP_FILE_BYTE_CAP);
215
215
  if (body.kind === "too-large") return Response.json({ error: "file exceeds the loop-file size limit" }, { status: 413 });
216
216
  if (body.kind === "invalid") return Response.json({ error: "could not read file body" }, { status: 400 });
217
217
  const bytes = Buffer.from(body.bytes.buffer, body.bytes.byteOffset, body.bytes.byteLength);
218
- const { getGateway } = await import("./boot-CecCDRoH.mjs").then((n) => n.r).then((n) => n.t);
218
+ const { getGateway } = await import("./boot-jtVCf_pN.mjs").then((n) => n.r).then((n) => n.t);
219
219
  const r = await (await getGateway()).storeRunFile(token, name, bytes, request.headers.get("x-pievo-sha256"));
220
220
  return Response.json(r.body, { status: r.status });
221
221
  }
@@ -240,8 +240,8 @@ var Route = createFileRoute("/api/artifact/$loopId/$")({ server: { handlers: { G
240
240
  const segments = after.slice(slash + 1).split("/").map((s) => safeDecode(s));
241
241
  if (segments.some((s) => s === null)) return Response.json({ error: "bad path" }, { status: 400 });
242
242
  const relPath = segments.join("/");
243
- if (!await (await import("./boot-CecCDRoH.mjs").then((n) => n.N).then((n) => n.Dt)).getLoop(loopId)) return Response.json({ error: "not found" }, { status: 404 });
244
- const { readLoopArtifactBytes } = await import("./artifactFiles-DJiK99sF.mjs");
243
+ if (!await (await import("./boot-jtVCf_pN.mjs").then((n) => n.N).then((n) => n.Dt)).getLoop(loopId)) return Response.json({ error: "not found" }, { status: 404 });
244
+ const { readLoopArtifactBytes } = await import("./artifactFiles-DLfSRhrV.mjs");
245
245
  const r = await readLoopArtifactBytes(loopId, relPath);
246
246
  if (r.status !== 200 || !r.bytes) return Response.json({ error: "not found" }, { status: r.status });
247
247
  const filename = (r.filename || "file").replace(/["\\\r\n]/g, "_");
@@ -1,6 +1,6 @@
1
1
  import { h as require_jsx_runtime } from "../_libs/@base-ui/react+[...].mjs";
2
- import { n as Route, t as DashboardView } from "./routes-CT5IdoiP.mjs";
3
- //#region node_modules/.nitro/vite/services/ssr/assets/routes-CL4y6AEv.js
2
+ import { n as Route, t as DashboardView } from "./routes-fHRtSpkH.mjs";
3
+ //#region node_modules/.nitro/vite/services/ssr/assets/routes-BBmuVs6n.js
4
4
  var import_jsx_runtime = require_jsx_runtime();
5
5
  /** First-load failure screen — a calm retry instead of the router's default
6
6
  * error dump. Only the initial loader can land here; the in-page poll is
@@ -1,7 +1,7 @@
1
1
  import { h as require_jsx_runtime } from "../_libs/@base-ui/react+[...].mjs";
2
2
  import { f as useRouter } from "../_libs/@tanstack/react-router+[...].mjs";
3
- import { a as LoadErrorCard } from "./actionUi-CszQXDSN.mjs";
4
- //#region node_modules/.nitro/vite/services/ssr/assets/routes-nU2PDK3W.js
3
+ import { a as LoadErrorCard } from "./actionUi-CPYgZIr7.mjs";
4
+ //#region node_modules/.nitro/vite/services/ssr/assets/routes-JxTh5mbj.js
5
5
  var import_jsx_runtime = require_jsx_runtime();
6
6
  /** First-load failure screen — a calm retry instead of the router's default
7
7
  * error dump. Only the initial loader can land here; the in-page poll is
@@ -2,9 +2,9 @@ import { o as __toESM } from "../_runtime.mjs";
2
2
  import { g as require_react, h as require_jsx_runtime, s as TooltipProvider } from "../_libs/@base-ui/react+[...].mjs";
3
3
  import { c as createFileRoute, d as useNavigate, s as lazyRouteComponent } from "../_libs/@tanstack/react-router+[...].mjs";
4
4
  import { c as getConfig, f as listLoops, m as mintConnectKey, p as loadOlderRuns } from "./lifecycleUi-Bd7_sthp.mjs";
5
- import { b as focusRing, p as btnSm } from "./actionUi-CszQXDSN.mjs";
6
- import { c as listMachines, i as ModalHead, l as mergeRuns, n as MachinesModal, o as connectServerUrl, r as Modal, s as daemonConnectCommand, t as LoopOverview } from "./MachinesModal-DwHy2cis.mjs";
7
- //#region node_modules/.nitro/vite/services/ssr/assets/routes-CT5IdoiP.js
5
+ import { p as btnSm, v as focusRing } from "./actionUi-CPYgZIr7.mjs";
6
+ import { c as listMachines, i as ModalHead, l as mergeRuns, n as MachinesModal, o as connectServerUrl, r as Modal, s as daemonConnectCommand, t as LoopOverview } from "./MachinesModal-CB8rpDG2.mjs";
7
+ //#region node_modules/.nitro/vite/services/ssr/assets/routes-fHRtSpkH.js
8
8
  var import_react = /* @__PURE__ */ __toESM(require_react());
9
9
  var import_jsx_runtime = require_jsx_runtime();
10
10
  function LoopCard({ loop, onOpen, onPickRun }) {
@@ -520,8 +520,8 @@ function DashboardView({ initial }) {
520
520
  }
521
521
  var headerBtn = "inline-flex shrink-0 cursor-pointer items-center rounded-full px-3 py-1.5 text-meta font-medium text-secondary transition-colors hover:bg-raised hover:text-display";
522
522
  var headerIconBtn = "shrink-0 cursor-pointer items-center rounded-full p-1.5 text-secondary transition-colors hover:bg-raised hover:text-display";
523
- var $$splitErrorComponentImporter = () => import("./routes-nU2PDK3W.mjs");
524
- var $$splitComponentImporter = () => import("./routes-CL4y6AEv.mjs");
523
+ var $$splitErrorComponentImporter = () => import("./routes-JxTh5mbj.mjs");
524
+ var $$splitComponentImporter = () => import("./routes-BBmuVs6n.mjs");
525
525
  var Route = createFileRoute("/")({
526
526
  ssr: false,
527
527
  loader: () => fetchLiveData(),
@@ -3414,7 +3414,7 @@ var defaultSerovalPlugins = [
3414
3414
  * the dev styles URL for route-scoped CSS collection.
3415
3415
  */
3416
3416
  async function getStartManifest(matchedRoutes) {
3417
- const { tsrStartManifest } = await import("../_tanstack-start-manifest_v-_nMS2ozp.mjs");
3417
+ const { tsrStartManifest } = await import("../_tanstack-start-manifest_v-C9JsxlwC.mjs");
3418
3418
  const startManifest = tsrStartManifest();
3419
3419
  let routes = startManifest.routes;
3420
3420
  routes[rootRouteId];
@@ -3436,83 +3436,83 @@ async function getStartManifest(matchedRoutes) {
3436
3436
  var manifest = {
3437
3437
  "08565e35f6a3dd06ef25401de0343976c47f7ae319d3baed6320b56dd3718311": {
3438
3438
  functionName: "runLoop_createServerFn_handler",
3439
- importer: () => import("./loopApi-uEiBQ5YX.mjs")
3439
+ importer: () => import("./loopApi-0nR35Kh2.mjs")
3440
3440
  },
3441
3441
  "08c28b892712a1b491b120b74c7dcb81761988d31ccea60216d1807b73c1182c": {
3442
3442
  functionName: "getRunDiff_createServerFn_handler",
3443
- importer: () => import("./loopApi-uEiBQ5YX.mjs")
3443
+ importer: () => import("./loopApi-0nR35Kh2.mjs")
3444
3444
  },
3445
3445
  "169566e7637a22599b4eb32ee3775574e99677406922bbef7482a102036c33dd": {
3446
3446
  functionName: "machineStatus_createServerFn_handler",
3447
- importer: () => import("./machineFns-aw9xe5oz.mjs")
3447
+ importer: () => import("./machineFns-D-97a_hz.mjs")
3448
3448
  },
3449
3449
  "23e290b2b7483ceea6fe669024c35b12c2c4ddd76649f6fab21c958ceda02940": {
3450
3450
  functionName: "listLoops_createServerFn_handler",
3451
- importer: () => import("./loopApi-uEiBQ5YX.mjs")
3451
+ importer: () => import("./loopApi-0nR35Kh2.mjs")
3452
3452
  },
3453
3453
  "27d7eba0b6a2257949392fdd56057275a5c5366484ae01faf3b5897a225ecd83": {
3454
3454
  functionName: "finalizeMachine_createServerFn_handler",
3455
- importer: () => import("./machineFns-aw9xe5oz.mjs")
3455
+ importer: () => import("./machineFns-D-97a_hz.mjs")
3456
3456
  },
3457
3457
  "5660ea82ea5ff2549e0ce2f8f070c54f3e9e24fee84d547601ef5d6ef49a4016": {
3458
3458
  functionName: "startLoop_createServerFn_handler",
3459
- importer: () => import("./loopApi-uEiBQ5YX.mjs")
3459
+ importer: () => import("./loopApi-0nR35Kh2.mjs")
3460
3460
  },
3461
3461
  "5e0d6b55f5629faac2f55a68661eeb82668b2be752192b16264ffb5cd1e6fabe": {
3462
3462
  functionName: "deleteLoop_createServerFn_handler",
3463
- importer: () => import("./loopApi-uEiBQ5YX.mjs")
3463
+ importer: () => import("./loopApi-0nR35Kh2.mjs")
3464
3464
  },
3465
3465
  "6850ba403da9dec5aff45794eb52636ca540ddec2d9e59f5c75ccbb852bfeacb": {
3466
3466
  functionName: "stopRun_createServerFn_handler",
3467
- importer: () => import("./loopApi-uEiBQ5YX.mjs")
3467
+ importer: () => import("./loopApi-0nR35Kh2.mjs")
3468
3468
  },
3469
3469
  "85fdf73d4fee43aed762f93c5d47d33200fbff39e2d082647dc921f610d32698": {
3470
3470
  functionName: "loadOlderRuns_createServerFn_handler",
3471
- importer: () => import("./loopApi-uEiBQ5YX.mjs")
3471
+ importer: () => import("./loopApi-0nR35Kh2.mjs")
3472
3472
  },
3473
3473
  "95b7483b333d7649e70c848319417e83c2af6a0327bbcda2d0e331f626dffe05": {
3474
3474
  functionName: "pauseLoop_createServerFn_handler",
3475
- importer: () => import("./loopApi-uEiBQ5YX.mjs")
3475
+ importer: () => import("./loopApi-0nR35Kh2.mjs")
3476
3476
  },
3477
3477
  "9befe6b8d67ccbbd7aa9b538bde2a161a9894761c8936761a9503fda1a88c0fc": {
3478
3478
  functionName: "patchLoop_createServerFn_handler",
3479
- importer: () => import("./loopApi-uEiBQ5YX.mjs")
3479
+ importer: () => import("./loopApi-0nR35Kh2.mjs")
3480
3480
  },
3481
3481
  "a6384dc7154d9930422d29396f5de64b3ac69c62ad3824bc4a22d745fc07b293": {
3482
3482
  functionName: "deleteMachine_createServerFn_handler",
3483
- importer: () => import("./machineFns-aw9xe5oz.mjs")
3483
+ importer: () => import("./machineFns-D-97a_hz.mjs")
3484
3484
  },
3485
3485
  "aa46310016bb8a58b273a648ffd498c87f1f450d12827e30110a3b83ba6a27d9": {
3486
3486
  functionName: "listMachines_createServerFn_handler",
3487
- importer: () => import("./machineFns-aw9xe5oz.mjs")
3487
+ importer: () => import("./machineFns-D-97a_hz.mjs")
3488
3488
  },
3489
3489
  "b050455aacc84dd2a2c9a45517826ad10f91d8f1545e87cc7015784cc7116a97": {
3490
3490
  functionName: "getLoopDetail_createServerFn_handler",
3491
- importer: () => import("./loopApi-uEiBQ5YX.mjs")
3491
+ importer: () => import("./loopApi-0nR35Kh2.mjs")
3492
3492
  },
3493
3493
  "b18bbec3d06dfc77714e1e527dfb9172fd7575a64a6c0d6e73ba6dc658dccf0d": {
3494
3494
  functionName: "getArtifacts_createServerFn_handler",
3495
- importer: () => import("./loopApi-uEiBQ5YX.mjs")
3495
+ importer: () => import("./loopApi-0nR35Kh2.mjs")
3496
3496
  },
3497
3497
  "cbb6a1b09b309459bbba3dc3851ae85fc468658b3cda77e22b6c6f3e28b65af4": {
3498
3498
  functionName: "getConfig_createServerFn_handler",
3499
- importer: () => import("./loopApi-uEiBQ5YX.mjs")
3499
+ importer: () => import("./loopApi-0nR35Kh2.mjs")
3500
3500
  },
3501
3501
  "ce43dcb9366e7c8f7338a6ad28e4290b75a5ee3b13d0d2c9cb585020008f12c6": {
3502
3502
  functionName: "mintConnectKey_createServerFn_handler",
3503
- importer: () => import("./loopApi-uEiBQ5YX.mjs")
3503
+ importer: () => import("./loopApi-0nR35Kh2.mjs")
3504
3504
  },
3505
3505
  "e233a461e4526dec3cc4cbaa891a7c3621d5967ce7f32b4fb17e9fb645857b9a": {
3506
3506
  functionName: "stopLoop_createServerFn_handler",
3507
- importer: () => import("./loopApi-uEiBQ5YX.mjs")
3507
+ importer: () => import("./loopApi-0nR35Kh2.mjs")
3508
3508
  },
3509
3509
  "ed10d5fe79208e5e0e4e18e4a17b18d7f7db4dd16204c00c3ac90c4644668841": {
3510
3510
  functionName: "getArtifact_createServerFn_handler",
3511
- importer: () => import("./loopApi-uEiBQ5YX.mjs")
3511
+ importer: () => import("./loopApi-0nR35Kh2.mjs")
3512
3512
  },
3513
3513
  "ed679b4e1e05e903a5d4ba4a70d9b9d883991ab22ed59b4d2d69078941818415": {
3514
3514
  functionName: "createMachine_createServerFn_handler",
3515
- importer: () => import("./machineFns-aw9xe5oz.mjs")
3515
+ importer: () => import("./machineFns-D-97a_hz.mjs")
3516
3516
  }
3517
3517
  };
3518
3518
  async function getServerFnById(id, access) {
@@ -5344,7 +5344,7 @@ var getBaseManifest = getProdBaseManifest;
5344
5344
  var createEarlyHintsForRequest = createEarlyHintsCollector;
5345
5345
  async function loadEntries() {
5346
5346
  const [routerEntry, startEntry, pluginAdapters] = await Promise.all([
5347
- import("./router-3OQ849sN.mjs"),
5347
+ import("./router-CZ9CFWS2.mjs"),
5348
5348
  import("./start-B5_9Z5W-.mjs"),
5349
5349
  import("./empty-plugin-adapters-DKUlnwwl.mjs")
5350
5350
  ]);
@@ -1,4 +1,4 @@
1
- //#region node_modules/.nitro/vite/services/ssr/assets/_tanstack-start-manifest_v-_nMS2ozp.js
1
+ //#region node_modules/.nitro/vite/services/ssr/assets/_tanstack-start-manifest_v-C9JsxlwC.js
2
2
  var tsrStartManifest = () => ({ routes: {
3
3
  __root__: {
4
4
  filePath: "/home/runner/work/pievo/pievo/packages/server/src/routes/__root.tsx",
@@ -16,30 +16,30 @@ var tsrStartManifest = () => ({ routes: {
16
16
  "/loops/$loopId_/runs/$runId"
17
17
  ],
18
18
  preloads: [
19
- "/assets/index-BgNjFXWE.js",
20
- "/assets/actionUi-D47jwMfh.js",
21
- "/assets/preload-helper-CbYqBpY9.js"
19
+ "/assets/index-BxXrF3gW.js",
20
+ "/assets/actionUi-CY207nNM.js",
21
+ "/assets/preload-helper-B7p1iHUP.js"
22
22
  ],
23
23
  scripts: [{ attrs: {
24
24
  type: "module",
25
25
  async: !0,
26
- src: "/assets/index-BgNjFXWE.js"
26
+ src: "/assets/index-BxXrF3gW.js"
27
27
  } }]
28
28
  },
29
29
  "/": {
30
30
  filePath: "/home/runner/work/pievo/pievo/packages/server/src/routes/index.tsx",
31
31
  children: void 0,
32
- preloads: ["/assets/routes-C88oSApK.js", "/assets/routes-CTCh8xYm.js"]
32
+ preloads: ["/assets/routes-BUMEAWuS.js", "/assets/routes-BrqOpUEi.js"]
33
33
  },
34
34
  "/loops/$loopId": {
35
35
  filePath: "/home/runner/work/pievo/pievo/packages/server/src/routes/loops.$loopId.tsx",
36
36
  children: void 0,
37
- preloads: ["/assets/loops._loopId-Bo63FXPQ.js", "/assets/MarkdownView-C9-AzIkl.js"]
37
+ preloads: ["/assets/loops._loopId-DuSEcu38.js", "/assets/MarkdownView-T28pBEgh.js"]
38
38
  },
39
39
  "/loops/$loopId_/runs/$runId": {
40
40
  filePath: "/home/runner/work/pievo/pievo/packages/server/src/routes/loops.$loopId_.runs.$runId.tsx",
41
41
  children: void 0,
42
- preloads: ["/assets/loops._loopId_.runs._runId-DW2HPjtj.js", "/assets/MarkdownView-C9-AzIkl.js"]
42
+ preloads: ["/assets/loops._loopId_.runs._runId-vjQaPXEe.js", "/assets/MarkdownView-T28pBEgh.js"]
43
43
  }
44
44
  } });
45
45
  //#endregion
@@ -0,0 +1,13 @@
1
+ -- Run status collapses to ok|block; per-loop status definitions are dropped.
2
+ -- DATA LOSS (intentional): every loop's keep/no-change/block definition text is
3
+ -- removed, and keep/no-change history becomes ok. Legacy done runs without a
4
+ -- status become errors so that done always means a reported status.
5
+ ALTER TABLE "runs" DROP CONSTRAINT "runs_status_check";--> statement-breakpoint
6
+ UPDATE "runs" SET "status" = 'ok' WHERE "status" IN ('keep', 'no-change');--> statement-breakpoint
7
+ UPDATE "runs" SET "phase" = 'error', "error" = coalesce("error", 'run protocol incomplete: the final response has no STATUS line') WHERE "phase" = 'done' AND "status" IS NULL;--> statement-breakpoint
8
+ UPDATE "runs" SET "status" = NULL WHERE "phase" <> 'done' AND "status" IS NOT NULL;--> statement-breakpoint
9
+ ALTER TABLE "runs" ADD CONSTRAINT "runs_status_check" CHECK ("runs"."status" IS NULL OR "runs"."status" IN ('ok', 'block'));--> statement-breakpoint
10
+ ALTER TABLE "runs" ADD CONSTRAINT "runs_done_status_check" CHECK (("runs"."phase" = 'done') = ("runs"."status" IS NOT NULL));--> statement-breakpoint
11
+ ALTER TABLE "loops" DROP COLUMN "status_keep";--> statement-breakpoint
12
+ ALTER TABLE "loops" DROP COLUMN "status_no_change";--> statement-breakpoint
13
+ ALTER TABLE "loops" DROP COLUMN "status_block";
@@ -22,6 +22,13 @@
22
22
  "when": 1793000000000,
23
23
  "tag": "0002_run_attention",
24
24
  "breakpoints": true
25
+ },
26
+ {
27
+ "idx": 3,
28
+ "version": "7",
29
+ "when": 1793100000000,
30
+ "tag": "0003_run_status_ok",
31
+ "breakpoints": true
25
32
  }
26
33
  ]
27
34
  }