@voltro/cli 0.31.0 → 0.33.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.
- package/CHANGELOG.md +368 -0
- package/THIRD-PARTY-NOTICES.md +1 -29
- package/dist/apiBuild-C-x9YacA.js +2 -0
- package/dist/{apiBuild-CLPt-pX6.js → apiBuild-h9VHtnlw.js} +2 -2
- package/dist/bin.js +3 -3
- package/dist/checkCommand-DRovTKza.js +2 -0
- package/dist/{checkCommand-D7r6_pk7.js → checkCommand-xGhRFFg2.js} +330 -290
- package/dist/{commands-CNVVv03h.js → commands-CJfepbm4.js} +139 -13
- package/dist/{dbCommand-BH8GAYuf.js → dbCommand-DTLKAfbA.js} +431 -263
- package/dist/dbCommand-b1gum4td.js +2 -0
- package/dist/{dev-DdQEn2Ia.js → dev-C_P8FLSx.js} +2141 -2081
- package/dist/{dev-DOZVMVfi.js → dev-iiMtlkfs.js} +1 -1
- package/dist/index.js +1 -1
- package/dist/{inspectMetrics-BeEAnjqw.js → inspectMetrics-1xzTKAFx.js} +750 -685
- package/dist/{sdkgen-v9WV8zRi.js → sdkgen-C81QIkiL.js} +1 -1
- package/dist/serveCommand-DdaM4Hup.js +1608 -0
- package/dist/serveEntry.js +2 -2
- package/dist/{start-CI2QdKy9.js → start-C0koT0UO.js} +1 -1
- package/dist/startEntry.js +2 -2
- package/package.json +431 -18
- package/templates/AGENTS.md +1 -1
- package/templates/agent-docs/_index.md +1 -1
- package/templates/agent-docs/database/misc.md +37 -0
- package/templates/agent-docs/database/schema.md +4 -2
- package/templates/agent-docs/deployment.md +87 -1
- package/templates/agent-docs/plugins/audit.md +24 -0
- package/templates/agent-docs/plugins.md +50 -0
- package/templates/agent-docs/scheduling.md +4 -1
- package/templates/agent-docs/security.md +31 -1
- package/templates/agent-docs/whats-new.md +149 -59
- package/templates/apps/api-ai/package.json +7 -7
- package/templates/apps/api-auth/package.json +8 -8
- package/templates/apps/api-backend/package.json +7 -7
- package/templates/apps/api-backend-deactivation/package.json +7 -7
- package/templates/apps/api-backend-mail/package.json +8 -8
- package/templates/apps/api-backend-mariadb/package.json +9 -9
- package/templates/apps/api-backend-sqlite/package.json +8 -8
- package/templates/apps/api-backend-storage/package.json +8 -8
- package/templates/apps/api-cms/package.json +10 -10
- package/templates/apps/api-collab/package.json +8 -8
- package/templates/apps/api-data-advanced/package.json +8 -8
- package/templates/apps/api-durable/package.json +8 -8
- package/templates/apps/api-feature-flags/package.json +9 -9
- package/templates/apps/api-governance/package.json +8 -8
- package/templates/apps/api-kv/package.json +8 -8
- package/templates/apps/api-moderation/package.json +8 -8
- package/templates/apps/api-observability/package.json +8 -8
- package/templates/apps/api-ratelimit/package.json +8 -8
- package/templates/apps/api-rbac/package.json +8 -8
- package/templates/apps/api-rest/package.json +7 -7
- package/templates/apps/api-saas/package.json +11 -11
- package/templates/apps/api-saas-starter/package.json +10 -10
- package/templates/apps/api-search/package.json +8 -8
- package/templates/apps/api-status/package.json +8 -8
- package/templates/apps/api-versioning/package.json +8 -8
- package/templates/apps/api-webhooks/package.json +9 -9
- package/templates/apps/changelog/package.json +6 -6
- package/templates/apps/edge-functions/package.json +2 -2
- package/templates/apps/frontend-admin/package.json +8 -8
- package/templates/apps/frontend-app/package.json +8 -8
- package/templates/apps/frontend-auth/package.json +8 -8
- package/templates/apps/frontend-blank/package.json +7 -7
- package/templates/apps/frontend-cms/package.json +9 -9
- package/templates/apps/frontend-collab/package.json +9 -9
- package/templates/apps/frontend-contact/package.json +7 -7
- package/templates/apps/frontend-dashboard/package.json +7 -7
- package/templates/apps/frontend-docs/package.json +7 -7
- package/templates/apps/frontend-i18n/package.json +6 -6
- package/templates/apps/frontend-landing/package.json +7 -7
- package/templates/apps/frontend-portal/package.json +8 -8
- package/templates/apps/frontend-saas/package.json +8 -8
- package/templates/apps/frontend-spa/package.json +7 -7
- package/templates/apps/frontend-ssr/package.json +7 -7
- package/templates/apps/frontend-ssr-api/package.json +8 -8
- package/templates/apps/frontend-static-blog/package.json +6 -6
- package/templates/apps/frontend-status/package.json +8 -8
- package/templates/apps/mobile-app/package.json +2 -2
- package/dist/apiBuild-BOqL1dlg.js +0 -2
- package/dist/checkCommand-ClRvH_SN.js +0 -2
- package/dist/dbCommand-BwQ_Jl98.js +0 -2
- package/dist/serveCommand-KsKXXWn4.js +0 -1578
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import { t as e } from "./cliRuntime-Oh517vCV.js";
|
|
2
|
-
import { A as t, Ct as n, D as r, Dt as i, Et as a, F as o, I as s, M as c, N as l, O as u, P as d, R as f, S as p, X as m, Y as h, Z as g, _t as _, a as v, b as y, bt as b, c as ee, d as te, f as ne, gt as re, h as ie, ht as ae, j as oe, m as se, o as ce, p as le, s as ue, u as de, vt as fe, w as pe, x as me, xt as he, yt as ge } from "./inspectMetrics-
|
|
3
|
-
import { _ as _e, a as ve, c as ye, d as x, f as be, g as xe, h as Se, i as Ce, l as we, m as Te, n as Ee, o as De, p as Oe, s as ke, t as Ae, u as je, v as S, y as Me } from "./checkCommand-
|
|
2
|
+
import { A as t, Ct as n, D as r, Dt as i, Et as a, F as o, I as s, M as c, N as l, O as u, P as d, R as f, S as p, X as m, Y as h, Z as g, _t as _, a as v, b as y, bt as b, c as ee, d as te, f as ne, gt as re, h as ie, ht as ae, j as oe, m as se, o as ce, p as le, s as ue, u as de, vt as fe, w as pe, x as me, xt as he, yt as ge } from "./inspectMetrics-1xzTKAFx.js";
|
|
3
|
+
import { _ as _e, a as ve, c as ye, d as x, f as be, g as xe, h as Se, i as Ce, l as we, m as Te, n as Ee, o as De, p as Oe, s as ke, t as Ae, u as je, v as S, y as Me } from "./checkCommand-xGhRFFg2.js";
|
|
4
4
|
import { s as Ne } from "./seedRunner-Bqxgp7HZ.js";
|
|
5
5
|
import { n as Pe } from "./appModuleLoader-C9r9mxZt.js";
|
|
6
6
|
import { a as C, c as Fe, i as Ie, o as Le, s as Re } from "./devActivity-BhIu6ncs.js";
|
|
7
|
-
import {
|
|
7
|
+
import { Kt as ze, Rt as Be, Ut as Ve, an as He, c as Ue, f as We, i as Ge, l as Ke, o as qe, qt as Je, z as Ye } from "./dev-C_P8FLSx.js";
|
|
8
8
|
import { C as Xe, i as Ze, o as Qe } from "./frameworkTableAssembly-BwIrO5nv.js";
|
|
9
9
|
import { D as $e, E as et, N as tt, O as nt, T as rt, a as it, d as at, f as ot, h as st, i as ct, j as lt, k as ut, l as dt, m as ft, r as pt, u as mt } from "./fileConventions-Cof68_BL.js";
|
|
10
|
-
import { i as ht, n as gt, o as _t, s as vt } from "./apiBuild-
|
|
10
|
+
import { i as ht, n as gt, o as _t, s as vt } from "./apiBuild-h9VHtnlw.js";
|
|
11
11
|
import { r as yt } from "./appGraph-gQ_6GkQQ.js";
|
|
12
|
-
import { t as bt } from "./start-
|
|
12
|
+
import { t as bt } from "./start-C0koT0UO.js";
|
|
13
13
|
import { a as xt, i as St, n as Ct, r as wt, t as Tt } from "./cliArgs-qdZSElM3.js";
|
|
14
|
-
import { n as Et, r as Dt } from "./serveCommand-
|
|
15
|
-
import { c as Ot, r as kt, s as At } from "./dbCommand-
|
|
14
|
+
import { n as Et, r as Dt } from "./serveCommand-DdaM4Hup.js";
|
|
15
|
+
import { c as Ot, r as kt, s as At } from "./dbCommand-DTLKAfbA.js";
|
|
16
16
|
import { basename as w, dirname as T, isAbsolute as jt, join as E, relative as D, resolve as O, sep as Mt } from "node:path";
|
|
17
17
|
import { fileURLToPath as Nt, pathToFileURL as Pt } from "node:url";
|
|
18
18
|
import { FileSystem as Ft } from "@effect/platform";
|
|
@@ -870,10 +870,10 @@ never mint — inspect stays closed until an operator opens it.`);
|
|
|
870
870
|
}, Kr = async (e) => {
|
|
871
871
|
let t = await ue(e);
|
|
872
872
|
if (!t) {
|
|
873
|
-
let { loadApiConfig: t } = await import("./dev-
|
|
873
|
+
let { loadApiConfig: t } = await import("./dev-iiMtlkfs.js"), n = await t(e);
|
|
874
874
|
if (n) {
|
|
875
875
|
V.info("building api app", { app: n.name ?? "(unnamed)" });
|
|
876
|
-
let { runApiBuild: t, runServeBundleBuild: r } = await import("./apiBuild-
|
|
876
|
+
let { runApiBuild: t, runServeBundleBuild: r } = await import("./apiBuild-C-x9YacA.js");
|
|
877
877
|
await t(e);
|
|
878
878
|
try {
|
|
879
879
|
await r(e);
|
|
@@ -1092,10 +1092,10 @@ never mint — inspect stays closed until an operator opens it.`);
|
|
|
1092
1092
|
return t.ran ? t.exitCode : (yield* k.logError("no web app found at this path", { hint: "looked for app.config.ts with `type: 'web'`" }), 1);
|
|
1093
1093
|
}), Jr = async (t) => {
|
|
1094
1094
|
if (t.includes("--target")) {
|
|
1095
|
-
let { runSdkBuildCommand: e } = await import("./sdkgen-
|
|
1095
|
+
let { runSdkBuildCommand: e } = await import("./sdkgen-C81QIkiL.js");
|
|
1096
1096
|
return e(t);
|
|
1097
1097
|
}
|
|
1098
|
-
let n = t.find((e) => !e.startsWith("-")) ?? process.cwd(), r = await e(qr(n), { scope: "voltro:build" }), i =
|
|
1098
|
+
let n = t.find((e) => !e.startsWith("-")) ?? process.cwd(), r = await e(qr(n), { scope: "voltro:build" }), i = He(n);
|
|
1099
1099
|
return i.warning !== void 0 && V.warn(i.warning), r;
|
|
1100
1100
|
}, Yr = 3, Xr = 50, Zr = 256 * 1024, Qr = (e) => e.reduce((e, t) => e + Buffer.byteLength(t.content, "utf8"), 0), $r = async (e, t) => {
|
|
1101
1101
|
let n = Math.max(1, t.maxAttempts ?? Yr), r = t.maxArtifacts ?? Xr, i = t.maxTotalBytes ?? Zr, a = [];
|
|
@@ -4447,6 +4447,132 @@ never mint — inspect stays closed until an operator opens it.`);
|
|
|
4447
4447
|
"credential on the Subject — `connectionCredentials(...)` keeps it in the",
|
|
4448
4448
|
"framework vault."
|
|
4449
4449
|
].join("\n")
|
|
4450
|
+
}),
|
|
4451
|
+
H({
|
|
4452
|
+
version: "0.32.0",
|
|
4453
|
+
id: "0.32.0/01_audit-redacts-outcome",
|
|
4454
|
+
title: "`auditPlugin` now redacts `outcome` by default — opt out if your trail reads it",
|
|
4455
|
+
kind: "manual",
|
|
4456
|
+
appliesTo: ({ project: e }) => e.getSourceFiles().some((e) => /auditPlugin\s*\(/.test(e.getFullText())),
|
|
4457
|
+
note: [
|
|
4458
|
+
"`auditPlugin` gained `redactOutcome`, and it DEFAULTS TO `'all'`.",
|
|
4459
|
+
"",
|
|
4460
|
+
"What changes in your `_voltro_audit_log` rows from this version on:",
|
|
4461
|
+
"",
|
|
4462
|
+
" outcome.value (on success) → { \"__redacted\": \"all\" }",
|
|
4463
|
+
" outcome.error (on failure) → { \"_tag\": \"<yours>\" } ← the tag SURVIVES",
|
|
4464
|
+
" outcome.kind, outcome.durationMs ← unchanged",
|
|
4465
|
+
"",
|
|
4466
|
+
"Nothing else moves: the input and subject policies are unchanged, the",
|
|
4467
|
+
"caller still receives the real result, and a `record` predicate still sees",
|
|
4468
|
+
"the live outcome, so a filter keyed on what a call returned keeps working.",
|
|
4469
|
+
"",
|
|
4470
|
+
"WHY: a credential-issuing call has nothing sensitive in its INPUT — the",
|
|
4471
|
+
"secret is the thing it returns. `redactInput` could never reach it. A team",
|
|
4472
|
+
"found four live webhook signing secrets stored in full in this column, with",
|
|
4473
|
+
"both existing redaction options already enabled.",
|
|
4474
|
+
"",
|
|
4475
|
+
"IF YOUR TRAIL IS READ FOR THE RESULT PAYLOAD, opt out explicitly:",
|
|
4476
|
+
"",
|
|
4477
|
+
" auditPlugin({ sink: 'datastore', redactOutcome: 'none' })",
|
|
4478
|
+
"",
|
|
4479
|
+
"or keep the shape and drop only the sensitive part:",
|
|
4480
|
+
"",
|
|
4481
|
+
" auditPlugin({ sink: 'datastore', redactOutcome: (e) => summarise(e) })",
|
|
4482
|
+
"",
|
|
4483
|
+
"AND WHILE YOU ARE HERE — the rows already written are not touched by this.",
|
|
4484
|
+
"Run the scan on every environment:",
|
|
4485
|
+
"",
|
|
4486
|
+
" voltro db scan-credentials",
|
|
4487
|
+
"",
|
|
4488
|
+
"It exits 1 on a hit and 2 when it examined nothing. If it finds something,",
|
|
4489
|
+
"purge the rows AND rotate the credentials — assume anything written to a",
|
|
4490
|
+
"log table has been read."
|
|
4491
|
+
].join("\n")
|
|
4492
|
+
}),
|
|
4493
|
+
H({
|
|
4494
|
+
version: "0.33.0",
|
|
4495
|
+
id: "0.33.0/01_opentelemetry-optional-peer",
|
|
4496
|
+
title: "`@effect/opentelemetry` is now an optional peer — install it if you use tracing",
|
|
4497
|
+
kind: "manual",
|
|
4498
|
+
appliesTo: () => !0,
|
|
4499
|
+
note: [
|
|
4500
|
+
"SKIP THIS if you do not export traces or metrics (no `FRAMEWORK_TRACING`,",
|
|
4501
|
+
"no `FRAMEWORK_METRICS`, no `OTEL_EXPORTER_OTLP_*` endpoint). Nothing changes",
|
|
4502
|
+
"for you, and your `pnpm install` just got 24 lines quieter.",
|
|
4503
|
+
"",
|
|
4504
|
+
"IF YOU DO: `@effect/opentelemetry` is no longer installed for you. Add it:",
|
|
4505
|
+
"",
|
|
4506
|
+
" pnpm add @effect/opentelemetry",
|
|
4507
|
+
"",
|
|
4508
|
+
"WHY: it was a hard dependency of `@voltro/runtime` and is reached from one",
|
|
4509
|
+
"dynamic import, only when tracing is on. It declares seven non-optional",
|
|
4510
|
+
"OpenTelemetry peers; we supply five. The two we do not are",
|
|
4511
|
+
"`@opentelemetry/sdk-logs` and `@opentelemetry/sdk-trace-web` — and the",
|
|
4512
|
+
"second is the BROWSER tracer, so adding it to a server package to silence",
|
|
4513
|
+
"the warning would have been the wrong direction. So every consumer saw an",
|
|
4514
|
+
"unmet-peer block on every install, for a condition that broke nothing.",
|
|
4515
|
+
"",
|
|
4516
|
+
"The team who reported it read past that block for four releases. A warning",
|
|
4517
|
+
"that is always there is a warning nobody reads, and the next one in the",
|
|
4518
|
+
"block is the one that matters.",
|
|
4519
|
+
"",
|
|
4520
|
+
"IF YOU FORGET: a boot with tracing enabled fails with a message naming this",
|
|
4521
|
+
"exact install line, rather than a bare module-not-found for a package you",
|
|
4522
|
+
"never wrote down. It is a startup failure, not a silent loss of traces —",
|
|
4523
|
+
"losing telemetry quietly would be the worse outcome."
|
|
4524
|
+
].join("\n")
|
|
4525
|
+
}),
|
|
4526
|
+
H({
|
|
4527
|
+
version: "0.33.0",
|
|
4528
|
+
id: "0.33.0/02_coordinated-handle-gained-wake",
|
|
4529
|
+
title: "`CoordinatedScheduleHandle` gained `wake()`, `currentIntervalMs()` and `isArmed()` — update hand-written test doubles",
|
|
4530
|
+
kind: "manual",
|
|
4531
|
+
appliesTo: ({ project: e }) => e.getSourceFiles().some((e) => e.getFullText().includes("scheduleCoordinated")),
|
|
4532
|
+
note: [
|
|
4533
|
+
"SKIP THIS unless you STUB `ctx.scheduleCoordinated` in a test. Calling it is",
|
|
4534
|
+
"unchanged — the framework builds the handle, and the effect parameter only",
|
|
4535
|
+
"got wider (it may now return a tick outcome; returning nothing still works",
|
|
4536
|
+
"and still means \"assume there was work\").",
|
|
4537
|
+
"",
|
|
4538
|
+
"IF YOU STUB IT: the handle now has three more members. A minimal double:",
|
|
4539
|
+
"",
|
|
4540
|
+
" scheduleCoordinated: (name, intervalMs, effect) => {",
|
|
4541
|
+
" const timer = setInterval(() => { void effect() }, intervalMs)",
|
|
4542
|
+
" return {",
|
|
4543
|
+
" name,",
|
|
4544
|
+
" stop: () => clearInterval(timer),",
|
|
4545
|
+
" wake: () => { void effect() },",
|
|
4546
|
+
" currentIntervalMs: () => intervalMs,",
|
|
4547
|
+
" isArmed: () => true,",
|
|
4548
|
+
" }",
|
|
4549
|
+
" }",
|
|
4550
|
+
"",
|
|
4551
|
+
"WHY: a coordinated tick used to run on a fixed interval and write a row into",
|
|
4552
|
+
"`_voltro_schedule_claims` every time it won — whether or not there was any",
|
|
4553
|
+
"work. On a two-replica deployment that had never enqueued anything, two",
|
|
4554
|
+
"framework tasks accounted for 99.3 % of that table: 2 506 rows an hour,",
|
|
4555
|
+
"against 18 from the app's own eight schedules. The table reached 86 214 rows",
|
|
4556
|
+
"and pinned ten connections of a fifteen-slot pooler.",
|
|
4557
|
+
"",
|
|
4558
|
+
"So the interval is a FLOOR now. Return `{ idle: true }` from a tick that",
|
|
4559
|
+
"found nothing and the runner backs off toward `VOLTRO_POLL_CEILING_MS`",
|
|
4560
|
+
"(30 s); add `nextDueInMs` when you already know something is coming, and it",
|
|
4561
|
+
"arms for that instant instead. `wake()` is the other half — wire it to",
|
|
4562
|
+
"whatever announces work (a `store.onChange` on your queue table) and the",
|
|
4563
|
+
"work starts on arrival rather than up to one interval later.",
|
|
4564
|
+
"",
|
|
4565
|
+
"AND IF YOU HAVE A CHANGE CHANNEL, you can stop polling altogether: pass",
|
|
4566
|
+
"`{ disarmWhenIdle: true }` as a fourth argument and an idle tick with",
|
|
4567
|
+
"nothing pending stops the timer — one tick at startup, then only `wake()`.",
|
|
4568
|
+
"Only do that where a peer replica's write reaches your process (Postgres",
|
|
4569
|
+
"LISTEN/NOTIFY, or a broadcast broker); without that a disarmed task sleeps",
|
|
4570
|
+
"through a peer's enqueue and the backoff ceiling is the right choice.",
|
|
4571
|
+
"",
|
|
4572
|
+
"IF YOU DO NOTHING: your task keeps its fixed interval, exactly as before.",
|
|
4573
|
+
"Reporting nothing is the conservative default on purpose — a task that",
|
|
4574
|
+
"cannot tell whether it was idle must not be slowed down on a guess."
|
|
4575
|
+
].join("\n")
|
|
4450
4576
|
})
|
|
4451
4577
|
], ls = /* @__PURE__ */ new Set([
|
|
4452
4578
|
"node_modules",
|
|
@@ -5202,7 +5328,7 @@ never mint — inspect stays closed until an operator opens it.`);
|
|
|
5202
5328
|
]
|
|
5203
5329
|
});
|
|
5204
5330
|
c.push(i), await ic(o, "web"), U.info(`running ${s.length} test file(s)`, { count: s.length });
|
|
5205
|
-
let l = 0, u =
|
|
5331
|
+
let l = 0, u = ze(), d = Je(u);
|
|
5206
5332
|
d !== void 0 && U.warn(d);
|
|
5207
5333
|
for (let e of s) {
|
|
5208
5334
|
let t = await new Promise((t) => {
|
|
@@ -8181,7 +8307,7 @@ replicas = 1
|
|
|
8181
8307
|
return Ne(e);
|
|
8182
8308
|
}, yf = async (t) => {
|
|
8183
8309
|
if (t.includes("--create-only")) return e(gf(O(t.find((e) => !e.startsWith("-")) ?? process.cwd())), { scope: "voltro:migrate" });
|
|
8184
|
-
let { runDbCommand: n } = await import("./dbCommand-
|
|
8310
|
+
let { runDbCommand: n } = await import("./dbCommand-b1gum4td.js");
|
|
8185
8311
|
return n(["apply", ...t]);
|
|
8186
8312
|
}, bf = "voltro-backup-stamp.json", xf = (e) => ({
|
|
8187
8313
|
stampVersion: 1,
|