@ucdjs/pipelines-server 0.0.1-beta.3 → 0.0.1-beta.6
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/dist/client/assets/badge-DpfYXzsc.js +1 -0
- package/dist/client/assets/button-D8TNeETo.js +1 -0
- package/dist/client/assets/card-4nTswg_n.js +1 -0
- package/dist/client/assets/{code.lazy-FGQTh0m_.js → code.lazy-Hk8YeOZq.js} +6 -6
- package/dist/client/assets/createBaseUIEventDetails-eG8mNZ45.js +1 -0
- package/dist/client/assets/createLucideIcon-DqT5FQwf.js +1 -0
- package/dist/client/assets/dist-DOhv2m1Z.js +1 -0
- package/dist/client/assets/file-code-sFotPMp6.js +1 -0
- package/dist/client/assets/graph.lazy-BSNr7S9S.js +1 -0
- package/dist/client/assets/graph.lazy-j3mLiSDD.js +1 -0
- package/dist/client/assets/graphs.lazy-BesTMfiu.js +1 -0
- package/dist/client/assets/index-9D_zdG_Y.css +2 -0
- package/dist/client/assets/index-DvzFBIUy.js +26 -0
- package/dist/client/assets/index.lazy-CYDCkmZn.js +1 -0
- package/dist/client/assets/index.lazy-Cyazp84x.js +1 -0
- package/dist/client/assets/index.lazy-DlzPp9kk.js +1 -0
- package/dist/client/assets/index.lazy-IFnMjMMx.js +1 -0
- package/dist/client/assets/inspect.lazy-CFnVtBAm.js +1 -0
- package/dist/client/assets/loader-circle-B23ONZKS.js +1 -0
- package/dist/client/assets/pipeline-command-palette-D5eOYOY2.js +1 -0
- package/dist/client/assets/pipeline-graph-CjR9n8rb.js +7 -0
- package/dist/client/assets/play-D_JVLdxR.js +1 -0
- package/dist/client/assets/react-dom-nSF78UiM.js +1 -0
- package/dist/client/assets/route.lazy-DFXW1vf2.js +1 -0
- package/dist/client/assets/route.lazy-IMrNfqZN.js +1 -0
- package/dist/client/assets/status-icon-DwAuzQ-Z.js +1 -0
- package/dist/client/assets/table-B_O6sE70.js +1 -0
- package/dist/client/assets/use-execute-BFp3EN62.js +1 -0
- package/dist/client/assets/use-pipeline-versions-B4Bj4BNC.js +1 -0
- package/dist/client/assets/useIsoLayoutEffect-Dm7lmL2S.js +1 -0
- package/dist/client/assets/x-DsbJUv53.js +12 -0
- package/dist/client/index.html +9 -2
- package/dist/server/app.d.ts +21 -0
- package/dist/server/app.js +196 -105
- package/dist/server/code.d.ts +5 -0
- package/dist/server/db/index.d.ts +10 -0
- package/dist/server/db/schema.d.ts +562 -0
- package/dist/server/lib/execution-logs.d.ts +27 -0
- package/dist/server/lib/files.d.ts +38 -0
- package/dist/server/lib/ids.d.ts +5 -0
- package/dist/server/lib/loader.d.ts +2 -0
- package/dist/server/lib/log-capture.d.ts +6 -0
- package/dist/server/lib/resolve.d.ts +1 -0
- package/dist/server/migrations/0000_amazing_kang.sql +20 -0
- package/dist/server/migrations/0001_wandering_wind_dancer.sql +10 -0
- package/dist/server/migrations/0002_lively_maestro.sql +18 -0
- package/dist/server/migrations/0003_common_scarlet_witch.sql +54 -0
- package/dist/server/migrations/meta/0000_snapshot.json +150 -0
- package/dist/server/migrations/meta/0001_snapshot.json +223 -0
- package/dist/server/migrations/meta/0002_snapshot.json +325 -0
- package/dist/server/migrations/meta/0003_snapshot.json +365 -0
- package/dist/server/migrations/meta/_journal.json +34 -0
- package/dist/server/routes/index.d.ts +7 -0
- package/dist/server/routes/pipelines.events.d.ts +2 -0
- package/dist/server/routes/pipelines.execution.d.ts +2 -0
- package/dist/server/routes/pipelines.file.d.ts +2 -0
- package/dist/server/routes/pipelines.graph.d.ts +2 -0
- package/dist/server/routes/pipelines.index.d.ts +2 -0
- package/dist/server/routes/pipelines.logs.d.ts +2 -0
- package/dist/server/routes/pipelines.pipeline.d.ts +2 -0
- package/dist/server/workspace.d.ts +17 -0
- package/package.json +25 -20
- package/dist/client/assets/badge-CiZ9XGQk.js +0 -1
- package/dist/client/assets/card-BlDtnoJE.js +0 -1
- package/dist/client/assets/file-code-5UzxVDjG.js +0 -1
- package/dist/client/assets/graph.lazy-BOYYfhw3.js +0 -1
- package/dist/client/assets/graph.lazy-DA9DvkOv.js +0 -1
- package/dist/client/assets/graphs.lazy-B126tNcm.js +0 -1
- package/dist/client/assets/index-CM5XQ164.js +0 -37
- package/dist/client/assets/index-DMk-WqWb.css +0 -2
- package/dist/client/assets/index.lazy-CU14Wam7.js +0 -1
- package/dist/client/assets/index.lazy-Cb2iPSue.js +0 -1
- package/dist/client/assets/index.lazy-wtKmX-2H.js +0 -1
- package/dist/client/assets/index.lazy-y07R4t6D.js +0 -1
- package/dist/client/assets/inspect.lazy-BYA5YEbr.js +0 -1
- package/dist/client/assets/loader-circle-BY1Dugig.js +0 -1
- package/dist/client/assets/pipeline-command-palette-CWHY1w53.js +0 -45
- package/dist/client/assets/pipeline-graph-CDObZuGJ.js +0 -7
- package/dist/client/assets/play-B6p-hHI7.js +0 -1
- package/dist/client/assets/route.lazy-D79_-rW6.js +0 -1
- package/dist/client/assets/route.lazy-eVSF2dsv.js +0 -1
- package/dist/client/assets/status-icon-NVeRT4ag.js +0 -1
- package/dist/client/assets/table-Cbx6lsBL.js +0 -1
- package/dist/client/assets/use-execute-CG1fzzQp.js +0 -1
- package/dist/client/assets/use-pipeline-versions-Dg2J_cPs.js +0 -1
- /package/dist/client/assets/{javascript-DKcGLuub.js → javascript-UW4R5q0N.js} +0 -0
- /package/dist/client/assets/{json-CgREIYS1.js → json-Bq05x4Q-.js} +0 -0
- /package/dist/client/assets/{typescript-xi0cSHCO.js → typescript-GFMdcsgQ.js} +0 -0
package/dist/server/app.js
CHANGED
|
@@ -1,28 +1,28 @@
|
|
|
1
1
|
import { createRequire } from "node:module";
|
|
2
|
-
import fs, {
|
|
2
|
+
import fs, { readFile } from "node:fs/promises";
|
|
3
3
|
import path, { sep } from "node:path";
|
|
4
4
|
import process$1 from "node:process";
|
|
5
|
+
import fs$1, { existsSync } from "node:fs";
|
|
5
6
|
import { fileURLToPath, pathToFileURL } from "node:url";
|
|
6
7
|
import { createClient } from "@libsql/client";
|
|
8
|
+
import os from "node:os";
|
|
7
9
|
import { drizzle } from "drizzle-orm/libsql";
|
|
8
10
|
import { migrate } from "drizzle-orm/libsql/migrator";
|
|
9
|
-
import { integer, sqliteTable, text } from "drizzle-orm/sqlite-core";
|
|
10
|
-
import { and, asc, desc, eq } from "drizzle-orm";
|
|
11
|
+
import { index, integer, sqliteTable, text } from "drizzle-orm/sqlite-core";
|
|
12
|
+
import { and, asc, desc, eq, sql } from "drizzle-orm";
|
|
11
13
|
import { H3, getQuery, getValidatedQuery, readValidatedBody, serve, serveStatic } from "h3";
|
|
12
14
|
import * as nativeFs$1 from "fs";
|
|
13
15
|
import nativeFs from "fs";
|
|
14
16
|
import path$1, { basename, dirname, normalize, posix, relative, resolve, sep as sep$1 } from "path";
|
|
15
17
|
import { fileURLToPath as fileURLToPath$1 } from "url";
|
|
16
18
|
import { createRequire as createRequire$1 } from "module";
|
|
17
|
-
import fsp, { readFile } from "node:fs/promises";
|
|
18
19
|
import { Worker, isMainThread } from "node:worker_threads";
|
|
19
20
|
import { formatWithOptions, styleText } from "node:util";
|
|
20
21
|
import * as tty from "node:tty";
|
|
21
|
-
import os from "node:os";
|
|
22
22
|
import { parseSync } from "oxc-parser";
|
|
23
23
|
import { z } from "zod";
|
|
24
24
|
import { Buffer as Buffer$1 } from "node:buffer";
|
|
25
|
-
import { randomUUID } from "node:crypto";
|
|
25
|
+
import { createHash, randomUUID } from "node:crypto";
|
|
26
26
|
import { print } from "esrap";
|
|
27
27
|
import ts from "esrap/languages/ts";
|
|
28
28
|
import { AsyncLocalStorage } from "node:async_hooks";
|
|
@@ -56,13 +56,35 @@ var __toESM$1 = (mod, isNodeMode, target) => (target = mod != null ? __create$1(
|
|
|
56
56
|
value: mod,
|
|
57
57
|
enumerable: true
|
|
58
58
|
}) : target, mod));
|
|
59
|
+
var env$1 = process$1.env;
|
|
60
|
+
function getXdgConfigDir() {
|
|
61
|
+
if (env$1.XDG_CONFIG_HOME) return env$1.XDG_CONFIG_HOME;
|
|
62
|
+
return path.join(os.homedir(), ".config");
|
|
63
|
+
}
|
|
64
|
+
function getUcdConfigDir() {
|
|
65
|
+
return path.join(getXdgConfigDir(), "ucd");
|
|
66
|
+
}
|
|
67
|
+
function getUcdConfigPath(...segments) {
|
|
68
|
+
return path.join(getUcdConfigDir(), ...segments);
|
|
69
|
+
}
|
|
70
|
+
function getPipelineDbPath() {
|
|
71
|
+
return getUcdConfigPath("pipeline.db");
|
|
72
|
+
}
|
|
59
73
|
var schema_exports = /* @__PURE__ */ __exportAll$1({
|
|
60
74
|
events: () => events,
|
|
61
75
|
executionLogs: () => executionLogs,
|
|
62
|
-
executions: () => executions
|
|
76
|
+
executions: () => executions,
|
|
77
|
+
workspaces: () => workspaces
|
|
78
|
+
});
|
|
79
|
+
const workspaces = sqliteTable("workspaces", {
|
|
80
|
+
id: text("id").primaryKey(),
|
|
81
|
+
rootPath: text("root_path"),
|
|
82
|
+
createdAt: integer("created_at", { mode: "timestamp" }).notNull(),
|
|
83
|
+
updatedAt: integer("updated_at", { mode: "timestamp" }).notNull()
|
|
63
84
|
});
|
|
64
85
|
const executions = sqliteTable("executions", {
|
|
65
86
|
id: text("id").primaryKey(),
|
|
87
|
+
workspaceId: text("workspace_id").notNull().references(() => workspaces.id, { onDelete: "cascade" }),
|
|
66
88
|
pipelineId: text("pipeline_id").notNull(),
|
|
67
89
|
status: text("status").$type().notNull(),
|
|
68
90
|
startedAt: integer("started_at", { mode: "timestamp" }).notNull(),
|
|
@@ -71,26 +93,29 @@ const executions = sqliteTable("executions", {
|
|
|
71
93
|
summary: text("summary", { mode: "json" }).$type(),
|
|
72
94
|
graph: text("graph", { mode: "json" }).$type(),
|
|
73
95
|
error: text("error")
|
|
74
|
-
});
|
|
96
|
+
}, (table) => [index("executions_workspace_pipeline_idx").on(table.workspaceId, table.pipelineId), index("executions_workspace_started_idx").on(table.workspaceId, table.startedAt)]);
|
|
75
97
|
const events = sqliteTable("events", {
|
|
76
98
|
id: text("id").primaryKey(),
|
|
99
|
+
workspaceId: text("workspace_id").notNull().references(() => workspaces.id, { onDelete: "cascade" }),
|
|
77
100
|
executionId: text("execution_id").notNull().references(() => executions.id, { onDelete: "cascade" }),
|
|
78
101
|
type: text("type").$type().notNull(),
|
|
79
102
|
timestamp: integer("timestamp", { mode: "timestamp" }).notNull(),
|
|
80
103
|
data: text("data", { mode: "json" }).$type()
|
|
81
|
-
});
|
|
104
|
+
}, (table) => [index("events_workspace_execution_idx").on(table.workspaceId, table.executionId)]);
|
|
82
105
|
const executionLogs = sqliteTable("execution_logs", {
|
|
83
106
|
id: text("id").primaryKey(),
|
|
107
|
+
workspaceId: text("workspace_id").notNull().references(() => workspaces.id, { onDelete: "cascade" }),
|
|
84
108
|
executionId: text("execution_id").notNull().references(() => executions.id, { onDelete: "cascade" }),
|
|
85
109
|
spanId: text("span_id"),
|
|
86
110
|
stream: text("stream").$type().notNull(),
|
|
87
111
|
message: text("message").notNull(),
|
|
88
112
|
timestamp: integer("timestamp", { mode: "timestamp" }).notNull(),
|
|
89
113
|
payload: text("payload", { mode: "json" }).$type()
|
|
90
|
-
});
|
|
114
|
+
}, (table) => [index("execution_logs_workspace_execution_idx").on(table.workspaceId, table.executionId), index("execution_logs_workspace_timestamp_idx").on(table.workspaceId, table.timestamp)]);
|
|
91
115
|
function createDatabase(options = {}) {
|
|
116
|
+
const defaultUrl = `file:${getPipelineDbPath()}`;
|
|
92
117
|
return drizzle(createClient({
|
|
93
|
-
url: options.url ?? process$1.env.DB_URL ??
|
|
118
|
+
url: options.url ?? process$1.env.DB_URL ?? defaultUrl,
|
|
94
119
|
authToken: options.authToken ?? process$1.env.DB_AUTH_TOKEN
|
|
95
120
|
}), { schema: schema_exports });
|
|
96
121
|
}
|
|
@@ -102,6 +127,7 @@ async function runMigrations(db) {
|
|
|
102
127
|
const pipelinesEventsRouter = new H3();
|
|
103
128
|
pipelinesEventsRouter.get("/:file/:id/executions/:executionId/events", async (event) => {
|
|
104
129
|
const { db } = event.context;
|
|
130
|
+
const workspaceId = event.context.workspaceId;
|
|
105
131
|
const executionId = event.context.params?.executionId;
|
|
106
132
|
if (!executionId) return { error: "Execution ID is required" };
|
|
107
133
|
const query = getQuery(event);
|
|
@@ -109,7 +135,7 @@ pipelinesEventsRouter.get("/:file/:id/executions/:executionId/events", async (ev
|
|
|
109
135
|
const offset = typeof query.offset === "string" ? Number.parseInt(query.offset, 10) : 0;
|
|
110
136
|
try {
|
|
111
137
|
const execution = await db.query.executions.findFirst({
|
|
112
|
-
where: eq(executions.id, executionId),
|
|
138
|
+
where: and(eq(executions.workspaceId, workspaceId), eq(executions.id, executionId)),
|
|
113
139
|
columns: {
|
|
114
140
|
id: true,
|
|
115
141
|
pipelineId: true,
|
|
@@ -118,15 +144,13 @@ pipelinesEventsRouter.get("/:file/:id/executions/:executionId/events", async (ev
|
|
|
118
144
|
});
|
|
119
145
|
if (!execution) return { error: `Execution "${executionId}" not found` };
|
|
120
146
|
const events$1 = await db.query.events.findMany({
|
|
121
|
-
where: eq(events.executionId, executionId),
|
|
147
|
+
where: and(eq(events.workspaceId, workspaceId), eq(events.executionId, executionId)),
|
|
122
148
|
orderBy: asc(events.timestamp),
|
|
123
149
|
limit,
|
|
124
150
|
offset
|
|
125
151
|
});
|
|
126
|
-
const
|
|
127
|
-
|
|
128
|
-
columns: { id: true }
|
|
129
|
-
})).length;
|
|
152
|
+
const countResult = await db.select({ count: sql`count(*)` }).from(events).where(and(eq(events.workspaceId, workspaceId), eq(events.executionId, executionId)));
|
|
153
|
+
const total = Number(countResult[0]?.count ?? 0);
|
|
130
154
|
return {
|
|
131
155
|
executionId,
|
|
132
156
|
pipelineId: execution.pipelineId,
|
|
@@ -155,6 +179,7 @@ pipelinesEventsRouter.get("/:file/:id/executions/:executionId/events", async (ev
|
|
|
155
179
|
const pipelinesExecutionRouter = new H3();
|
|
156
180
|
pipelinesExecutionRouter.get("/:file/:id/executions", async (event) => {
|
|
157
181
|
const { db } = event.context;
|
|
182
|
+
const workspaceId = event.context.workspaceId;
|
|
158
183
|
const id = event.context.params?.id;
|
|
159
184
|
if (!id) return { error: "Pipeline ID is required" };
|
|
160
185
|
const query = getQuery(event);
|
|
@@ -162,15 +187,13 @@ pipelinesExecutionRouter.get("/:file/:id/executions", async (event) => {
|
|
|
162
187
|
const offset = typeof query.offset === "string" ? Number.parseInt(query.offset, 10) : 0;
|
|
163
188
|
try {
|
|
164
189
|
const executions$1 = await db.query.executions.findMany({
|
|
165
|
-
where: eq(executions.pipelineId, id),
|
|
190
|
+
where: and(eq(executions.workspaceId, workspaceId), eq(executions.pipelineId, id)),
|
|
166
191
|
orderBy: desc(executions.startedAt),
|
|
167
192
|
limit,
|
|
168
193
|
offset
|
|
169
194
|
});
|
|
170
|
-
const
|
|
171
|
-
|
|
172
|
-
columns: { id: true }
|
|
173
|
-
})).length;
|
|
195
|
+
const countResult = await db.select({ count: sql`count(*)` }).from(executions).where(and(eq(executions.workspaceId, workspaceId), eq(executions.pipelineId, id)));
|
|
196
|
+
const total = Number(countResult[0]?.count ?? 0);
|
|
174
197
|
return {
|
|
175
198
|
executions: executions$1.map((exec) => ({
|
|
176
199
|
id: exec.id,
|
|
@@ -2989,7 +3012,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
2989
3012
|
try {
|
|
2990
3013
|
const binding = __require("@rolldown/binding-android-arm64");
|
|
2991
3014
|
const bindingPackageVersion = __require("@rolldown/binding-android-arm64/package.json").version;
|
|
2992
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3015
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
2993
3016
|
return binding;
|
|
2994
3017
|
} catch (e) {
|
|
2995
3018
|
loadErrors.push(e);
|
|
@@ -3003,7 +3026,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3003
3026
|
try {
|
|
3004
3027
|
const binding = __require("@rolldown/binding-android-arm-eabi");
|
|
3005
3028
|
const bindingPackageVersion = __require("@rolldown/binding-android-arm-eabi/package.json").version;
|
|
3006
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3029
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3007
3030
|
return binding;
|
|
3008
3031
|
} catch (e) {
|
|
3009
3032
|
loadErrors.push(e);
|
|
@@ -3018,7 +3041,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3018
3041
|
try {
|
|
3019
3042
|
const binding = __require("@rolldown/binding-win32-x64-gnu");
|
|
3020
3043
|
const bindingPackageVersion = __require("@rolldown/binding-win32-x64-gnu/package.json").version;
|
|
3021
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3044
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3022
3045
|
return binding;
|
|
3023
3046
|
} catch (e) {
|
|
3024
3047
|
loadErrors.push(e);
|
|
@@ -3032,7 +3055,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3032
3055
|
try {
|
|
3033
3056
|
const binding = __require("@rolldown/binding-win32-x64-msvc");
|
|
3034
3057
|
const bindingPackageVersion = __require("@rolldown/binding-win32-x64-msvc/package.json").version;
|
|
3035
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3058
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3036
3059
|
return binding;
|
|
3037
3060
|
} catch (e) {
|
|
3038
3061
|
loadErrors.push(e);
|
|
@@ -3047,7 +3070,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3047
3070
|
try {
|
|
3048
3071
|
const binding = __require("@rolldown/binding-win32-ia32-msvc");
|
|
3049
3072
|
const bindingPackageVersion = __require("@rolldown/binding-win32-ia32-msvc/package.json").version;
|
|
3050
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3073
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3051
3074
|
return binding;
|
|
3052
3075
|
} catch (e) {
|
|
3053
3076
|
loadErrors.push(e);
|
|
@@ -3061,7 +3084,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3061
3084
|
try {
|
|
3062
3085
|
const binding = __require("@rolldown/binding-win32-arm64-msvc");
|
|
3063
3086
|
const bindingPackageVersion = __require("@rolldown/binding-win32-arm64-msvc/package.json").version;
|
|
3064
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3087
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3065
3088
|
return binding;
|
|
3066
3089
|
} catch (e) {
|
|
3067
3090
|
loadErrors.push(e);
|
|
@@ -3076,7 +3099,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3076
3099
|
try {
|
|
3077
3100
|
const binding = __require("@rolldown/binding-darwin-universal");
|
|
3078
3101
|
const bindingPackageVersion = __require("@rolldown/binding-darwin-universal/package.json").version;
|
|
3079
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3102
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3080
3103
|
return binding;
|
|
3081
3104
|
} catch (e) {
|
|
3082
3105
|
loadErrors.push(e);
|
|
@@ -3090,7 +3113,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3090
3113
|
try {
|
|
3091
3114
|
const binding = __require("@rolldown/binding-darwin-x64");
|
|
3092
3115
|
const bindingPackageVersion = __require("@rolldown/binding-darwin-x64/package.json").version;
|
|
3093
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3116
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3094
3117
|
return binding;
|
|
3095
3118
|
} catch (e) {
|
|
3096
3119
|
loadErrors.push(e);
|
|
@@ -3104,7 +3127,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3104
3127
|
try {
|
|
3105
3128
|
const binding = __require("@rolldown/binding-darwin-arm64");
|
|
3106
3129
|
const bindingPackageVersion = __require("@rolldown/binding-darwin-arm64/package.json").version;
|
|
3107
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3130
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3108
3131
|
return binding;
|
|
3109
3132
|
} catch (e) {
|
|
3110
3133
|
loadErrors.push(e);
|
|
@@ -3119,7 +3142,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3119
3142
|
try {
|
|
3120
3143
|
const binding = __require("@rolldown/binding-freebsd-x64");
|
|
3121
3144
|
const bindingPackageVersion = __require("@rolldown/binding-freebsd-x64/package.json").version;
|
|
3122
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3145
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3123
3146
|
return binding;
|
|
3124
3147
|
} catch (e) {
|
|
3125
3148
|
loadErrors.push(e);
|
|
@@ -3133,7 +3156,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3133
3156
|
try {
|
|
3134
3157
|
const binding = __require("@rolldown/binding-freebsd-arm64");
|
|
3135
3158
|
const bindingPackageVersion = __require("@rolldown/binding-freebsd-arm64/package.json").version;
|
|
3136
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3159
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3137
3160
|
return binding;
|
|
3138
3161
|
} catch (e) {
|
|
3139
3162
|
loadErrors.push(e);
|
|
@@ -3148,7 +3171,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3148
3171
|
try {
|
|
3149
3172
|
const binding = __require("@rolldown/binding-linux-x64-musl");
|
|
3150
3173
|
const bindingPackageVersion = __require("@rolldown/binding-linux-x64-musl/package.json").version;
|
|
3151
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3174
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3152
3175
|
return binding;
|
|
3153
3176
|
} catch (e) {
|
|
3154
3177
|
loadErrors.push(e);
|
|
@@ -3162,7 +3185,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3162
3185
|
try {
|
|
3163
3186
|
const binding = __require("@rolldown/binding-linux-x64-gnu");
|
|
3164
3187
|
const bindingPackageVersion = __require("@rolldown/binding-linux-x64-gnu/package.json").version;
|
|
3165
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3188
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3166
3189
|
return binding;
|
|
3167
3190
|
} catch (e) {
|
|
3168
3191
|
loadErrors.push(e);
|
|
@@ -3177,7 +3200,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3177
3200
|
try {
|
|
3178
3201
|
const binding = __require("@rolldown/binding-linux-arm64-musl");
|
|
3179
3202
|
const bindingPackageVersion = __require("@rolldown/binding-linux-arm64-musl/package.json").version;
|
|
3180
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3203
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3181
3204
|
return binding;
|
|
3182
3205
|
} catch (e) {
|
|
3183
3206
|
loadErrors.push(e);
|
|
@@ -3191,7 +3214,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3191
3214
|
try {
|
|
3192
3215
|
const binding = __require("@rolldown/binding-linux-arm64-gnu");
|
|
3193
3216
|
const bindingPackageVersion = __require("@rolldown/binding-linux-arm64-gnu/package.json").version;
|
|
3194
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3217
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3195
3218
|
return binding;
|
|
3196
3219
|
} catch (e) {
|
|
3197
3220
|
loadErrors.push(e);
|
|
@@ -3206,7 +3229,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3206
3229
|
try {
|
|
3207
3230
|
const binding = __require("@rolldown/binding-linux-arm-musleabihf");
|
|
3208
3231
|
const bindingPackageVersion = __require("@rolldown/binding-linux-arm-musleabihf/package.json").version;
|
|
3209
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3232
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3210
3233
|
return binding;
|
|
3211
3234
|
} catch (e) {
|
|
3212
3235
|
loadErrors.push(e);
|
|
@@ -3220,7 +3243,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3220
3243
|
try {
|
|
3221
3244
|
const binding = __require("@rolldown/binding-linux-arm-gnueabihf");
|
|
3222
3245
|
const bindingPackageVersion = __require("@rolldown/binding-linux-arm-gnueabihf/package.json").version;
|
|
3223
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3246
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3224
3247
|
return binding;
|
|
3225
3248
|
} catch (e) {
|
|
3226
3249
|
loadErrors.push(e);
|
|
@@ -3235,7 +3258,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3235
3258
|
try {
|
|
3236
3259
|
const binding = __require("@rolldown/binding-linux-loong64-musl");
|
|
3237
3260
|
const bindingPackageVersion = __require("@rolldown/binding-linux-loong64-musl/package.json").version;
|
|
3238
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3261
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3239
3262
|
return binding;
|
|
3240
3263
|
} catch (e) {
|
|
3241
3264
|
loadErrors.push(e);
|
|
@@ -3249,7 +3272,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3249
3272
|
try {
|
|
3250
3273
|
const binding = __require("@rolldown/binding-linux-loong64-gnu");
|
|
3251
3274
|
const bindingPackageVersion = __require("@rolldown/binding-linux-loong64-gnu/package.json").version;
|
|
3252
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3275
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3253
3276
|
return binding;
|
|
3254
3277
|
} catch (e) {
|
|
3255
3278
|
loadErrors.push(e);
|
|
@@ -3264,7 +3287,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3264
3287
|
try {
|
|
3265
3288
|
const binding = __require("@rolldown/binding-linux-riscv64-musl");
|
|
3266
3289
|
const bindingPackageVersion = __require("@rolldown/binding-linux-riscv64-musl/package.json").version;
|
|
3267
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3290
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3268
3291
|
return binding;
|
|
3269
3292
|
} catch (e) {
|
|
3270
3293
|
loadErrors.push(e);
|
|
@@ -3278,7 +3301,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3278
3301
|
try {
|
|
3279
3302
|
const binding = __require("@rolldown/binding-linux-riscv64-gnu");
|
|
3280
3303
|
const bindingPackageVersion = __require("@rolldown/binding-linux-riscv64-gnu/package.json").version;
|
|
3281
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3304
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3282
3305
|
return binding;
|
|
3283
3306
|
} catch (e) {
|
|
3284
3307
|
loadErrors.push(e);
|
|
@@ -3293,7 +3316,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3293
3316
|
try {
|
|
3294
3317
|
const binding = __require("@rolldown/binding-linux-ppc64-gnu");
|
|
3295
3318
|
const bindingPackageVersion = __require("@rolldown/binding-linux-ppc64-gnu/package.json").version;
|
|
3296
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3319
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3297
3320
|
return binding;
|
|
3298
3321
|
} catch (e) {
|
|
3299
3322
|
loadErrors.push(e);
|
|
@@ -3307,7 +3330,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3307
3330
|
try {
|
|
3308
3331
|
const binding = __require("@rolldown/binding-linux-s390x-gnu");
|
|
3309
3332
|
const bindingPackageVersion = __require("@rolldown/binding-linux-s390x-gnu/package.json").version;
|
|
3310
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3333
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3311
3334
|
return binding;
|
|
3312
3335
|
} catch (e) {
|
|
3313
3336
|
loadErrors.push(e);
|
|
@@ -3322,7 +3345,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3322
3345
|
try {
|
|
3323
3346
|
const binding = __require("@rolldown/binding-openharmony-arm64");
|
|
3324
3347
|
const bindingPackageVersion = __require("@rolldown/binding-openharmony-arm64/package.json").version;
|
|
3325
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3348
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3326
3349
|
return binding;
|
|
3327
3350
|
} catch (e) {
|
|
3328
3351
|
loadErrors.push(e);
|
|
@@ -3336,7 +3359,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3336
3359
|
try {
|
|
3337
3360
|
const binding = __require("@rolldown/binding-openharmony-x64");
|
|
3338
3361
|
const bindingPackageVersion = __require("@rolldown/binding-openharmony-x64/package.json").version;
|
|
3339
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3362
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3340
3363
|
return binding;
|
|
3341
3364
|
} catch (e) {
|
|
3342
3365
|
loadErrors.push(e);
|
|
@@ -3350,7 +3373,7 @@ var require_binding = /* @__PURE__ */ __commonJSMin(((exports, module) => {
|
|
|
3350
3373
|
try {
|
|
3351
3374
|
const binding = __require("@rolldown/binding-openharmony-arm");
|
|
3352
3375
|
const bindingPackageVersion = __require("@rolldown/binding-openharmony-arm/package.json").version;
|
|
3353
|
-
if (bindingPackageVersion !== "1.0.0-rc.
|
|
3376
|
+
if (bindingPackageVersion !== "1.0.0-rc.5" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 1.0.0-rc.5 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
3354
3377
|
return binding;
|
|
3355
3378
|
} catch (e) {
|
|
3356
3379
|
loadErrors.push(e);
|
|
@@ -3927,7 +3950,7 @@ function exclude(expr) {
|
|
|
3927
3950
|
*
|
|
3928
3951
|
* @category Plugin APIs
|
|
3929
3952
|
*/
|
|
3930
|
-
var VERSION = "1.0.0-rc.
|
|
3953
|
+
var VERSION = "1.0.0-rc.5";
|
|
3931
3954
|
var LOG_LEVEL_SILENT = "silent";
|
|
3932
3955
|
var LOG_LEVEL_WARN = "warn";
|
|
3933
3956
|
var LOG_LEVEL_INFO = "info";
|
|
@@ -4450,6 +4473,7 @@ function transformModuleInfo(info, option) {
|
|
|
4450
4473
|
dynamicallyImportedIds: info.dynamicallyImportedIds,
|
|
4451
4474
|
exports: info.exports,
|
|
4452
4475
|
isEntry: info.isEntry,
|
|
4476
|
+
inputFormat: info.inputFormat,
|
|
4453
4477
|
...option
|
|
4454
4478
|
};
|
|
4455
4479
|
}
|
|
@@ -4659,19 +4683,19 @@ function bindingPluginOrder(order) {
|
|
|
4659
4683
|
}
|
|
4660
4684
|
}
|
|
4661
4685
|
var fsModule = {
|
|
4662
|
-
appendFile:
|
|
4663
|
-
copyFile:
|
|
4664
|
-
mkdir:
|
|
4665
|
-
mkdtemp:
|
|
4666
|
-
readdir:
|
|
4667
|
-
readFile:
|
|
4668
|
-
realpath:
|
|
4669
|
-
rename:
|
|
4670
|
-
rmdir:
|
|
4671
|
-
stat:
|
|
4672
|
-
lstat:
|
|
4673
|
-
unlink:
|
|
4674
|
-
writeFile:
|
|
4686
|
+
appendFile: fs.appendFile,
|
|
4687
|
+
copyFile: fs.copyFile,
|
|
4688
|
+
mkdir: fs.mkdir,
|
|
4689
|
+
mkdtemp: fs.mkdtemp,
|
|
4690
|
+
readdir: fs.readdir,
|
|
4691
|
+
readFile: fs.readFile,
|
|
4692
|
+
realpath: fs.realpath,
|
|
4693
|
+
rename: fs.rename,
|
|
4694
|
+
rmdir: fs.rmdir,
|
|
4695
|
+
stat: fs.stat,
|
|
4696
|
+
lstat: fs.lstat,
|
|
4697
|
+
unlink: fs.unlink,
|
|
4698
|
+
writeFile: fs.writeFile
|
|
4675
4699
|
};
|
|
4676
4700
|
var PluginContextImpl = class extends MinimalPluginContextImpl {
|
|
4677
4701
|
fs = fsModule;
|
|
@@ -5991,7 +6015,7 @@ function getLogger(plugins, onLog, logLevel, watchMode) {
|
|
|
5991
6015
|
info: getLogHandler("info"),
|
|
5992
6016
|
meta: {
|
|
5993
6017
|
rollupVersion: "4.23.0",
|
|
5994
|
-
rolldownVersion: "1.0.0-rc.
|
|
6018
|
+
rolldownVersion: "1.0.0-rc.5",
|
|
5995
6019
|
watchMode
|
|
5996
6020
|
},
|
|
5997
6021
|
warn: getLogHandler("warn"),
|
|
@@ -7410,7 +7434,8 @@ var ChecksOptionsSchema = /* @__PURE__ */ strictObject({
|
|
|
7410
7434
|
couldNotCleanDirectory: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Whether to emit warnings when Rolldown could not clean the output directory")),
|
|
7411
7435
|
pluginTimings: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Whether to emit warnings when plugins take significant time during the build process")),
|
|
7412
7436
|
duplicateShebang: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Whether to emit warnings when both the code and postBanner contain shebang")),
|
|
7413
|
-
unsupportedTsconfigOption: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Whether to emit warnings when a tsconfig option or combination of options is not supported"))
|
|
7437
|
+
unsupportedTsconfigOption: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Whether to emit warnings when a tsconfig option or combination of options is not supported")),
|
|
7438
|
+
ineffectiveDynamicImport: /* @__PURE__ */ pipe(/* @__PURE__ */ optional(/* @__PURE__ */ boolean()), /* @__PURE__ */ description("Whether to emit warnings when a module is dynamically imported but also statically imported, making the dynamic import ineffective for code splitting"))
|
|
7414
7439
|
});
|
|
7415
7440
|
isTypeTrue();
|
|
7416
7441
|
var CompressOptionsKeepNamesSchema = /* @__PURE__ */ strictObject({
|
|
@@ -7634,7 +7659,9 @@ var AdvancedChunksSchema = /* @__PURE__ */ strictObject({
|
|
|
7634
7659
|
minShareCount: /* @__PURE__ */ optional(/* @__PURE__ */ number()),
|
|
7635
7660
|
maxSize: /* @__PURE__ */ optional(/* @__PURE__ */ number()),
|
|
7636
7661
|
minModuleSize: /* @__PURE__ */ optional(/* @__PURE__ */ number()),
|
|
7637
|
-
maxModuleSize: /* @__PURE__ */ optional(/* @__PURE__ */ number())
|
|
7662
|
+
maxModuleSize: /* @__PURE__ */ optional(/* @__PURE__ */ number()),
|
|
7663
|
+
entriesAware: /* @__PURE__ */ optional(/* @__PURE__ */ boolean()),
|
|
7664
|
+
entriesAwareMergeThreshold: /* @__PURE__ */ optional(/* @__PURE__ */ number())
|
|
7638
7665
|
})))
|
|
7639
7666
|
});
|
|
7640
7667
|
isTypeTrue();
|
|
@@ -9564,7 +9591,7 @@ function requireNative() {
|
|
|
9564
9591
|
try {
|
|
9565
9592
|
const binding = require$1("@oxc-transform/binding-android-arm64");
|
|
9566
9593
|
const bindingPackageVersion = require$1("@oxc-transform/binding-android-arm64/package.json").version;
|
|
9567
|
-
if (bindingPackageVersion !== "0.
|
|
9594
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9568
9595
|
return binding;
|
|
9569
9596
|
} catch (e) {
|
|
9570
9597
|
loadErrors.push(e);
|
|
@@ -9578,7 +9605,7 @@ function requireNative() {
|
|
|
9578
9605
|
try {
|
|
9579
9606
|
const binding = require$1("@oxc-transform/binding-android-arm-eabi");
|
|
9580
9607
|
const bindingPackageVersion = require$1("@oxc-transform/binding-android-arm-eabi/package.json").version;
|
|
9581
|
-
if (bindingPackageVersion !== "0.
|
|
9608
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9582
9609
|
return binding;
|
|
9583
9610
|
} catch (e) {
|
|
9584
9611
|
loadErrors.push(e);
|
|
@@ -9593,7 +9620,7 @@ function requireNative() {
|
|
|
9593
9620
|
try {
|
|
9594
9621
|
const binding = require$1("@oxc-transform/binding-win32-x64-gnu");
|
|
9595
9622
|
const bindingPackageVersion = require$1("@oxc-transform/binding-win32-x64-gnu/package.json").version;
|
|
9596
|
-
if (bindingPackageVersion !== "0.
|
|
9623
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9597
9624
|
return binding;
|
|
9598
9625
|
} catch (e) {
|
|
9599
9626
|
loadErrors.push(e);
|
|
@@ -9607,7 +9634,7 @@ function requireNative() {
|
|
|
9607
9634
|
try {
|
|
9608
9635
|
const binding = require$1("@oxc-transform/binding-win32-x64-msvc");
|
|
9609
9636
|
const bindingPackageVersion = require$1("@oxc-transform/binding-win32-x64-msvc/package.json").version;
|
|
9610
|
-
if (bindingPackageVersion !== "0.
|
|
9637
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9611
9638
|
return binding;
|
|
9612
9639
|
} catch (e) {
|
|
9613
9640
|
loadErrors.push(e);
|
|
@@ -9622,7 +9649,7 @@ function requireNative() {
|
|
|
9622
9649
|
try {
|
|
9623
9650
|
const binding = require$1("@oxc-transform/binding-win32-ia32-msvc");
|
|
9624
9651
|
const bindingPackageVersion = require$1("@oxc-transform/binding-win32-ia32-msvc/package.json").version;
|
|
9625
|
-
if (bindingPackageVersion !== "0.
|
|
9652
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9626
9653
|
return binding;
|
|
9627
9654
|
} catch (e) {
|
|
9628
9655
|
loadErrors.push(e);
|
|
@@ -9636,7 +9663,7 @@ function requireNative() {
|
|
|
9636
9663
|
try {
|
|
9637
9664
|
const binding = require$1("@oxc-transform/binding-win32-arm64-msvc");
|
|
9638
9665
|
const bindingPackageVersion = require$1("@oxc-transform/binding-win32-arm64-msvc/package.json").version;
|
|
9639
|
-
if (bindingPackageVersion !== "0.
|
|
9666
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9640
9667
|
return binding;
|
|
9641
9668
|
} catch (e) {
|
|
9642
9669
|
loadErrors.push(e);
|
|
@@ -9651,7 +9678,7 @@ function requireNative() {
|
|
|
9651
9678
|
try {
|
|
9652
9679
|
const binding = require$1("@oxc-transform/binding-darwin-universal");
|
|
9653
9680
|
const bindingPackageVersion = require$1("@oxc-transform/binding-darwin-universal/package.json").version;
|
|
9654
|
-
if (bindingPackageVersion !== "0.
|
|
9681
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9655
9682
|
return binding;
|
|
9656
9683
|
} catch (e) {
|
|
9657
9684
|
loadErrors.push(e);
|
|
@@ -9665,7 +9692,7 @@ function requireNative() {
|
|
|
9665
9692
|
try {
|
|
9666
9693
|
const binding = require$1("@oxc-transform/binding-darwin-x64");
|
|
9667
9694
|
const bindingPackageVersion = require$1("@oxc-transform/binding-darwin-x64/package.json").version;
|
|
9668
|
-
if (bindingPackageVersion !== "0.
|
|
9695
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9669
9696
|
return binding;
|
|
9670
9697
|
} catch (e) {
|
|
9671
9698
|
loadErrors.push(e);
|
|
@@ -9679,7 +9706,7 @@ function requireNative() {
|
|
|
9679
9706
|
try {
|
|
9680
9707
|
const binding = require$1("@oxc-transform/binding-darwin-arm64");
|
|
9681
9708
|
const bindingPackageVersion = require$1("@oxc-transform/binding-darwin-arm64/package.json").version;
|
|
9682
|
-
if (bindingPackageVersion !== "0.
|
|
9709
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9683
9710
|
return binding;
|
|
9684
9711
|
} catch (e) {
|
|
9685
9712
|
loadErrors.push(e);
|
|
@@ -9694,7 +9721,7 @@ function requireNative() {
|
|
|
9694
9721
|
try {
|
|
9695
9722
|
const binding = require$1("@oxc-transform/binding-freebsd-x64");
|
|
9696
9723
|
const bindingPackageVersion = require$1("@oxc-transform/binding-freebsd-x64/package.json").version;
|
|
9697
|
-
if (bindingPackageVersion !== "0.
|
|
9724
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9698
9725
|
return binding;
|
|
9699
9726
|
} catch (e) {
|
|
9700
9727
|
loadErrors.push(e);
|
|
@@ -9708,7 +9735,7 @@ function requireNative() {
|
|
|
9708
9735
|
try {
|
|
9709
9736
|
const binding = require$1("@oxc-transform/binding-freebsd-arm64");
|
|
9710
9737
|
const bindingPackageVersion = require$1("@oxc-transform/binding-freebsd-arm64/package.json").version;
|
|
9711
|
-
if (bindingPackageVersion !== "0.
|
|
9738
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9712
9739
|
return binding;
|
|
9713
9740
|
} catch (e) {
|
|
9714
9741
|
loadErrors.push(e);
|
|
@@ -9723,7 +9750,7 @@ function requireNative() {
|
|
|
9723
9750
|
try {
|
|
9724
9751
|
const binding = require$1("@oxc-transform/binding-linux-x64-musl");
|
|
9725
9752
|
const bindingPackageVersion = require$1("@oxc-transform/binding-linux-x64-musl/package.json").version;
|
|
9726
|
-
if (bindingPackageVersion !== "0.
|
|
9753
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9727
9754
|
return binding;
|
|
9728
9755
|
} catch (e) {
|
|
9729
9756
|
loadErrors.push(e);
|
|
@@ -9737,7 +9764,7 @@ function requireNative() {
|
|
|
9737
9764
|
try {
|
|
9738
9765
|
const binding = require$1("@oxc-transform/binding-linux-x64-gnu");
|
|
9739
9766
|
const bindingPackageVersion = require$1("@oxc-transform/binding-linux-x64-gnu/package.json").version;
|
|
9740
|
-
if (bindingPackageVersion !== "0.
|
|
9767
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9741
9768
|
return binding;
|
|
9742
9769
|
} catch (e) {
|
|
9743
9770
|
loadErrors.push(e);
|
|
@@ -9752,7 +9779,7 @@ function requireNative() {
|
|
|
9752
9779
|
try {
|
|
9753
9780
|
const binding = require$1("@oxc-transform/binding-linux-arm64-musl");
|
|
9754
9781
|
const bindingPackageVersion = require$1("@oxc-transform/binding-linux-arm64-musl/package.json").version;
|
|
9755
|
-
if (bindingPackageVersion !== "0.
|
|
9782
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9756
9783
|
return binding;
|
|
9757
9784
|
} catch (e) {
|
|
9758
9785
|
loadErrors.push(e);
|
|
@@ -9766,7 +9793,7 @@ function requireNative() {
|
|
|
9766
9793
|
try {
|
|
9767
9794
|
const binding = require$1("@oxc-transform/binding-linux-arm64-gnu");
|
|
9768
9795
|
const bindingPackageVersion = require$1("@oxc-transform/binding-linux-arm64-gnu/package.json").version;
|
|
9769
|
-
if (bindingPackageVersion !== "0.
|
|
9796
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9770
9797
|
return binding;
|
|
9771
9798
|
} catch (e) {
|
|
9772
9799
|
loadErrors.push(e);
|
|
@@ -9781,7 +9808,7 @@ function requireNative() {
|
|
|
9781
9808
|
try {
|
|
9782
9809
|
const binding = require$1("@oxc-transform/binding-linux-arm-musleabihf");
|
|
9783
9810
|
const bindingPackageVersion = require$1("@oxc-transform/binding-linux-arm-musleabihf/package.json").version;
|
|
9784
|
-
if (bindingPackageVersion !== "0.
|
|
9811
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9785
9812
|
return binding;
|
|
9786
9813
|
} catch (e) {
|
|
9787
9814
|
loadErrors.push(e);
|
|
@@ -9795,7 +9822,7 @@ function requireNative() {
|
|
|
9795
9822
|
try {
|
|
9796
9823
|
const binding = require$1("@oxc-transform/binding-linux-arm-gnueabihf");
|
|
9797
9824
|
const bindingPackageVersion = require$1("@oxc-transform/binding-linux-arm-gnueabihf/package.json").version;
|
|
9798
|
-
if (bindingPackageVersion !== "0.
|
|
9825
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9799
9826
|
return binding;
|
|
9800
9827
|
} catch (e) {
|
|
9801
9828
|
loadErrors.push(e);
|
|
@@ -9810,7 +9837,7 @@ function requireNative() {
|
|
|
9810
9837
|
try {
|
|
9811
9838
|
const binding = require$1("@oxc-transform/binding-linux-loong64-musl");
|
|
9812
9839
|
const bindingPackageVersion = require$1("@oxc-transform/binding-linux-loong64-musl/package.json").version;
|
|
9813
|
-
if (bindingPackageVersion !== "0.
|
|
9840
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9814
9841
|
return binding;
|
|
9815
9842
|
} catch (e) {
|
|
9816
9843
|
loadErrors.push(e);
|
|
@@ -9824,7 +9851,7 @@ function requireNative() {
|
|
|
9824
9851
|
try {
|
|
9825
9852
|
const binding = require$1("@oxc-transform/binding-linux-loong64-gnu");
|
|
9826
9853
|
const bindingPackageVersion = require$1("@oxc-transform/binding-linux-loong64-gnu/package.json").version;
|
|
9827
|
-
if (bindingPackageVersion !== "0.
|
|
9854
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9828
9855
|
return binding;
|
|
9829
9856
|
} catch (e) {
|
|
9830
9857
|
loadErrors.push(e);
|
|
@@ -9839,7 +9866,7 @@ function requireNative() {
|
|
|
9839
9866
|
try {
|
|
9840
9867
|
const binding = require$1("@oxc-transform/binding-linux-riscv64-musl");
|
|
9841
9868
|
const bindingPackageVersion = require$1("@oxc-transform/binding-linux-riscv64-musl/package.json").version;
|
|
9842
|
-
if (bindingPackageVersion !== "0.
|
|
9869
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9843
9870
|
return binding;
|
|
9844
9871
|
} catch (e) {
|
|
9845
9872
|
loadErrors.push(e);
|
|
@@ -9853,7 +9880,7 @@ function requireNative() {
|
|
|
9853
9880
|
try {
|
|
9854
9881
|
const binding = require$1("@oxc-transform/binding-linux-riscv64-gnu");
|
|
9855
9882
|
const bindingPackageVersion = require$1("@oxc-transform/binding-linux-riscv64-gnu/package.json").version;
|
|
9856
|
-
if (bindingPackageVersion !== "0.
|
|
9883
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9857
9884
|
return binding;
|
|
9858
9885
|
} catch (e) {
|
|
9859
9886
|
loadErrors.push(e);
|
|
@@ -9868,7 +9895,7 @@ function requireNative() {
|
|
|
9868
9895
|
try {
|
|
9869
9896
|
const binding = require$1("@oxc-transform/binding-linux-ppc64-gnu");
|
|
9870
9897
|
const bindingPackageVersion = require$1("@oxc-transform/binding-linux-ppc64-gnu/package.json").version;
|
|
9871
|
-
if (bindingPackageVersion !== "0.
|
|
9898
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9872
9899
|
return binding;
|
|
9873
9900
|
} catch (e) {
|
|
9874
9901
|
loadErrors.push(e);
|
|
@@ -9882,7 +9909,7 @@ function requireNative() {
|
|
|
9882
9909
|
try {
|
|
9883
9910
|
const binding = require$1("@oxc-transform/binding-linux-s390x-gnu");
|
|
9884
9911
|
const bindingPackageVersion = require$1("@oxc-transform/binding-linux-s390x-gnu/package.json").version;
|
|
9885
|
-
if (bindingPackageVersion !== "0.
|
|
9912
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9886
9913
|
return binding;
|
|
9887
9914
|
} catch (e) {
|
|
9888
9915
|
loadErrors.push(e);
|
|
@@ -9897,7 +9924,7 @@ function requireNative() {
|
|
|
9897
9924
|
try {
|
|
9898
9925
|
const binding = require$1("@oxc-transform/binding-openharmony-arm64");
|
|
9899
9926
|
const bindingPackageVersion = require$1("@oxc-transform/binding-openharmony-arm64/package.json").version;
|
|
9900
|
-
if (bindingPackageVersion !== "0.
|
|
9927
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9901
9928
|
return binding;
|
|
9902
9929
|
} catch (e) {
|
|
9903
9930
|
loadErrors.push(e);
|
|
@@ -9911,7 +9938,7 @@ function requireNative() {
|
|
|
9911
9938
|
try {
|
|
9912
9939
|
const binding = require$1("@oxc-transform/binding-openharmony-x64");
|
|
9913
9940
|
const bindingPackageVersion = require$1("@oxc-transform/binding-openharmony-x64/package.json").version;
|
|
9914
|
-
if (bindingPackageVersion !== "0.
|
|
9941
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9915
9942
|
return binding;
|
|
9916
9943
|
} catch (e) {
|
|
9917
9944
|
loadErrors.push(e);
|
|
@@ -9925,7 +9952,7 @@ function requireNative() {
|
|
|
9925
9952
|
try {
|
|
9926
9953
|
const binding = require$1("@oxc-transform/binding-openharmony-arm");
|
|
9927
9954
|
const bindingPackageVersion = require$1("@oxc-transform/binding-openharmony-arm/package.json").version;
|
|
9928
|
-
if (bindingPackageVersion !== "0.
|
|
9955
|
+
if (bindingPackageVersion !== "0.114.0" && process.env.NAPI_RS_ENFORCE_VERSION_CHECK && process.env.NAPI_RS_ENFORCE_VERSION_CHECK !== "0") throw new Error(`Native binding package version mismatch, expected 0.114.0 but got ${bindingPackageVersion}. You can reinstall dependencies to fix this issue.`);
|
|
9929
9956
|
return binding;
|
|
9930
9957
|
} catch (e) {
|
|
9931
9958
|
loadErrors.push(e);
|
|
@@ -10347,12 +10374,13 @@ pipelinesFileRouter.get("/:file", async (event) => {
|
|
|
10347
10374
|
const pipelinesGraphRouter = new H3();
|
|
10348
10375
|
pipelinesGraphRouter.get("/:file/:id/executions/:executionId/graph", async (event) => {
|
|
10349
10376
|
const { db } = event.context;
|
|
10377
|
+
const workspaceId = event.context.workspaceId;
|
|
10350
10378
|
const executionId = event.context.params?.executionId;
|
|
10351
10379
|
const pipelineId = event.context.params?.id;
|
|
10352
10380
|
if (!executionId || !pipelineId) return { error: "Execution ID and pipeline ID are required" };
|
|
10353
10381
|
try {
|
|
10354
10382
|
const execution = await db.query.executions.findFirst({
|
|
10355
|
-
where: eq(executions.id, executionId),
|
|
10383
|
+
where: and(eq(executions.workspaceId, workspaceId), eq(executions.id, executionId)),
|
|
10356
10384
|
columns: {
|
|
10357
10385
|
id: true,
|
|
10358
10386
|
pipelineId: true,
|
|
@@ -10387,6 +10415,7 @@ pipelinesIndexRouter.get("/", async (event) => {
|
|
|
10387
10415
|
allErrors.push(...group.errors);
|
|
10388
10416
|
}
|
|
10389
10417
|
return {
|
|
10418
|
+
workspaceId: event.context.workspaceId,
|
|
10390
10419
|
files: allFiles.map((file) => ({
|
|
10391
10420
|
fileId: file.fileId,
|
|
10392
10421
|
filePath: file.filePath,
|
|
@@ -10400,6 +10429,7 @@ pipelinesIndexRouter.get("/", async (event) => {
|
|
|
10400
10429
|
const pipelinesLogsRouter = new H3();
|
|
10401
10430
|
pipelinesLogsRouter.get("/:file/:id/executions/:executionId/logs", async (event) => {
|
|
10402
10431
|
const { db } = event.context;
|
|
10432
|
+
const workspaceId = event.context.workspaceId;
|
|
10403
10433
|
const executionId = event.context.params?.executionId;
|
|
10404
10434
|
if (!executionId) return { error: "Execution ID is required" };
|
|
10405
10435
|
const query = getQuery(event);
|
|
@@ -10408,7 +10438,7 @@ pipelinesLogsRouter.get("/:file/:id/executions/:executionId/logs", async (event)
|
|
|
10408
10438
|
const spanId = typeof query.spanId === "string" ? query.spanId : void 0;
|
|
10409
10439
|
try {
|
|
10410
10440
|
const execution = await db.query.executions.findFirst({
|
|
10411
|
-
where: eq(executions.id, executionId),
|
|
10441
|
+
where: and(eq(executions.workspaceId, workspaceId), eq(executions.id, executionId)),
|
|
10412
10442
|
columns: {
|
|
10413
10443
|
id: true,
|
|
10414
10444
|
pipelineId: true,
|
|
@@ -10416,7 +10446,7 @@ pipelinesLogsRouter.get("/:file/:id/executions/:executionId/logs", async (event)
|
|
|
10416
10446
|
}
|
|
10417
10447
|
});
|
|
10418
10448
|
if (!execution) return { error: `Execution "${executionId}" not found` };
|
|
10419
|
-
const whereClause = spanId ? and(eq(executionLogs.executionId, executionId), eq(executionLogs.spanId, spanId)) : eq(executionLogs.executionId, executionId);
|
|
10449
|
+
const whereClause = spanId ? and(eq(executionLogs.workspaceId, workspaceId), eq(executionLogs.executionId, executionId), eq(executionLogs.spanId, spanId)) : and(eq(executionLogs.workspaceId, workspaceId), eq(executionLogs.executionId, executionId));
|
|
10420
10450
|
const logs = await db.query.executionLogs.findMany({
|
|
10421
10451
|
where: whereClause,
|
|
10422
10452
|
orderBy: asc(executionLogs.timestamp),
|
|
@@ -10600,6 +10630,7 @@ async function storeExecutionLog(db, state, options) {
|
|
|
10600
10630
|
}
|
|
10601
10631
|
await db.insert(executionLogs).values({
|
|
10602
10632
|
id: randomUUID(),
|
|
10633
|
+
workspaceId: options.workspaceId,
|
|
10603
10634
|
executionId: options.executionId,
|
|
10604
10635
|
spanId: options.spanId ?? null,
|
|
10605
10636
|
stream: options.stream,
|
|
@@ -11531,6 +11562,7 @@ function createExecutionLogCapture(db) {
|
|
|
11531
11562
|
const message = buildMessage(args);
|
|
11532
11563
|
const executionId = context.executionId;
|
|
11533
11564
|
const spanId = context.spanId;
|
|
11565
|
+
const workspaceId = context.workspaceId;
|
|
11534
11566
|
const payload = buildPayload(args, message, stream, context.event);
|
|
11535
11567
|
let executionState = stateByExecution.get(executionId);
|
|
11536
11568
|
if (!executionState) {
|
|
@@ -11544,6 +11576,7 @@ function createExecutionLogCapture(db) {
|
|
|
11544
11576
|
}
|
|
11545
11577
|
const result = await storeExecutionLog(db, executionState.state, {
|
|
11546
11578
|
executionId,
|
|
11579
|
+
workspaceId,
|
|
11547
11580
|
spanId,
|
|
11548
11581
|
stream,
|
|
11549
11582
|
message,
|
|
@@ -11555,6 +11588,7 @@ function createExecutionLogCapture(db) {
|
|
|
11555
11588
|
const bannerPayload = buildTruncationBanner(executionState.state, stream);
|
|
11556
11589
|
await storeExecutionLog(db, executionState.state, {
|
|
11557
11590
|
executionId,
|
|
11591
|
+
workspaceId,
|
|
11558
11592
|
spanId,
|
|
11559
11593
|
stream,
|
|
11560
11594
|
message: bannerPayload.message,
|
|
@@ -11693,7 +11727,7 @@ async function getPipelineFileForSource(source, filePath) {
|
|
|
11693
11727
|
if (source.type === "local") {
|
|
11694
11728
|
const resolvedPath = resolveLocalFilePath(source.cwd, filePath);
|
|
11695
11729
|
return {
|
|
11696
|
-
content: await fs.promises.readFile(resolvedPath, "utf-8"),
|
|
11730
|
+
content: await fs$1.promises.readFile(resolvedPath, "utf-8"),
|
|
11697
11731
|
filePath
|
|
11698
11732
|
};
|
|
11699
11733
|
}
|
|
@@ -11752,9 +11786,10 @@ pipelinesPipelineRouter.get("/:file/:id/code", async (event) => {
|
|
|
11752
11786
|
});
|
|
11753
11787
|
pipelinesPipelineRouter.post("/:file/:id/execute", async (event) => {
|
|
11754
11788
|
const { sources, db } = event.context;
|
|
11789
|
+
const workspaceId = event.context.workspaceId;
|
|
11755
11790
|
const fileId = event.context.params?.file;
|
|
11756
11791
|
const id = event.context.params?.id;
|
|
11757
|
-
if (!fileId || !id) return { error: "File ID and
|
|
11792
|
+
if (!fileId || !id || !workspaceId) return { error: "File ID, pipeline ID, and workspace ID are required" };
|
|
11758
11793
|
const localSources = sources.filter((s) => s.type === "local");
|
|
11759
11794
|
if (localSources.length === 0) return { error: "No local sources configured for pipeline execution" };
|
|
11760
11795
|
const body = await readValidatedBody(event, z.object({
|
|
@@ -11772,6 +11807,7 @@ pipelinesPipelineRouter.post("/:file/:id/execute", async (event) => {
|
|
|
11772
11807
|
const startedAt = /* @__PURE__ */ new Date();
|
|
11773
11808
|
await db.insert(executions).values({
|
|
11774
11809
|
id: executionId,
|
|
11810
|
+
workspaceId,
|
|
11775
11811
|
pipelineId: id,
|
|
11776
11812
|
status: "running",
|
|
11777
11813
|
startedAt,
|
|
@@ -11782,6 +11818,7 @@ pipelinesPipelineRouter.post("/:file/:id/execute", async (event) => {
|
|
|
11782
11818
|
const executor = createPipelineExecutor({ onEvent: async (evt) => {
|
|
11783
11819
|
await db.insert(events).values({
|
|
11784
11820
|
id: randomUUID(),
|
|
11821
|
+
workspaceId,
|
|
11785
11822
|
executionId,
|
|
11786
11823
|
type: evt.type,
|
|
11787
11824
|
timestamp: new Date(evt.timestamp),
|
|
@@ -11789,7 +11826,10 @@ pipelinesPipelineRouter.post("/:file/:id/execute", async (event) => {
|
|
|
11789
11826
|
});
|
|
11790
11827
|
} });
|
|
11791
11828
|
try {
|
|
11792
|
-
const pipelineResult = (await runWithPipelineExecutionContext({
|
|
11829
|
+
const pipelineResult = (await runWithPipelineExecutionContext({
|
|
11830
|
+
executionId,
|
|
11831
|
+
workspaceId
|
|
11832
|
+
}, async () => {
|
|
11793
11833
|
return executor.run([pipeline], {
|
|
11794
11834
|
versions,
|
|
11795
11835
|
cache
|
|
@@ -11801,7 +11841,7 @@ pipelinesPipelineRouter.post("/:file/:id/execute", async (event) => {
|
|
|
11801
11841
|
completedAt,
|
|
11802
11842
|
summary: pipelineResult?.summary ?? null,
|
|
11803
11843
|
graph: pipelineResult?.graph ?? null
|
|
11804
|
-
}).where(eq(executions.id, executionId));
|
|
11844
|
+
}).where(and(eq(executions.workspaceId, workspaceId), eq(executions.id, executionId)));
|
|
11805
11845
|
console.info("Pipeline execution completed:", {
|
|
11806
11846
|
executionId,
|
|
11807
11847
|
pipelineId: id,
|
|
@@ -11818,7 +11858,7 @@ pipelinesPipelineRouter.post("/:file/:id/execute", async (event) => {
|
|
|
11818
11858
|
status: "failed",
|
|
11819
11859
|
completedAt,
|
|
11820
11860
|
error: errorMessage
|
|
11821
|
-
}).where(eq(executions.id, executionId));
|
|
11861
|
+
}).where(and(eq(executions.workspaceId, workspaceId), eq(executions.id, executionId)));
|
|
11822
11862
|
return {
|
|
11823
11863
|
success: false,
|
|
11824
11864
|
executionId,
|
|
@@ -11830,8 +11870,48 @@ pipelinesPipelineRouter.post("/:file/:id/execute", async (event) => {
|
|
|
11830
11870
|
}
|
|
11831
11871
|
return { error: `Pipeline "${id}" not found in local sources` };
|
|
11832
11872
|
});
|
|
11873
|
+
const WORKSPACE_CONFIG_FILENAME = "ucd-pipelines.config.json";
|
|
11874
|
+
function resolveWorkspaceRoot(options = {}) {
|
|
11875
|
+
if (options.rootPath) return options.rootPath;
|
|
11876
|
+
const localSources = (options.sources ?? []).filter((source) => source.type === "local");
|
|
11877
|
+
if (localSources.length > 0) return localSources[0]?.cwd ?? process$1.cwd();
|
|
11878
|
+
return process$1.cwd();
|
|
11879
|
+
}
|
|
11880
|
+
function resolveWorkspace(options = {}) {
|
|
11881
|
+
const rootPath = resolveWorkspaceRoot(options);
|
|
11882
|
+
const normalizedRoot = path.normalize(path.resolve(rootPath));
|
|
11883
|
+
const configPath = path.join(normalizedRoot, WORKSPACE_CONFIG_FILENAME);
|
|
11884
|
+
let workspaceId;
|
|
11885
|
+
if (fs$1.existsSync(configPath)) try {
|
|
11886
|
+
const content = fs$1.readFileSync(configPath, "utf-8");
|
|
11887
|
+
const parsed = JSON.parse(content);
|
|
11888
|
+
if (typeof parsed?.workspaceId === "string" && parsed.workspaceId.length > 0) workspaceId = parsed.workspaceId;
|
|
11889
|
+
} catch {
|
|
11890
|
+
workspaceId = void 0;
|
|
11891
|
+
}
|
|
11892
|
+
return {
|
|
11893
|
+
workspaceId: workspaceId ?? createHash("sha256").update(normalizedRoot).digest("hex"),
|
|
11894
|
+
rootPath: normalizedRoot,
|
|
11895
|
+
source: workspaceId ? "config" : "path"
|
|
11896
|
+
};
|
|
11897
|
+
}
|
|
11898
|
+
async function ensureWorkspace(db, workspaceId, rootPath) {
|
|
11899
|
+
const now = /* @__PURE__ */ new Date();
|
|
11900
|
+
await db.insert(workspaces).values({
|
|
11901
|
+
id: workspaceId,
|
|
11902
|
+
rootPath,
|
|
11903
|
+
createdAt: now,
|
|
11904
|
+
updatedAt: now
|
|
11905
|
+
}).onConflictDoUpdate({
|
|
11906
|
+
target: workspaces.id,
|
|
11907
|
+
set: {
|
|
11908
|
+
rootPath,
|
|
11909
|
+
updatedAt: now
|
|
11910
|
+
}
|
|
11911
|
+
});
|
|
11912
|
+
}
|
|
11833
11913
|
function createApp(options = {}) {
|
|
11834
|
-
const { sources = [], db } = options;
|
|
11914
|
+
const { sources = [], db, workspaceId } = options;
|
|
11835
11915
|
if (!db) throw new Error("Database is required. Pass db to createApp() or use startServer()");
|
|
11836
11916
|
const app = new H3({ debug: true });
|
|
11837
11917
|
let resolvedSources = sources;
|
|
@@ -11851,6 +11931,7 @@ function createApp(options = {}) {
|
|
|
11851
11931
|
app.use("/**", (event, next) => {
|
|
11852
11932
|
event.context.sources = resolvedSources;
|
|
11853
11933
|
event.context.db = db;
|
|
11934
|
+
event.context.workspaceId = workspaceId ?? "default";
|
|
11854
11935
|
next();
|
|
11855
11936
|
});
|
|
11856
11937
|
app.get("/api/hello", () => ({
|
|
@@ -11867,7 +11948,8 @@ function createApp(options = {}) {
|
|
|
11867
11948
|
return app;
|
|
11868
11949
|
}
|
|
11869
11950
|
async function startServer(options = {}) {
|
|
11870
|
-
const { port = 3030, sources } = options;
|
|
11951
|
+
const { port = 3030, sources, workspaceId, workspaceRoot } = options;
|
|
11952
|
+
await fs.mkdir(getUcdConfigDir(), { recursive: true });
|
|
11871
11953
|
const db = createDatabase();
|
|
11872
11954
|
try {
|
|
11873
11955
|
await runMigrations(db);
|
|
@@ -11876,20 +11958,29 @@ async function startServer(options = {}) {
|
|
|
11876
11958
|
console.error("Failed to run database migrations:", err);
|
|
11877
11959
|
throw err;
|
|
11878
11960
|
}
|
|
11961
|
+
const resolvedWorkspace = workspaceId ? {
|
|
11962
|
+
workspaceId,
|
|
11963
|
+
rootPath: workspaceRoot ?? process$1.cwd()
|
|
11964
|
+
} : resolveWorkspace({
|
|
11965
|
+
sources,
|
|
11966
|
+
rootPath: workspaceRoot
|
|
11967
|
+
});
|
|
11968
|
+
await ensureWorkspace(db, resolvedWorkspace.workspaceId, resolvedWorkspace.rootPath);
|
|
11879
11969
|
const app = createApp({
|
|
11880
11970
|
sources,
|
|
11881
|
-
db
|
|
11971
|
+
db,
|
|
11972
|
+
workspaceId: resolvedWorkspace.workspaceId
|
|
11882
11973
|
});
|
|
11883
11974
|
const clientDir = path.join(import.meta.dirname, "../client");
|
|
11884
11975
|
app.use((event) => {
|
|
11885
11976
|
if (event.url.pathname.startsWith("/api")) return;
|
|
11886
11977
|
return serveStatic(event, {
|
|
11887
11978
|
fallthrough: true,
|
|
11888
|
-
getContents: (id) => fs.
|
|
11979
|
+
getContents: (id) => fs.readFile(path.join(clientDir, id)),
|
|
11889
11980
|
getMeta: async (id) => {
|
|
11890
11981
|
const filePath = path.join(clientDir, id);
|
|
11891
11982
|
try {
|
|
11892
|
-
const stats = await fs.
|
|
11983
|
+
const stats = await fs.stat(filePath);
|
|
11893
11984
|
if (!stats.isFile()) return;
|
|
11894
11985
|
return {
|
|
11895
11986
|
size: stats.size,
|
|
@@ -11902,7 +11993,7 @@ async function startServer(options = {}) {
|
|
|
11902
11993
|
app.use((event) => {
|
|
11903
11994
|
if (event.url.pathname.startsWith("/api")) return;
|
|
11904
11995
|
const indexPath = path.join(clientDir, "index.html");
|
|
11905
|
-
return fs.
|
|
11996
|
+
return fs.readFile(indexPath, "utf-8").then((html) => {
|
|
11906
11997
|
return new Response(html, { headers: { "content-type": "text/html" } });
|
|
11907
11998
|
});
|
|
11908
11999
|
});
|