@warlock.js/devtools 5.59.0 → 5.61.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 +30 -0
- package/cjs/{app-versions-DfpPZOI2.cjs → app-versions-C_ZyzuvD.cjs} +1 -116
- package/cjs/app-versions-C_ZyzuvD.cjs.map +1 -0
- package/cjs/attach-D5aMqUnA.cjs +1342 -0
- package/cjs/attach-D5aMqUnA.cjs.map +1 -0
- package/cjs/{auth-B3wyjJnQ.cjs → auth-ChHh5E7j.cjs} +6 -6
- package/cjs/{auth-B3wyjJnQ.cjs.map → auth-ChHh5E7j.cjs.map} +1 -1
- package/cjs/{boot-nczSvJ_F.cjs → boot-D0nF-7w3.cjs} +78 -14
- package/cjs/boot-D0nF-7w3.cjs.map +1 -0
- package/cjs/{capture-CuyT8Vab.cjs → capture-D2k0GnBN.cjs} +23 -422
- package/cjs/capture-D2k0GnBN.cjs.map +1 -0
- package/cjs/{cascade-store-CuRRYzt_.cjs → cascade-store-DUT2Laha.cjs} +3 -3
- package/cjs/{cascade-store-CuRRYzt_.cjs.map → cascade-store-DUT2Laha.cjs.map} +1 -1
- package/cjs/{collector-CJbQbzzK.cjs → collector-BfC4v87v.cjs} +4 -46
- package/cjs/collector-BfC4v87v.cjs.map +1 -0
- package/cjs/{current-request-id-CeQhRz9Q.cjs → current-request-id-Badec-TH.cjs} +2 -2
- package/cjs/{current-request-id-CeQhRz9Q.cjs.map → current-request-id-Badec-TH.cjs.map} +1 -1
- package/cjs/{errors-BadbSDX8.cjs → errors-DNQ-g49I.cjs} +198 -1
- package/cjs/errors-DNQ-g49I.cjs.map +1 -0
- package/cjs/extract-8kaX_cUV.cjs +1103 -0
- package/cjs/extract-8kaX_cUV.cjs.map +1 -0
- package/cjs/{http-Biauhqi0.cjs → http-1nnpAoI7.cjs} +33 -10
- package/cjs/http-1nnpAoI7.cjs.map +1 -0
- package/cjs/index.cjs +1 -1
- package/cjs/{insights-BjJA6Ret.cjs → insights-COA3u37q.cjs} +54 -22
- package/cjs/insights-COA3u37q.cjs.map +1 -0
- package/cjs/migrations-BQdNOL5_.cjs +30 -0
- package/cjs/migrations-BQdNOL5_.cjs.map +1 -0
- package/cjs/{migrations-BP4cYTGo.cjs → models-DF1agAm4.cjs} +106 -24
- package/cjs/models-DF1agAm4.cjs.map +1 -0
- package/cjs/{process-panel-DskSA7Cm.cjs → process-panel-D3D9Y_dc.cjs} +4 -4
- package/cjs/{process-panel-DskSA7Cm.cjs.map → process-panel-D3D9Y_dc.cjs.map} +1 -1
- package/cjs/production/index.cjs +4 -4
- package/cjs/query-shape-DShKQa0x.cjs +45 -0
- package/cjs/query-shape-DShKQa0x.cjs.map +1 -0
- package/cjs/redact-DQ28mDzr.cjs +533 -0
- package/cjs/redact-DQ28mDzr.cjs.map +1 -0
- package/cjs/runs-DECWPGnq.cjs +390 -0
- package/cjs/runs-DECWPGnq.cjs.map +1 -0
- package/cjs/{server-D3XRbSSb.cjs → server-DLT3uPef.cjs} +8 -7
- package/cjs/{server-D3XRbSSb.cjs.map → server-DLT3uPef.cjs.map} +1 -1
- package/cjs/{src-QcNghoYN.cjs → src-BZiSv8A1.cjs} +182 -24
- package/cjs/src-BZiSv8A1.cjs.map +1 -0
- package/cjs/{store-CNFv3wVp.cjs → store-EFn4wp0T.cjs} +2 -2
- package/cjs/{stream-route-BqyAlfxQ.cjs → stream-route-B6WAjbPG.cjs} +111 -22
- package/cjs/stream-route-B6WAjbPG.cjs.map +1 -0
- package/esm/ai/attach.mjs +92 -0
- package/esm/ai/attach.mjs.map +1 -0
- package/esm/ai/options.mjs +31 -0
- package/esm/ai/options.mjs.map +1 -0
- package/esm/ai/reports/aggregate.mjs +330 -0
- package/esm/ai/reports/aggregate.mjs.map +1 -0
- package/esm/ai/reports/evaluate.mjs +108 -0
- package/esm/ai/reports/evaluate.mjs.map +1 -0
- package/esm/ai/reports/range.mjs +121 -0
- package/esm/ai/reports/range.mjs.map +1 -0
- package/esm/ai/reports/runs.d.mts +2 -0
- package/esm/ai/reports/runs.mjs +212 -0
- package/esm/ai/reports/runs.mjs.map +1 -0
- package/esm/ai/reports/service.mjs +132 -0
- package/esm/ai/reports/service.mjs.map +1 -0
- package/esm/ai/rollup/cascade-store.mjs +84 -0
- package/esm/ai/rollup/cascade-store.mjs.map +1 -0
- package/esm/ai/rollup/categories.mjs +67 -0
- package/esm/ai/rollup/categories.mjs.map +1 -0
- package/esm/ai/rollup/extract.mjs +225 -0
- package/esm/ai/rollup/extract.mjs.map +1 -0
- package/esm/ai/rollup/file-store.mjs +147 -0
- package/esm/ai/rollup/file-store.mjs.map +1 -0
- package/esm/ai/rollup/histogram.mjs +42 -0
- package/esm/ai/rollup/histogram.mjs.map +1 -0
- package/esm/ai/rollup/increment-error.mjs +19 -0
- package/esm/ai/rollup/increment-error.mjs.map +1 -0
- package/esm/ai/rollup/index.mjs +9 -0
- package/esm/ai/rollup/mapping.mjs +69 -0
- package/esm/ai/rollup/mapping.mjs.map +1 -0
- package/esm/ai/rollup/memory-store.mjs +26 -0
- package/esm/ai/rollup/memory-store.mjs.map +1 -0
- package/esm/ai/rollup/writer.mjs +113 -0
- package/esm/ai/rollup/writer.mjs.map +1 -0
- package/esm/ai/types.d.mts +29 -0
- package/esm/ai/types.d.mts.map +1 -0
- package/esm/devtools-connector.d.mts.map +1 -1
- package/esm/devtools-connector.mjs +58 -3
- package/esm/devtools-connector.mjs.map +1 -1
- package/esm/index.d.mts +3 -2
- package/esm/options.mjs +4 -0
- package/esm/options.mjs.map +1 -1
- package/esm/production/boot.mjs +70 -3
- package/esm/production/boot.mjs.map +1 -1
- package/esm/production/contracts.d.mts +388 -6
- package/esm/production/contracts.d.mts.map +1 -1
- package/esm/production/contracts.mjs +64 -2
- package/esm/production/contracts.mjs.map +1 -1
- package/esm/production/errors.mjs +8 -0
- package/esm/production/errors.mjs.map +1 -1
- package/esm/production/http/access.mjs +6 -0
- package/esm/production/http/access.mjs.map +1 -1
- package/esm/production/http/mount.mjs +21 -2
- package/esm/production/http/mount.mjs.map +1 -1
- package/esm/production/http/share.mjs.map +1 -1
- package/esm/production/index.d.mts +2 -2
- package/esm/production/insights/jobs.mjs +45 -11
- package/esm/production/insights/jobs.mjs.map +1 -1
- package/esm/production/store/migrations.d.mts +1 -1
- package/esm/production/store/migrations.d.mts.map +1 -1
- package/esm/production/store/migrations.mjs +4 -2
- package/esm/production/store/migrations.mjs.map +1 -1
- package/esm/production/store/models/ai-rollup.migration.mjs +48 -0
- package/esm/production/store/models/ai-rollup.migration.mjs.map +1 -0
- package/esm/production/store/models/ai-rollup.model.mjs +13 -0
- package/esm/production/store/models/ai-rollup.model.mjs.map +1 -0
- package/esm/production/store/models/index.mjs +3 -1
- package/esm/server/ai-report-routes.mjs +72 -0
- package/esm/server/ai-report-routes.mjs.map +1 -0
- package/esm/server/ai-routes.mjs +22 -1
- package/esm/server/ai-routes.mjs.map +1 -1
- package/esm/server/index.mjs +2 -0
- package/esm/server/index.mjs.map +1 -1
- package/esm/server/panel-routes.mjs.map +1 -1
- package/esm/server/ui-assets.mjs +4 -7
- package/esm/server/ui-assets.mjs.map +1 -1
- package/esm/sources/agent-trace-source.d.mts.map +1 -1
- package/esm/sources/agent-trace-source.mjs.map +1 -1
- package/esm/sources/ai-source.d.mts +2 -0
- package/esm/sources/ai-source.d.mts.map +1 -1
- package/esm/sources/ai-source.mjs +58 -17
- package/esm/sources/ai-source.mjs.map +1 -1
- package/esm/types.d.mts +13 -3
- package/esm/types.d.mts.map +1 -1
- package/llms-full.txt +61 -22
- package/package.json +8 -8
- package/skills/SKILL.md +61 -22
- package/ui/dashboard/assets/app.css +1 -1
- package/ui/dashboard/assets/app.js +12 -5
- package/ui/dashboard/build-info.json +7 -7
- package/cjs/ai-source-BdvMfyKw.cjs +0 -448
- package/cjs/ai-source-BdvMfyKw.cjs.map +0 -1
- package/cjs/app-versions-DfpPZOI2.cjs.map +0 -1
- package/cjs/boot-nczSvJ_F.cjs.map +0 -1
- package/cjs/capture-CuyT8Vab.cjs.map +0 -1
- package/cjs/collector-CJbQbzzK.cjs.map +0 -1
- package/cjs/errors-BadbSDX8.cjs.map +0 -1
- package/cjs/histogram-DTOGnNBW.cjs +0 -102
- package/cjs/histogram-DTOGnNBW.cjs.map +0 -1
- package/cjs/http-Biauhqi0.cjs.map +0 -1
- package/cjs/insights-BjJA6Ret.cjs.map +0 -1
- package/cjs/migrations-BP4cYTGo.cjs.map +0 -1
- package/cjs/options-B9FHbRAJ.cjs +0 -205
- package/cjs/options-B9FHbRAJ.cjs.map +0 -1
- package/cjs/panels-D1ITm-jc.cjs +0 -384
- package/cjs/panels-D1ITm-jc.cjs.map +0 -1
- package/cjs/src-QcNghoYN.cjs.map +0 -1
- package/cjs/stream-route-BqyAlfxQ.cjs.map +0 -1
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,36 @@ All notable changes to `@warlock.js/devtools` are documented in this file.
|
|
|
4
4
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/). `@warlock.js/*` packages are released in lockstep — every package shares the same version number, so a version below may list only the changes that affected this package.
|
|
6
6
|
|
|
7
|
+
## 5.61.0 - 2026-11-20
|
|
8
|
+
|
|
9
|
+
### Added
|
|
10
|
+
|
|
11
|
+
- The Jobs tab shows each schedule's last duration, last error, runs, failures and recent runs, and the job counts (waiting, active, delayed, failed, completed) of each queue. "Counts not available" appears only for a queue driver without `counts()`.
|
|
12
|
+
|
|
13
|
+
### Fixed
|
|
14
|
+
|
|
15
|
+
- Closed production monitor URLs answer exactly like any unknown URL of the app, including a web site's `route_not_found` answer (JSON and document), instead of Fastify's default 404. The app's global rate limit applies to them as to any unknown URL (same `x-ratelimit-*` headers, same 429), and an error of the app's catch-all gets the app's own error answer.
|
|
16
|
+
- The Jobs tab finds the active queue driver; before, it could not and always said the queue was not available.
|
|
17
|
+
- Error messages in the Jobs tab (last error, recent runs) are scrubbed like request errors: quoted values, emails and documents are removed.
|
|
18
|
+
- The Queries tab works when production mode is enabled only through `devtoolsConnector` options; `queryEvents: true` is no longer needed.
|
|
19
|
+
|
|
20
|
+
## 5.60.0 - 2026-11-19
|
|
21
|
+
|
|
22
|
+
### Added
|
|
23
|
+
|
|
24
|
+
- An AI sidebar group with six pages: Reports, Runs, Agents, Models, Errors and Evaluate. Reports, Models and Errors show estimated cost, tokens, error rate and latency over 24 hours, 7 days, 30 days or a custom range, with accessible charts (keyboard tooltips, table view) that keep each model's colour while filters change. Cost is an estimate from model pricing: runs of models without pricing are counted next to every cost (a model priced at 0 counts as priced), a model whose runs used no tokens shows "No tokens used", and a comparison whose previous period is older than the kept history reads "No earlier data". Custom ranges longer than 8 days use daily columns from local midnight to midnight.
|
|
25
|
+
- Runs gains search, status, type, exact HTTP request id and group-by filters, summary tiles (the estimated cost says how many unpriced runs it leaves out) and a cost tint on the span tree by each span's own cost; Errors lists recent failed runs inside the chosen range and filters; Agents shows the last 24 hours per agent; Evaluate grades a system prompt with the configured judge model and shows the score, issues and judge.
|
|
26
|
+
- AI report API: `GET /api/ai/reports`, `/models`, `/errors` (range, timezone, agent, model and provider filters, previous-period comparison, 15 s cache), `GET /api/ai/runs` (filter, `requestId`, group, stats) and `GET`/`POST /api/ai/evaluate`.
|
|
27
|
+
- Hourly AI rollups per hour, agent, model and provider (runs, tokens, estimated cost, errors by category, latency histogram), stored in the app database (`devtools_ai_rollups`, part of `devtoolsMigrations`), in JSON files in development and in memory in specs. A write that fails part-way retries only the totals it did not save, so nothing is counted twice.
|
|
28
|
+
- `devtools.ai` options: `reports`, `retentionDays` (30 in development, 90 in production, 1 to 400) and `flushIntervalMs` (default 60000, minimum 5000).
|
|
29
|
+
- Specific error codes for AI routes: `ai.range-invalid`, `ai.evaluate-unavailable`, `ai.prompt-not-found` and `ai.evaluate-failed`.
|
|
30
|
+
- Devtools publishes where it is mounted so other packages can point to it. In production, Reports, Models and Errors are listed only when Panoptic is installed.
|
|
31
|
+
|
|
32
|
+
### Changed
|
|
33
|
+
|
|
34
|
+
- Upgrade note: in production, the Reports, Models and Errors tabs are on by default once Panoptic loads. Run `warlock migrate` to create `devtools_ai_rollups`; until then each process logs one warning at boot and the pages show "AI reports need their table". Turning all three tabs off with `production.panels` also stops the totals from being written.
|
|
35
|
+
- The `ai` tab keeps its id (and `production.panels.ai`) and is titled "Runs", inside the AI sidebar group.
|
|
36
|
+
|
|
7
37
|
## 5.59.0 - 2026-11-19
|
|
8
38
|
|
|
9
39
|
### Added
|
|
@@ -43,103 +43,6 @@ let node_path = require("node:path");
|
|
|
43
43
|
node_path = __toESM(node_path, 1);
|
|
44
44
|
let node_url = require("node:url");
|
|
45
45
|
|
|
46
|
-
//#region ../../packages/devtools/src/production/contracts.ts
|
|
47
|
-
/**
|
|
48
|
-
* Upper bounds (inclusive, ms) of the latency buckets every histogram uses.
|
|
49
|
-
* A histogram's `counts` has one more entry than this list: the last entry
|
|
50
|
-
* counts everything above the highest bound. Fixed bounds make histograms
|
|
51
|
-
* from several instances merge exactly.
|
|
52
|
-
*/
|
|
53
|
-
const DEVTOOLS_LATENCY_BUCKETS_MS = [
|
|
54
|
-
1,
|
|
55
|
-
2,
|
|
56
|
-
5,
|
|
57
|
-
10,
|
|
58
|
-
25,
|
|
59
|
-
50,
|
|
60
|
-
100,
|
|
61
|
-
250,
|
|
62
|
-
500,
|
|
63
|
-
1e3,
|
|
64
|
-
2500,
|
|
65
|
-
5e3,
|
|
66
|
-
1e4,
|
|
67
|
-
3e4
|
|
68
|
-
];
|
|
69
|
-
/**
|
|
70
|
-
* The built-in tabs, in display order, with whether production shows them
|
|
71
|
-
* when the project says nothing (`production.panels` overrides per id).
|
|
72
|
-
*/
|
|
73
|
-
const DEVTOOLS_BUILT_IN_PANELS = [
|
|
74
|
-
{
|
|
75
|
-
id: "requests",
|
|
76
|
-
title: "Requests",
|
|
77
|
-
production: true
|
|
78
|
-
},
|
|
79
|
-
{
|
|
80
|
-
id: "queries",
|
|
81
|
-
title: "Queries",
|
|
82
|
-
production: true
|
|
83
|
-
},
|
|
84
|
-
{
|
|
85
|
-
id: "routes",
|
|
86
|
-
title: "Routes",
|
|
87
|
-
production: true
|
|
88
|
-
},
|
|
89
|
-
{
|
|
90
|
-
id: "resources",
|
|
91
|
-
title: "Resources",
|
|
92
|
-
production: true
|
|
93
|
-
},
|
|
94
|
-
{
|
|
95
|
-
id: "health",
|
|
96
|
-
title: "Health",
|
|
97
|
-
production: true
|
|
98
|
-
},
|
|
99
|
-
{
|
|
100
|
-
id: "errors",
|
|
101
|
-
title: "Errors",
|
|
102
|
-
production: true
|
|
103
|
-
},
|
|
104
|
-
{
|
|
105
|
-
id: "logs",
|
|
106
|
-
title: "Logs",
|
|
107
|
-
production: true
|
|
108
|
-
},
|
|
109
|
-
{
|
|
110
|
-
id: "jobs",
|
|
111
|
-
title: "Jobs",
|
|
112
|
-
production: true
|
|
113
|
-
},
|
|
114
|
-
{
|
|
115
|
-
id: "mail",
|
|
116
|
-
title: "Mail",
|
|
117
|
-
production: false
|
|
118
|
-
},
|
|
119
|
-
{
|
|
120
|
-
id: "ai",
|
|
121
|
-
title: "AI",
|
|
122
|
-
production: false
|
|
123
|
-
},
|
|
124
|
-
{
|
|
125
|
-
id: "agents",
|
|
126
|
-
title: "Agents",
|
|
127
|
-
production: false
|
|
128
|
-
},
|
|
129
|
-
{
|
|
130
|
-
id: "api",
|
|
131
|
-
title: "API",
|
|
132
|
-
production: false
|
|
133
|
-
}
|
|
134
|
-
];
|
|
135
|
-
/** The audit types that count toward the account, IP and global failure limits. */
|
|
136
|
-
const DEVTOOLS_FAILURE_AUDIT_TYPES = [
|
|
137
|
-
"login.failed",
|
|
138
|
-
"mfa.failed",
|
|
139
|
-
"share.failed"
|
|
140
|
-
];
|
|
141
|
-
|
|
142
|
-
//#endregion
|
|
143
46
|
//#region ../../packages/devtools/src/app-versions.ts
|
|
144
47
|
/** The `version` of a `package.json` named `name`, or `null` when the file is not that package's. */
|
|
145
48
|
function versionIn(file, name) {
|
|
@@ -208,24 +111,6 @@ function readVersions(root = process.cwd()) {
|
|
|
208
111
|
}
|
|
209
112
|
|
|
210
113
|
//#endregion
|
|
211
|
-
Object.defineProperty(exports, "DEVTOOLS_BUILT_IN_PANELS", {
|
|
212
|
-
enumerable: true,
|
|
213
|
-
get: function () {
|
|
214
|
-
return DEVTOOLS_BUILT_IN_PANELS;
|
|
215
|
-
}
|
|
216
|
-
});
|
|
217
|
-
Object.defineProperty(exports, "DEVTOOLS_FAILURE_AUDIT_TYPES", {
|
|
218
|
-
enumerable: true,
|
|
219
|
-
get: function () {
|
|
220
|
-
return DEVTOOLS_FAILURE_AUDIT_TYPES;
|
|
221
|
-
}
|
|
222
|
-
});
|
|
223
|
-
Object.defineProperty(exports, "DEVTOOLS_LATENCY_BUCKETS_MS", {
|
|
224
|
-
enumerable: true,
|
|
225
|
-
get: function () {
|
|
226
|
-
return DEVTOOLS_LATENCY_BUCKETS_MS;
|
|
227
|
-
}
|
|
228
|
-
});
|
|
229
114
|
Object.defineProperty(exports, "__exportAll", {
|
|
230
115
|
enumerable: true,
|
|
231
116
|
get: function () {
|
|
@@ -250,4 +135,4 @@ Object.defineProperty(exports, "readVersions", {
|
|
|
250
135
|
return readVersions;
|
|
251
136
|
}
|
|
252
137
|
});
|
|
253
|
-
//# sourceMappingURL=app-versions-
|
|
138
|
+
//# sourceMappingURL=app-versions-C_ZyzuvD.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"app-versions-C_ZyzuvD.cjs","names":["readFileSync","path","fileURLToPath"],"sources":["../../../../../../../packages/devtools/src/app-versions.ts"],"sourcesContent":["import { readFileSync } from \"node:fs\";\nimport path from \"node:path\";\nimport { fileURLToPath } from \"node:url\";\n\n/** The app's own name and version, as the dashboard shows them at the bottom of the sidebar. */\nexport type DevtoolsAppInfo = { name: string; version: string };\n\n/** The `version` of a `package.json` named `name`, or `null` when the file is not that package's. */\nfunction versionIn(file: string, name: string): string | null {\n try {\n const manifest = JSON.parse(readFileSync(file, \"utf8\")) as {\n name?: unknown;\n version?: unknown;\n };\n\n return manifest.name === name && typeof manifest.version === \"string\" ? manifest.version : null;\n } catch {\n return null;\n }\n}\n\n/**\n * The installed version of a package, read from its `package.json` without\n * going through its `exports` (published `@warlock.js/core` exports neither\n * `./package.json` nor a `require` condition). It resolves the package's entry\n * and walks up to the `package.json` with that name; when the entry cannot be\n * resolved, it looks in each `node_modules` above `from`. `null` when unknown.\n */\nexport function installedVersion(\n name: string,\n from: string,\n resolve: ((specifier: string) => string) | undefined,\n): string | null {\n try {\n const entry = resolve?.(name);\n\n if (entry !== undefined) {\n let folder = path.dirname(entry.startsWith(\"file:\") ? fileURLToPath(entry) : entry);\n\n for (;;) {\n const version = versionIn(path.join(folder, \"package.json\"), name);\n\n if (version !== null) return version;\n\n const parent = path.dirname(folder);\n\n if (parent === folder) break;\n\n folder = parent;\n }\n }\n } catch {\n // Not resolvable from here: look in the node_modules folders below.\n }\n\n for (let folder = from; ; folder = path.dirname(folder)) {\n const version = versionIn(\n path.join(folder, \"node_modules\", ...name.split(\"/\"), \"package.json\"),\n name,\n );\n\n if (version !== null) return version;\n if (path.dirname(folder) === folder) return null;\n }\n}\n\n/**\n * The app's `name` and `version` from the `package.json` in `root`. Only these\n * two strings are read; `null` when the file is missing, unreadable or lacks\n * either one.\n */\nexport function readAppInfo(root: string): DevtoolsAppInfo | null {\n try {\n const manifest = JSON.parse(readFileSync(path.join(root, \"package.json\"), \"utf8\")) as {\n name?: unknown;\n version?: unknown;\n };\n\n if (\n typeof manifest.name !== \"string\" ||\n typeof manifest.version !== \"string\" ||\n manifest.name === \"\" ||\n manifest.version === \"\"\n ) {\n return null;\n }\n\n return { name: manifest.name.slice(0, 100), version: manifest.version.slice(0, 50) };\n } catch {\n return null;\n }\n}\n\ntype Versions = { warlockVersion: string | null; app: DevtoolsAppInfo | null };\n\nlet cached: Versions | undefined;\n\n/**\n * The installed `@warlock.js/core` version and the app's name and version,\n * read once per process (`root` defaults to the working directory) and kept.\n */\nexport function readVersions(root: string = process.cwd()): Versions {\n cached ??= {\n warlockVersion: installedVersion(\n \"@warlock.js/core\",\n root,\n typeof import.meta.resolve === \"function\"\n ? (specifier: string) => import.meta.resolve(specifier)\n : undefined,\n ),\n app: readAppInfo(root),\n };\n\n return cached;\n}\n\n/** Forgets the cached versions (for tests). */\nexport function resetVersionsCache(): void {\n cached = undefined;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAQA,SAAS,UAAU,MAAc,MAA6B;CAC5D,IAAI;EACF,MAAM,WAAW,KAAK,UAAMA,sBAAa,MAAM,MAAM,CAAC;EAKtD,OAAO,SAAS,SAAS,QAAQ,OAAO,SAAS,YAAY,WAAW,SAAS,UAAU;CAC7F,QAAQ;EACN,OAAO;CACT;AACF;;;;;;;;AASA,SAAgB,iBACd,MACA,MACA,SACe;CACf,IAAI;EACF,MAAM,QAAQ,UAAU,IAAI;EAE5B,IAAI,UAAU,QAAW;GACvB,IAAI,SAASC,kBAAK,QAAQ,MAAM,WAAW,OAAO,QAAIC,wBAAc,KAAK,IAAI,KAAK;GAElF,SAAS;IACP,MAAM,UAAU,UAAUD,kBAAK,KAAK,QAAQ,cAAc,GAAG,IAAI;IAEjE,IAAI,YAAY,MAAM,OAAO;IAE7B,MAAM,SAASA,kBAAK,QAAQ,MAAM;IAElC,IAAI,WAAW,QAAQ;IAEvB,SAAS;GACX;EACF;CACF,QAAQ,CAER;CAEA,KAAK,IAAI,SAAS,OAAQ,SAASA,kBAAK,QAAQ,MAAM,GAAG;EACvD,MAAM,UAAU,UACdA,kBAAK,KAAK,QAAQ,gBAAgB,GAAG,KAAK,MAAM,GAAG,GAAG,cAAc,GACpE,IACF;EAEA,IAAI,YAAY,MAAM,OAAO;EAC7B,IAAIA,kBAAK,QAAQ,MAAM,MAAM,QAAQ,OAAO;CAC9C;AACF;;;;;;AAOA,SAAgB,YAAY,MAAsC;CAChE,IAAI;EACF,MAAM,WAAW,KAAK,UAAMD,sBAAaC,kBAAK,KAAK,MAAM,cAAc,GAAG,MAAM,CAAC;EAKjF,IACE,OAAO,SAAS,SAAS,YACzB,OAAO,SAAS,YAAY,YAC5B,SAAS,SAAS,MAClB,SAAS,YAAY,IAErB,OAAO;EAGT,OAAO;GAAE,MAAM,SAAS,KAAK,MAAM,GAAG,GAAG;GAAG,SAAS,SAAS,QAAQ,MAAM,GAAG,EAAE;EAAE;CACrF,QAAQ;EACN,OAAO;CACT;AACF;AAIA,IAAI;;;;;AAMJ,SAAgB,aAAa,OAAe,QAAQ,IAAI,GAAa;CACnE,WAAW;EACT,gBAAgB,iBACd,oBACA,MACA,UAAmB,YAAY,cAC1B,mBAAkC,QAAQ,SAAS,IACpD,MACN;EACA,KAAK,YAAY,IAAI;CACvB;CAEA,OAAO;AACT"}
|