@walkeros/cli 4.2.0-next-1780571888599 → 4.2.0-next-1780577792479
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 +12 -5
- package/dist/cli.js +16 -7
- package/dist/index.d.ts +13 -0
- package/dist/index.js +27 -6
- package/dist/index.js.map +1 -1
- package/package.json +7 -7
package/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @walkeros/cli
|
|
2
2
|
|
|
3
|
-
## 4.2.0-next-
|
|
3
|
+
## 4.2.0-next-1780577792479
|
|
4
4
|
|
|
5
5
|
### Minor Changes
|
|
6
6
|
|
|
@@ -33,6 +33,13 @@
|
|
|
33
33
|
Commander 15, better-sqlite3 12, @libsql/client 0.17, Google Cloud
|
|
34
34
|
functions-framework 5, mixpanel 0.22, and jsdom 29. No public API changes;
|
|
35
35
|
installs now pull the current versions of these SDKs.
|
|
36
|
+
- d39a6a1: Bundle skeletons now expose each package's dev exports through a lazy
|
|
37
|
+
loader. Production deploy bundles drop it entirely, so a shipped `walker.js`
|
|
38
|
+
never carries the dev schema graph, while in-process simulate and push inline
|
|
39
|
+
the dev exports so they resolve on a minimal runtime without the source
|
|
40
|
+
packages installed alongside. This fixes a browser deploy bundle that could
|
|
41
|
+
fail to build or retain dev schemas, and web simulation that could not find
|
|
42
|
+
the dev exports.
|
|
36
43
|
- 9d066cc: The MCP now loads flows by ID, requires the `flow_simulate` `step`
|
|
37
44
|
parameter it always enforced, and adds a `diagnostics` tool reporting client
|
|
38
45
|
and CLI versions plus backend reachability. Package discovery returns a
|
|
@@ -57,10 +64,10 @@
|
|
|
57
64
|
- Updated dependencies [126c0f1]
|
|
58
65
|
- Updated dependencies [654ba38]
|
|
59
66
|
- Updated dependencies [3eb2467]
|
|
60
|
-
- @walkeros/core@4.2.0-next-
|
|
61
|
-
- @walkeros/collector@4.2.0-next-
|
|
62
|
-
- @walkeros/server-core@4.2.0-next-
|
|
63
|
-
- @walkeros/server-destination-api@4.2.0-next-
|
|
67
|
+
- @walkeros/core@4.2.0-next-1780577792479
|
|
68
|
+
- @walkeros/collector@4.2.0-next-1780577792479
|
|
69
|
+
- @walkeros/server-core@4.2.0-next-1780577792479
|
|
70
|
+
- @walkeros/server-destination-api@4.2.0-next-1780577792479
|
|
64
71
|
|
|
65
72
|
## 4.1.2
|
|
66
73
|
|
package/dist/cli.js
CHANGED
|
@@ -3742,10 +3742,13 @@ async function bundleCore(flowSettings, buildOptions, logger, showStats = false)
|
|
|
3742
3742
|
const { codeEntry, dataPayload, hasFlow, devPackages } = await createEntryPoint(flowSettings, buildOptions, packagePaths);
|
|
3743
3743
|
await fs11.ensureDir(path12.dirname(outputPath));
|
|
3744
3744
|
const codeKeyInputs = {
|
|
3745
|
-
//
|
|
3746
|
-
//
|
|
3745
|
+
// Deploy browser skeletons (externalizeDev) externalize each `<pkg>/dev`
|
|
3746
|
+
// so the lazy registry is not inlined; in-process simulate/push inline it.
|
|
3747
|
+
// Record the externals only when they are actually emitted, otherwise two
|
|
3748
|
+
// builds with identical entry code but different inline/external `/dev`
|
|
3749
|
+
// would alias the same L2 slot and one would receive the other's bytes.
|
|
3747
3750
|
externals: new Set(
|
|
3748
|
-
buildOptions.platform === "browser" ? devPackages.map((p2) => `${p2}/dev`) : []
|
|
3751
|
+
buildOptions.platform === "browser" && buildOptions.externalizeDev === true ? devPackages.map((p2) => `${p2}/dev`) : []
|
|
3749
3752
|
),
|
|
3750
3753
|
platform: buildOptions.platform === "node" ? "node" : "browser",
|
|
3751
3754
|
target: resolveTarget(buildOptions),
|
|
@@ -3972,7 +3975,7 @@ function createEsbuildOptions(buildOptions, entryPath, outputPath, tempDir, pack
|
|
|
3972
3975
|
"process.env.NODE_ENV": '"production"',
|
|
3973
3976
|
global: "globalThis"
|
|
3974
3977
|
};
|
|
3975
|
-
const devSubpathExternals = devPackages.map((p2) => `${p2}/dev`);
|
|
3978
|
+
const devSubpathExternals = buildOptions.externalizeDev === true ? devPackages.map((p2) => `${p2}/dev`) : [];
|
|
3976
3979
|
baseOptions.external = [
|
|
3977
3980
|
...buildOptions.external || [],
|
|
3978
3981
|
...devSubpathExternals
|
|
@@ -4638,6 +4641,7 @@ var init_targets = __esm({
|
|
|
4638
4641
|
cdn: Object.freeze({
|
|
4639
4642
|
skipWrapper: false,
|
|
4640
4643
|
withDev: false,
|
|
4644
|
+
externalizeDev: false,
|
|
4641
4645
|
platform: "browser",
|
|
4642
4646
|
injectEnv: true
|
|
4643
4647
|
}),
|
|
@@ -4651,24 +4655,28 @@ var init_targets = __esm({
|
|
|
4651
4655
|
"cdn-skeleton": Object.freeze({
|
|
4652
4656
|
skipWrapper: true,
|
|
4653
4657
|
withDev: true,
|
|
4658
|
+
externalizeDev: true,
|
|
4654
4659
|
platform: "browser",
|
|
4655
4660
|
injectEnv: false
|
|
4656
4661
|
}),
|
|
4657
4662
|
runner: Object.freeze({
|
|
4658
4663
|
skipWrapper: true,
|
|
4659
4664
|
withDev: true,
|
|
4665
|
+
externalizeDev: true,
|
|
4660
4666
|
platform: "node",
|
|
4661
4667
|
injectEnv: false
|
|
4662
4668
|
}),
|
|
4663
4669
|
simulate: Object.freeze({
|
|
4664
4670
|
skipWrapper: true,
|
|
4665
4671
|
withDev: true,
|
|
4672
|
+
externalizeDev: false,
|
|
4666
4673
|
platform: "node",
|
|
4667
4674
|
injectEnv: false
|
|
4668
4675
|
}),
|
|
4669
4676
|
push: Object.freeze({
|
|
4670
4677
|
skipWrapper: true,
|
|
4671
4678
|
withDev: true,
|
|
4679
|
+
externalizeDev: false,
|
|
4672
4680
|
platform: "node",
|
|
4673
4681
|
injectEnv: false
|
|
4674
4682
|
})
|
|
@@ -4987,7 +4995,8 @@ async function bundle(configOrPath, options = {}) {
|
|
|
4987
4995
|
const mergedOverrides = {
|
|
4988
4996
|
...options.buildOverrides ?? {},
|
|
4989
4997
|
skipWrapper: preset.skipWrapper,
|
|
4990
|
-
withDev: preset.withDev
|
|
4998
|
+
withDev: preset.withDev,
|
|
4999
|
+
externalizeDev: preset.externalizeDev
|
|
4991
5000
|
};
|
|
4992
5001
|
const { flowSettings, buildOptions } = loadBundleConfig(rawConfig, {
|
|
4993
5002
|
configPath,
|
|
@@ -6725,7 +6734,7 @@ async function Pt2(e4, t4 = {}) {
|
|
|
6725
6734
|
}
|
|
6726
6735
|
async function zt2(e4) {
|
|
6727
6736
|
const t4 = ne({ globalsStatic: {}, sessionStatic: {}, run: true, queueMax: 1e3 }, e4, { merge: false, extend: false }), n4 = { level: e4.logger?.level, handler: e4.logger?.handler }, o3 = Me(n4), s5 = { ...t4.globalsStatic, ...e4.globals }, i3 = { allowed: false, config: t4, consent: e4.consent || {}, custom: e4.custom || {}, destinations: {}, transformers: {}, stores: {}, globals: s5, hooks: e4.hooks || {}, observers: /* @__PURE__ */ new Set(), logger: o3, on: {}, queue: [], round: 0, stateVersion: 0, cellVersion: {}, delivery: /* @__PURE__ */ new WeakMap(), session: void 0, status: { startedAt: Date.now(), in: 0, out: 0, failed: 0, sources: {}, destinations: {}, dropped: {} }, timing: Date.now(), user: e4.user || {}, sources: {}, pending: { destinations: {} }, hasShutdown: false, seenEvents: /* @__PURE__ */ new Set(), push: void 0, command: void 0 };
|
|
6728
|
-
i3.push = St2(i3, (e5) => ({ timing: Math.round((Date.now() - i3.timing) / 10) / 100, source: { type: "collector", schema: "4", version: "4.2.0-next-
|
|
6737
|
+
i3.push = St2(i3, (e5) => ({ timing: Math.round((Date.now() - i3.timing) / 10) / 100, source: { type: "collector", schema: "4", version: "4.2.0-next-1780577792479" }, ...e5 })), i3.command = (function(e5, t5) {
|
|
6729
6738
|
return at(async (n5, o4, s6) => await Be(async () => await t5(e5, n5, o4, s6), (t6) => {
|
|
6730
6739
|
if (t6 instanceof We) throw t6;
|
|
6731
6740
|
return e5.status.failed++, e5.logger.error("command failed", { command: n5, data: o4, error: t6 }), nt2({ ok: false });
|
|
@@ -10433,7 +10442,7 @@ function validateMapping(input) {
|
|
|
10433
10442
|
// src/commands/validate/validators/entry.ts
|
|
10434
10443
|
init_dist();
|
|
10435
10444
|
import Ajv from "ajv";
|
|
10436
|
-
var CLIENT_HEADER = "walkeros-cli/4.2.0-next-
|
|
10445
|
+
var CLIENT_HEADER = "walkeros-cli/4.2.0-next-1780577792479";
|
|
10437
10446
|
var SECTIONS = ["destinations", "sources", "transformers"];
|
|
10438
10447
|
function resolveEntry(path19, flowConfig) {
|
|
10439
10448
|
const flows = flowConfig.flows;
|
package/dist/index.d.ts
CHANGED
|
@@ -130,6 +130,19 @@ interface BuildOptions extends CLIBuildOptions {
|
|
|
130
130
|
* @internal
|
|
131
131
|
*/
|
|
132
132
|
withDev?: boolean;
|
|
133
|
+
/**
|
|
134
|
+
* Gates browser `<pkg>/dev` externalization. Derived from the resolved
|
|
135
|
+
* `BundleTarget` preset by `bundle()`.
|
|
136
|
+
*
|
|
137
|
+
* When `true` (deploy skeletons), each `<pkg>/dev` is externalized so the lazy
|
|
138
|
+
* registry stays a literal `import('<pkg>/dev')` and the deploy wrap DCEs the
|
|
139
|
+
* /dev graph to zero bytes. When `false`/undefined (in-process simulate/push),
|
|
140
|
+
* `<pkg>/dev` is inlined so the lazy thunk resolves an already-bundled module
|
|
141
|
+
* with no host node_modules lookup. Node platform ignores this flag (it always
|
|
142
|
+
* externalizes step packages, which prefix-covers `<pkg>/dev`).
|
|
143
|
+
* @internal
|
|
144
|
+
*/
|
|
145
|
+
externalizeDev?: boolean;
|
|
133
146
|
/**
|
|
134
147
|
* Folders to include in the output directory.
|
|
135
148
|
* These folders are copied alongside the bundle for runtime access.
|
package/dist/index.js
CHANGED
|
@@ -2191,10 +2191,13 @@ async function bundleCore(flowSettings, buildOptions, logger, showStats = false)
|
|
|
2191
2191
|
const { codeEntry, dataPayload, hasFlow, devPackages } = await createEntryPoint(flowSettings, buildOptions, packagePaths);
|
|
2192
2192
|
await fs11.ensureDir(path12.dirname(outputPath));
|
|
2193
2193
|
const codeKeyInputs = {
|
|
2194
|
-
//
|
|
2195
|
-
//
|
|
2194
|
+
// Deploy browser skeletons (externalizeDev) externalize each `<pkg>/dev`
|
|
2195
|
+
// so the lazy registry is not inlined; in-process simulate/push inline it.
|
|
2196
|
+
// Record the externals only when they are actually emitted, otherwise two
|
|
2197
|
+
// builds with identical entry code but different inline/external `/dev`
|
|
2198
|
+
// would alias the same L2 slot and one would receive the other's bytes.
|
|
2196
2199
|
externals: new Set(
|
|
2197
|
-
buildOptions.platform === "browser" ? devPackages.map((p) => `${p}/dev`) : []
|
|
2200
|
+
buildOptions.platform === "browser" && buildOptions.externalizeDev === true ? devPackages.map((p) => `${p}/dev`) : []
|
|
2198
2201
|
),
|
|
2199
2202
|
platform: buildOptions.platform === "node" ? "node" : "browser",
|
|
2200
2203
|
target: resolveTarget(buildOptions),
|
|
@@ -2421,7 +2424,7 @@ function createEsbuildOptions(buildOptions, entryPath, outputPath, tempDir, pack
|
|
|
2421
2424
|
"process.env.NODE_ENV": '"production"',
|
|
2422
2425
|
global: "globalThis"
|
|
2423
2426
|
};
|
|
2424
|
-
const devSubpathExternals = devPackages.map((p) => `${p}/dev`);
|
|
2427
|
+
const devSubpathExternals = buildOptions.externalizeDev === true ? devPackages.map((p) => `${p}/dev`) : [];
|
|
2425
2428
|
baseOptions.external = [
|
|
2426
2429
|
...buildOptions.external || [],
|
|
2427
2430
|
...devSubpathExternals
|
|
@@ -3279,6 +3282,7 @@ var init_targets = __esm({
|
|
|
3279
3282
|
cdn: Object.freeze({
|
|
3280
3283
|
skipWrapper: false,
|
|
3281
3284
|
withDev: false,
|
|
3285
|
+
externalizeDev: false,
|
|
3282
3286
|
platform: "browser",
|
|
3283
3287
|
injectEnv: true
|
|
3284
3288
|
}),
|
|
@@ -3292,24 +3296,28 @@ var init_targets = __esm({
|
|
|
3292
3296
|
"cdn-skeleton": Object.freeze({
|
|
3293
3297
|
skipWrapper: true,
|
|
3294
3298
|
withDev: true,
|
|
3299
|
+
externalizeDev: true,
|
|
3295
3300
|
platform: "browser",
|
|
3296
3301
|
injectEnv: false
|
|
3297
3302
|
}),
|
|
3298
3303
|
runner: Object.freeze({
|
|
3299
3304
|
skipWrapper: true,
|
|
3300
3305
|
withDev: true,
|
|
3306
|
+
externalizeDev: true,
|
|
3301
3307
|
platform: "node",
|
|
3302
3308
|
injectEnv: false
|
|
3303
3309
|
}),
|
|
3304
3310
|
simulate: Object.freeze({
|
|
3305
3311
|
skipWrapper: true,
|
|
3306
3312
|
withDev: true,
|
|
3313
|
+
externalizeDev: false,
|
|
3307
3314
|
platform: "node",
|
|
3308
3315
|
injectEnv: false
|
|
3309
3316
|
}),
|
|
3310
3317
|
push: Object.freeze({
|
|
3311
3318
|
skipWrapper: true,
|
|
3312
3319
|
withDev: true,
|
|
3320
|
+
externalizeDev: false,
|
|
3313
3321
|
platform: "node",
|
|
3314
3322
|
injectEnv: false
|
|
3315
3323
|
})
|
|
@@ -3628,7 +3636,8 @@ async function bundle(configOrPath, options = {}) {
|
|
|
3628
3636
|
const mergedOverrides = {
|
|
3629
3637
|
...options.buildOverrides ?? {},
|
|
3630
3638
|
skipWrapper: preset.skipWrapper,
|
|
3631
|
-
withDev: preset.withDev
|
|
3639
|
+
withDev: preset.withDev,
|
|
3640
|
+
externalizeDev: preset.externalizeDev
|
|
3632
3641
|
};
|
|
3633
3642
|
const { flowSettings, buildOptions } = loadBundleConfig(rawConfig, {
|
|
3634
3643
|
configPath,
|
|
@@ -6974,7 +6983,7 @@ function validateMapping(input) {
|
|
|
6974
6983
|
// src/commands/validate/validators/entry.ts
|
|
6975
6984
|
import Ajv from "ajv";
|
|
6976
6985
|
import { fetchPackageSchema } from "@walkeros/core";
|
|
6977
|
-
var CLIENT_HEADER = "walkeros-cli/4.2.0-next-
|
|
6986
|
+
var CLIENT_HEADER = "walkeros-cli/4.2.0-next-1780577792479";
|
|
6978
6987
|
var SECTIONS = ["destinations", "sources", "transformers"];
|
|
6979
6988
|
function resolveEntry(path20, flowConfig) {
|
|
6980
6989
|
const flows = flowConfig.flows;
|
|
@@ -8618,6 +8627,15 @@ import * as os3 from "os";
|
|
|
8618
8627
|
import { fileURLToPath as fileURLToPath2 } from "url";
|
|
8619
8628
|
import fs18 from "fs-extra";
|
|
8620
8629
|
import * as esbuild2 from "esbuild";
|
|
8630
|
+
function extractDevExternals(skeletonText) {
|
|
8631
|
+
const pattern = /import\(\s*['"]([^'"]+\/dev)['"]\s*\)/g;
|
|
8632
|
+
const found = /* @__PURE__ */ new Set();
|
|
8633
|
+
let match;
|
|
8634
|
+
while ((match = pattern.exec(skeletonText)) !== null) {
|
|
8635
|
+
found.add(match[1]);
|
|
8636
|
+
}
|
|
8637
|
+
return Array.from(found);
|
|
8638
|
+
}
|
|
8621
8639
|
function getNodeResolutionPaths() {
|
|
8622
8640
|
const here = path19.dirname(fileURLToPath2(import.meta.url));
|
|
8623
8641
|
const candidates = [];
|
|
@@ -8656,6 +8674,8 @@ async function wrapSkeleton(options) {
|
|
|
8656
8674
|
throw new Error(`wrapSkeleton: skeleton not found at ${skeletonPath}`);
|
|
8657
8675
|
}
|
|
8658
8676
|
const absoluteSkeletonPath = path19.resolve(skeletonPath);
|
|
8677
|
+
const skeletonText = await fs18.readFile(absoluteSkeletonPath, "utf-8");
|
|
8678
|
+
const devExternals = extractDevExternals(skeletonText);
|
|
8659
8679
|
const tInput = options.telemetry;
|
|
8660
8680
|
const tLevel = tInput?.level ?? "standard";
|
|
8661
8681
|
const telemetry = tInput ? {
|
|
@@ -8707,6 +8727,7 @@ async function wrapSkeleton(options) {
|
|
|
8707
8727
|
"process.env.NODE_ENV": '"production"',
|
|
8708
8728
|
global: "globalThis"
|
|
8709
8729
|
};
|
|
8730
|
+
esbuildOptions.external = devExternals;
|
|
8710
8731
|
esbuildOptions.target = target ?? "es2018";
|
|
8711
8732
|
} else {
|
|
8712
8733
|
esbuildOptions.external = getNodeExternals();
|