deepline 0.1.255 → 0.1.257

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.
@@ -123,7 +123,7 @@ export const SDK_RELEASE = {
123
123
  // Deepline-native radars. Older clients must update before discovering,
124
124
  // checking, or deploying an unlaunched monitor integration.
125
125
  // 0.1.253 makes play-page browser opening opt-in and retires --no-open.
126
- version: '0.1.255',
126
+ version: '0.1.257',
127
127
  apiContract: '2026-07-native-monitor-launch-hard-cutover',
128
128
  supportPolicy: {
129
129
  minimumSupported: '0.1.53',
@@ -131,9 +131,12 @@ export const SDK_RELEASE = {
131
131
  commandMinimumSupported: [
132
132
  {
133
133
  command: 'enrich',
134
- minimumSupported: '0.1.253',
134
+ // Compatibility window through 2026-08-22 (owner: Chirag): versions
135
+ // 0.1.238-0.1.252 differ only in local browser-opening behavior and
136
+ // already contain the enrich data-correctness fixes below.
137
+ minimumSupported: '0.1.238',
135
138
  reason:
136
- 'Older SDK CLI enrich generated stale play source; SDK CLI enrich 0.1.153 generated removed StepOptions fields in play source; SDK CLI enrich before 0.1.175 could silently succeed on the empty-waterfall bug when a requested waterfall returned no values for selected rows; SDK CLI enrich before 0.1.230 could convert extractor failures into successful unmatched results; SDK CLI enrich before 0.1.238 could drop a nested provider email match during generic pick("email") extraction and materialize it as NO_MATCH; SDK CLI enrich before 0.1.253 opens the generated play page by default and accepts the removed --no-open flag.',
139
+ 'Older SDK CLI enrich generated stale play source; SDK CLI enrich 0.1.153 generated removed StepOptions fields in play source; SDK CLI enrich before 0.1.175 could silently succeed on the empty-waterfall bug when a requested waterfall returned no values for selected rows; SDK CLI enrich before 0.1.230 could convert extractor failures into successful unmatched results; SDK CLI enrich before 0.1.238 could drop a nested provider email match during generic pick("email") extraction and materialize it as NO_MATCH.',
137
140
  },
138
141
  {
139
142
  command: 'plays',
@@ -138,7 +138,6 @@ export interface PlayStaticColumnProducer {
138
138
  field: string;
139
139
  toolId?: string;
140
140
  playId?: string;
141
- dependsOnFields?: string[];
142
141
  conditional?: boolean;
143
142
  sourceRange?: PlayStaticSourceRange;
144
143
  steps?: PlayStaticColumnProducer[];
@@ -396,16 +395,10 @@ function truncateStaticSubstepsForStorage(
396
395
  ...column,
397
396
  producers: column.producers.map((producer) => ({
398
397
  ...omitUndefinedProperties({ ...producer }),
399
- dependsOnFields: producer.dependsOnFields
400
- ? [...producer.dependsOnFields]
401
- : undefined,
402
398
  sourceRange: cloneStorageSafeSourceRange(producer.sourceRange),
403
399
  steps: producer.steps
404
400
  ? producer.steps.map((stepProducer) => ({
405
401
  ...omitUndefinedProperties({ ...stepProducer }),
406
- dependsOnFields: stepProducer.dependsOnFields
407
- ? [...stepProducer.dependsOnFields]
408
- : undefined,
409
402
  sourceRange: cloneStorageSafeSourceRange(
410
403
  stepProducer.sourceRange,
411
404
  ),
@@ -564,7 +557,6 @@ export interface PlayStaticSourceRange {
564
557
  type PlayStaticSubstepMetadata = {
565
558
  conditional?: boolean;
566
559
  disabled?: boolean;
567
- dependsOnFields?: string[];
568
560
  };
569
561
 
570
562
  /**
@@ -958,9 +950,6 @@ function columnProducerFromSubstep(
958
950
  field,
959
951
  ...(substep.type === 'tool' ? { toolId: substep.toolId } : {}),
960
952
  ...(substep.type === 'play_call' ? { playId: substep.playId } : {}),
961
- ...(substep.dependsOnFields?.length
962
- ? { dependsOnFields: [...substep.dependsOnFields] }
963
- : {}),
964
953
  ...(substep.conditional ? { conditional: true } : {}),
965
954
  ...(substep.disabled ? { disabled: true } : {}),
966
955
  ...(substep.sourceRange ? { sourceRange: substep.sourceRange } : {}),
package/dist/cli/index.js CHANGED
@@ -636,7 +636,7 @@ var SDK_RELEASE = {
636
636
  // Deepline-native radars. Older clients must update before discovering,
637
637
  // checking, or deploying an unlaunched monitor integration.
638
638
  // 0.1.253 makes play-page browser opening opt-in and retires --no-open.
639
- version: "0.1.255",
639
+ version: "0.1.257",
640
640
  apiContract: "2026-07-native-monitor-launch-hard-cutover",
641
641
  supportPolicy: {
642
642
  minimumSupported: "0.1.53",
@@ -644,8 +644,11 @@ var SDK_RELEASE = {
644
644
  commandMinimumSupported: [
645
645
  {
646
646
  command: "enrich",
647
- minimumSupported: "0.1.253",
648
- reason: 'Older SDK CLI enrich generated stale play source; SDK CLI enrich 0.1.153 generated removed StepOptions fields in play source; SDK CLI enrich before 0.1.175 could silently succeed on the empty-waterfall bug when a requested waterfall returned no values for selected rows; SDK CLI enrich before 0.1.230 could convert extractor failures into successful unmatched results; SDK CLI enrich before 0.1.238 could drop a nested provider email match during generic pick("email") extraction and materialize it as NO_MATCH; SDK CLI enrich before 0.1.253 opens the generated play page by default and accepts the removed --no-open flag.'
647
+ // Compatibility window through 2026-08-22 (owner: Chirag): versions
648
+ // 0.1.238-0.1.252 differ only in local browser-opening behavior and
649
+ // already contain the enrich data-correctness fixes below.
650
+ minimumSupported: "0.1.238",
651
+ reason: 'Older SDK CLI enrich generated stale play source; SDK CLI enrich 0.1.153 generated removed StepOptions fields in play source; SDK CLI enrich before 0.1.175 could silently succeed on the empty-waterfall bug when a requested waterfall returned no values for selected rows; SDK CLI enrich before 0.1.230 could convert extractor failures into successful unmatched results; SDK CLI enrich before 0.1.238 could drop a nested provider email match during generic pick("email") extraction and materialize it as NO_MATCH.'
649
652
  },
650
653
  {
651
654
  command: "plays",
@@ -18698,10 +18701,11 @@ function compileEnrichConfigToPlaySource(config, options = {}) {
18698
18701
  `}, { description: ${stringLiteral("Read a CSV file, run the configured Deepline enrich commands, and return enriched rows.")} });`
18699
18702
  ];
18700
18703
  const helpers = idiomaticGetters ? selectUsedHelpers(helperSource(), body.join("\n")) : helperSource();
18704
+ const typeImports = idiomaticGetters ? inlineTypeImports : [.../* @__PURE__ */ new Set([...inlineTypeImports, "DeeplinePlayRuntimeContext"])].sort();
18701
18705
  return [
18702
18706
  ...inlineRunJavascript && configHasRunJavascript(config) ? ["// @ts-nocheck", "/* eslint-disable */", ""] : [],
18703
18707
  `import { definePlay, steps } from 'deepline';`,
18704
- ...inlineTypeImports.length > 0 ? [`import type { ${inlineTypeImports.join(", ")} } from 'deepline';`] : [],
18708
+ ...typeImports.length > 0 ? [`import type { ${typeImports.join(", ")} } from 'deepline';`] : [],
18705
18709
  ``,
18706
18710
  `type EnrichInput = { file: string; rowStart?: number | null; rowEnd?: number | null };`,
18707
18711
  ``,
@@ -19451,7 +19455,7 @@ function helperSource() {
19451
19455
  ` return result;`,
19452
19456
  `}`,
19453
19457
  ``,
19454
- `async function __dlRunCommand(input: { alias: string; callId: string; tool: string; payload: Record<string, unknown>; extract: ((args: __DlExtractorHelpers) => unknown) | null; runIf: ((row: Record<string, unknown>) => unknown) | null; row: Record<string, unknown>; stepCtx: { tools: { execute: (request: Record<string, unknown>) => Promise<unknown> } }; description?: string; force?: boolean; legacyEnvelope?: boolean }): Promise<unknown> {`,
19458
+ `async function __dlRunCommand(input: { alias: string; callId: string; tool: string; payload: Record<string, unknown>; extract: ((args: __DlExtractorHelpers) => unknown) | null; runIf: ((row: Record<string, unknown>) => unknown) | null; row: Record<string, unknown>; stepCtx: Pick<DeeplinePlayRuntimeContext, 'tools'>; description?: string; force?: boolean; legacyEnvelope?: boolean }): Promise<unknown> {`,
19455
19459
  ` if (input.runIf) {`,
19456
19460
  ` const shouldRun = input.runIf(input.row);`,
19457
19461
  ` if (!shouldRun) return null;`,
@@ -29182,6 +29186,13 @@ function sidecarRegistryUrl(hostUrl) {
29182
29186
  }
29183
29187
  return new URL("/api/v2/npm/", url).toString();
29184
29188
  }
29189
+ function publicNpmFallbackRegistryUrl(hostUrl) {
29190
+ try {
29191
+ return sidecarRegistryUrl(hostUrl);
29192
+ } catch {
29193
+ return void 0;
29194
+ }
29195
+ }
29185
29196
  function readOptionalText(path) {
29186
29197
  try {
29187
29198
  return (0, import_node_fs17.readFileSync)(path, "utf8").trim();
@@ -29294,6 +29305,9 @@ function resolveUpdatePlan(options = {}) {
29294
29305
  command,
29295
29306
  args,
29296
29307
  ...installPrefix ? { installPrefix } : {},
29308
+ fallbackRegistryUrl: publicNpmFallbackRegistryUrl(
29309
+ env.DEEPLINE_HOST_URL?.trim() || autoDetectBaseUrl()
29310
+ ),
29297
29311
  manualCommand: `${command} ${args.map(shellQuote6).join(" ")}`
29298
29312
  };
29299
29313
  }
@@ -29380,7 +29394,7 @@ async function runAutomaticUpdatePlan(plan) {
29380
29394
  previousFailure
29381
29395
  };
29382
29396
  }
29383
- const exitCode = await runUpdatePlan(plan, { stdio: "stderr" });
29397
+ const exitCode = await runUpdatePlan(plan);
29384
29398
  return exitCode === 0 ? { status: "updated", exitCode: 0 } : { status: "failed", exitCode };
29385
29399
  }
29386
29400
  function safeVersionSegment(value) {
@@ -29411,31 +29425,75 @@ function installedPackageVersion(versionDir) {
29411
29425
  return "";
29412
29426
  }
29413
29427
  }
29414
- function runCommand(command, args, env = process.env, options = {}) {
29415
- return new Promise((resolveExitCode) => {
29428
+ function runCommand(command, args, env = process.env) {
29429
+ return new Promise((resolveResult) => {
29430
+ let output2 = "";
29416
29431
  const child = (0, import_node_child_process4.spawn)(command, args, {
29417
- stdio: options.stdio === "stderr" ? ["inherit", "pipe", "pipe"] : "inherit",
29432
+ stdio: ["inherit", "pipe", "pipe"],
29418
29433
  shell: process.platform === "win32",
29419
29434
  env
29420
29435
  });
29421
- if (options.stdio === "stderr") {
29422
- child.stdout?.on("data", (chunk) => {
29423
- process.stderr.write(chunk);
29424
- });
29425
- child.stderr?.on("data", (chunk) => {
29426
- process.stderr.write(chunk);
29427
- });
29428
- }
29436
+ child.stdout?.on("data", (chunk) => {
29437
+ output2 += chunk.toString();
29438
+ process.stderr.write(chunk);
29439
+ });
29440
+ child.stderr?.on("data", (chunk) => {
29441
+ output2 += chunk.toString();
29442
+ process.stderr.write(chunk);
29443
+ });
29429
29444
  child.on("error", (error) => {
29430
29445
  process.stderr.write(`Failed to start ${command}: ${error.message}
29431
29446
  `);
29432
- resolveExitCode(1);
29447
+ resolveResult({ exitCode: 1, output: `${output2}
29448
+ ${error.message}` });
29433
29449
  });
29434
29450
  child.on("close", (code) => {
29435
- resolveExitCode(code ?? 1);
29451
+ resolveResult({ exitCode: code ?? 1, output: output2 });
29436
29452
  });
29437
29453
  });
29438
29454
  }
29455
+ var DEFAULT_NPM_REGISTRY_URL = "https://registry.npmjs.org/";
29456
+ function isRegistryAccessFailure(output2, registryUrl) {
29457
+ let registryHost = "";
29458
+ try {
29459
+ registryHost = new URL(registryUrl).hostname;
29460
+ } catch {
29461
+ return false;
29462
+ }
29463
+ if (!registryHost || !output2.toLowerCase().includes(registryHost.toLowerCase())) {
29464
+ return false;
29465
+ }
29466
+ return /\b(?:EAI_AGAIN|ECONNREFUSED|ECONNRESET|ENETUNREACH|ENOTFOUND|EHOSTUNREACH|ETIMEDOUT|E5\d\d)\b|\b5\d\d\b|access denied|blocked|forbidden|network (?:error|timeout)|request .* failed/iu.test(
29467
+ output2
29468
+ );
29469
+ }
29470
+ function withRegistry(args, registryUrl) {
29471
+ return [...args.slice(0, -1), "--registry", registryUrl, args.at(-1) ?? ""];
29472
+ }
29473
+ async function runNpmInstallWithRegistryFallback(input2) {
29474
+ const primaryArgs = input2.primaryRegistryUrl ? withRegistry(input2.installArgs, input2.primaryRegistryUrl) : input2.installArgs;
29475
+ const first = await runCommand(
29476
+ input2.npmCommand,
29477
+ primaryArgs,
29478
+ input2.env ?? process.env
29479
+ );
29480
+ if (first.exitCode === 0 || !input2.fallbackRegistryUrl || !isRegistryAccessFailure(
29481
+ first.output,
29482
+ input2.primaryRegistryUrl ?? DEFAULT_NPM_REGISTRY_URL
29483
+ )) {
29484
+ return first.exitCode;
29485
+ }
29486
+ process.stderr.write(
29487
+ `Primary npm registry access failed; retrying through Deepline's registry: ${input2.fallbackRegistryUrl}
29488
+ `
29489
+ );
29490
+ const fallback = await runCommand(
29491
+ input2.npmCommand,
29492
+ withRegistry(input2.installArgs, input2.fallbackRegistryUrl),
29493
+ input2.env ?? process.env
29494
+ );
29495
+ return fallback.exitCode;
29496
+ }
29439
29497
  function writeSidecarLauncher(input2) {
29440
29498
  (0, import_node_fs17.mkdirSync)((0, import_node_path19.dirname)(input2.path), { recursive: true });
29441
29499
  if (process.platform === "win32") {
@@ -29463,7 +29521,7 @@ function writeSidecarLauncher(input2) {
29463
29521
  { encoding: "utf8", mode: 493 }
29464
29522
  );
29465
29523
  }
29466
- async function runPythonSidecarUpdatePlan(plan, options = {}) {
29524
+ async function runPythonSidecarUpdatePlan(plan) {
29467
29525
  const versionsDir = (0, import_node_path19.join)(plan.stateDir, "versions");
29468
29526
  const tempDir = (0, import_node_path19.join)(
29469
29527
  versionsDir,
@@ -29476,7 +29534,7 @@ async function runPythonSidecarUpdatePlan(plan, options = {}) {
29476
29534
  ...process.env,
29477
29535
  PATH: `${(0, import_node_path19.dirname)(plan.nodeBin)}${process.platform === "win32" ? ";" : ":"}${process.env.PATH ?? ""}`
29478
29536
  };
29479
- const installExitCode = await runCommand(
29537
+ const installResult = await runCommand(
29480
29538
  plan.npmCommand,
29481
29539
  [
29482
29540
  "install",
@@ -29487,9 +29545,9 @@ async function runPythonSidecarUpdatePlan(plan, options = {}) {
29487
29545
  ...NPM_SDK_INSTALL_COMMON_FLAGS,
29488
29546
  plan.packageSpec
29489
29547
  ],
29490
- env,
29491
- options
29548
+ env
29492
29549
  );
29550
+ const installExitCode = installResult.exitCode;
29493
29551
  if (installExitCode !== 0) {
29494
29552
  (0, import_node_fs17.rmSync)(tempDir, { recursive: true, force: true });
29495
29553
  return installExitCode;
@@ -29561,12 +29619,17 @@ async function runPythonSidecarUpdatePlan(plan, options = {}) {
29561
29619
  );
29562
29620
  return 0;
29563
29621
  }
29564
- async function runUpdatePlan(plan, options = {}) {
29622
+ async function runUpdatePlan(plan) {
29565
29623
  let exitCode = 1;
29566
29624
  if (plan.kind === "npm-global") {
29567
- exitCode = await runCommand(plan.command, plan.args, process.env, options);
29625
+ exitCode = await runNpmInstallWithRegistryFallback({
29626
+ npmCommand: plan.command,
29627
+ installArgs: plan.args,
29628
+ primaryRegistryUrl: plan.primaryRegistryUrl,
29629
+ fallbackRegistryUrl: plan.fallbackRegistryUrl
29630
+ });
29568
29631
  } else if (plan.kind === "python-sidecar") {
29569
- exitCode = await runPythonSidecarUpdatePlan(plan, options);
29632
+ exitCode = await runPythonSidecarUpdatePlan(plan);
29570
29633
  }
29571
29634
  if (exitCode === 0) {
29572
29635
  clearAutoUpdateFailure(plan);
@@ -621,7 +621,7 @@ var SDK_RELEASE = {
621
621
  // Deepline-native radars. Older clients must update before discovering,
622
622
  // checking, or deploying an unlaunched monitor integration.
623
623
  // 0.1.253 makes play-page browser opening opt-in and retires --no-open.
624
- version: "0.1.255",
624
+ version: "0.1.257",
625
625
  apiContract: "2026-07-native-monitor-launch-hard-cutover",
626
626
  supportPolicy: {
627
627
  minimumSupported: "0.1.53",
@@ -629,8 +629,11 @@ var SDK_RELEASE = {
629
629
  commandMinimumSupported: [
630
630
  {
631
631
  command: "enrich",
632
- minimumSupported: "0.1.253",
633
- reason: 'Older SDK CLI enrich generated stale play source; SDK CLI enrich 0.1.153 generated removed StepOptions fields in play source; SDK CLI enrich before 0.1.175 could silently succeed on the empty-waterfall bug when a requested waterfall returned no values for selected rows; SDK CLI enrich before 0.1.230 could convert extractor failures into successful unmatched results; SDK CLI enrich before 0.1.238 could drop a nested provider email match during generic pick("email") extraction and materialize it as NO_MATCH; SDK CLI enrich before 0.1.253 opens the generated play page by default and accepts the removed --no-open flag.'
632
+ // Compatibility window through 2026-08-22 (owner: Chirag): versions
633
+ // 0.1.238-0.1.252 differ only in local browser-opening behavior and
634
+ // already contain the enrich data-correctness fixes below.
635
+ minimumSupported: "0.1.238",
636
+ reason: 'Older SDK CLI enrich generated stale play source; SDK CLI enrich 0.1.153 generated removed StepOptions fields in play source; SDK CLI enrich before 0.1.175 could silently succeed on the empty-waterfall bug when a requested waterfall returned no values for selected rows; SDK CLI enrich before 0.1.230 could convert extractor failures into successful unmatched results; SDK CLI enrich before 0.1.238 could drop a nested provider email match during generic pick("email") extraction and materialize it as NO_MATCH.'
634
637
  },
635
638
  {
636
639
  command: "plays",
@@ -18727,10 +18730,11 @@ function compileEnrichConfigToPlaySource(config, options = {}) {
18727
18730
  `}, { description: ${stringLiteral("Read a CSV file, run the configured Deepline enrich commands, and return enriched rows.")} });`
18728
18731
  ];
18729
18732
  const helpers = idiomaticGetters ? selectUsedHelpers(helperSource(), body.join("\n")) : helperSource();
18733
+ const typeImports = idiomaticGetters ? inlineTypeImports : [.../* @__PURE__ */ new Set([...inlineTypeImports, "DeeplinePlayRuntimeContext"])].sort();
18730
18734
  return [
18731
18735
  ...inlineRunJavascript && configHasRunJavascript(config) ? ["// @ts-nocheck", "/* eslint-disable */", ""] : [],
18732
18736
  `import { definePlay, steps } from 'deepline';`,
18733
- ...inlineTypeImports.length > 0 ? [`import type { ${inlineTypeImports.join(", ")} } from 'deepline';`] : [],
18737
+ ...typeImports.length > 0 ? [`import type { ${typeImports.join(", ")} } from 'deepline';`] : [],
18734
18738
  ``,
18735
18739
  `type EnrichInput = { file: string; rowStart?: number | null; rowEnd?: number | null };`,
18736
18740
  ``,
@@ -19480,7 +19484,7 @@ function helperSource() {
19480
19484
  ` return result;`,
19481
19485
  `}`,
19482
19486
  ``,
19483
- `async function __dlRunCommand(input: { alias: string; callId: string; tool: string; payload: Record<string, unknown>; extract: ((args: __DlExtractorHelpers) => unknown) | null; runIf: ((row: Record<string, unknown>) => unknown) | null; row: Record<string, unknown>; stepCtx: { tools: { execute: (request: Record<string, unknown>) => Promise<unknown> } }; description?: string; force?: boolean; legacyEnvelope?: boolean }): Promise<unknown> {`,
19487
+ `async function __dlRunCommand(input: { alias: string; callId: string; tool: string; payload: Record<string, unknown>; extract: ((args: __DlExtractorHelpers) => unknown) | null; runIf: ((row: Record<string, unknown>) => unknown) | null; row: Record<string, unknown>; stepCtx: Pick<DeeplinePlayRuntimeContext, 'tools'>; description?: string; force?: boolean; legacyEnvelope?: boolean }): Promise<unknown> {`,
19484
19488
  ` if (input.runIf) {`,
19485
19489
  ` const shouldRun = input.runIf(input.row);`,
19486
19490
  ` if (!shouldRun) return null;`,
@@ -29245,6 +29249,13 @@ function sidecarRegistryUrl(hostUrl) {
29245
29249
  }
29246
29250
  return new URL("/api/v2/npm/", url).toString();
29247
29251
  }
29252
+ function publicNpmFallbackRegistryUrl(hostUrl) {
29253
+ try {
29254
+ return sidecarRegistryUrl(hostUrl);
29255
+ } catch {
29256
+ return void 0;
29257
+ }
29258
+ }
29248
29259
  function readOptionalText(path) {
29249
29260
  try {
29250
29261
  return readFileSync13(path, "utf8").trim();
@@ -29357,6 +29368,9 @@ function resolveUpdatePlan(options = {}) {
29357
29368
  command,
29358
29369
  args,
29359
29370
  ...installPrefix ? { installPrefix } : {},
29371
+ fallbackRegistryUrl: publicNpmFallbackRegistryUrl(
29372
+ env.DEEPLINE_HOST_URL?.trim() || autoDetectBaseUrl()
29373
+ ),
29360
29374
  manualCommand: `${command} ${args.map(shellQuote6).join(" ")}`
29361
29375
  };
29362
29376
  }
@@ -29443,7 +29457,7 @@ async function runAutomaticUpdatePlan(plan) {
29443
29457
  previousFailure
29444
29458
  };
29445
29459
  }
29446
- const exitCode = await runUpdatePlan(plan, { stdio: "stderr" });
29460
+ const exitCode = await runUpdatePlan(plan);
29447
29461
  return exitCode === 0 ? { status: "updated", exitCode: 0 } : { status: "failed", exitCode };
29448
29462
  }
29449
29463
  function safeVersionSegment(value) {
@@ -29474,31 +29488,75 @@ function installedPackageVersion(versionDir) {
29474
29488
  return "";
29475
29489
  }
29476
29490
  }
29477
- function runCommand(command, args, env = process.env, options = {}) {
29478
- return new Promise((resolveExitCode) => {
29491
+ function runCommand(command, args, env = process.env) {
29492
+ return new Promise((resolveResult) => {
29493
+ let output2 = "";
29479
29494
  const child = spawn4(command, args, {
29480
- stdio: options.stdio === "stderr" ? ["inherit", "pipe", "pipe"] : "inherit",
29495
+ stdio: ["inherit", "pipe", "pipe"],
29481
29496
  shell: process.platform === "win32",
29482
29497
  env
29483
29498
  });
29484
- if (options.stdio === "stderr") {
29485
- child.stdout?.on("data", (chunk) => {
29486
- process.stderr.write(chunk);
29487
- });
29488
- child.stderr?.on("data", (chunk) => {
29489
- process.stderr.write(chunk);
29490
- });
29491
- }
29499
+ child.stdout?.on("data", (chunk) => {
29500
+ output2 += chunk.toString();
29501
+ process.stderr.write(chunk);
29502
+ });
29503
+ child.stderr?.on("data", (chunk) => {
29504
+ output2 += chunk.toString();
29505
+ process.stderr.write(chunk);
29506
+ });
29492
29507
  child.on("error", (error) => {
29493
29508
  process.stderr.write(`Failed to start ${command}: ${error.message}
29494
29509
  `);
29495
- resolveExitCode(1);
29510
+ resolveResult({ exitCode: 1, output: `${output2}
29511
+ ${error.message}` });
29496
29512
  });
29497
29513
  child.on("close", (code) => {
29498
- resolveExitCode(code ?? 1);
29514
+ resolveResult({ exitCode: code ?? 1, output: output2 });
29499
29515
  });
29500
29516
  });
29501
29517
  }
29518
+ var DEFAULT_NPM_REGISTRY_URL = "https://registry.npmjs.org/";
29519
+ function isRegistryAccessFailure(output2, registryUrl) {
29520
+ let registryHost = "";
29521
+ try {
29522
+ registryHost = new URL(registryUrl).hostname;
29523
+ } catch {
29524
+ return false;
29525
+ }
29526
+ if (!registryHost || !output2.toLowerCase().includes(registryHost.toLowerCase())) {
29527
+ return false;
29528
+ }
29529
+ return /\b(?:EAI_AGAIN|ECONNREFUSED|ECONNRESET|ENETUNREACH|ENOTFOUND|EHOSTUNREACH|ETIMEDOUT|E5\d\d)\b|\b5\d\d\b|access denied|blocked|forbidden|network (?:error|timeout)|request .* failed/iu.test(
29530
+ output2
29531
+ );
29532
+ }
29533
+ function withRegistry(args, registryUrl) {
29534
+ return [...args.slice(0, -1), "--registry", registryUrl, args.at(-1) ?? ""];
29535
+ }
29536
+ async function runNpmInstallWithRegistryFallback(input2) {
29537
+ const primaryArgs = input2.primaryRegistryUrl ? withRegistry(input2.installArgs, input2.primaryRegistryUrl) : input2.installArgs;
29538
+ const first = await runCommand(
29539
+ input2.npmCommand,
29540
+ primaryArgs,
29541
+ input2.env ?? process.env
29542
+ );
29543
+ if (first.exitCode === 0 || !input2.fallbackRegistryUrl || !isRegistryAccessFailure(
29544
+ first.output,
29545
+ input2.primaryRegistryUrl ?? DEFAULT_NPM_REGISTRY_URL
29546
+ )) {
29547
+ return first.exitCode;
29548
+ }
29549
+ process.stderr.write(
29550
+ `Primary npm registry access failed; retrying through Deepline's registry: ${input2.fallbackRegistryUrl}
29551
+ `
29552
+ );
29553
+ const fallback = await runCommand(
29554
+ input2.npmCommand,
29555
+ withRegistry(input2.installArgs, input2.fallbackRegistryUrl),
29556
+ input2.env ?? process.env
29557
+ );
29558
+ return fallback.exitCode;
29559
+ }
29502
29560
  function writeSidecarLauncher(input2) {
29503
29561
  mkdirSync10(dirname13(input2.path), { recursive: true });
29504
29562
  if (process.platform === "win32") {
@@ -29526,7 +29584,7 @@ function writeSidecarLauncher(input2) {
29526
29584
  { encoding: "utf8", mode: 493 }
29527
29585
  );
29528
29586
  }
29529
- async function runPythonSidecarUpdatePlan(plan, options = {}) {
29587
+ async function runPythonSidecarUpdatePlan(plan) {
29530
29588
  const versionsDir = join14(plan.stateDir, "versions");
29531
29589
  const tempDir = join14(
29532
29590
  versionsDir,
@@ -29539,7 +29597,7 @@ async function runPythonSidecarUpdatePlan(plan, options = {}) {
29539
29597
  ...process.env,
29540
29598
  PATH: `${dirname13(plan.nodeBin)}${process.platform === "win32" ? ";" : ":"}${process.env.PATH ?? ""}`
29541
29599
  };
29542
- const installExitCode = await runCommand(
29600
+ const installResult = await runCommand(
29543
29601
  plan.npmCommand,
29544
29602
  [
29545
29603
  "install",
@@ -29550,9 +29608,9 @@ async function runPythonSidecarUpdatePlan(plan, options = {}) {
29550
29608
  ...NPM_SDK_INSTALL_COMMON_FLAGS,
29551
29609
  plan.packageSpec
29552
29610
  ],
29553
- env,
29554
- options
29611
+ env
29555
29612
  );
29613
+ const installExitCode = installResult.exitCode;
29556
29614
  if (installExitCode !== 0) {
29557
29615
  rmSync4(tempDir, { recursive: true, force: true });
29558
29616
  return installExitCode;
@@ -29624,12 +29682,17 @@ async function runPythonSidecarUpdatePlan(plan, options = {}) {
29624
29682
  );
29625
29683
  return 0;
29626
29684
  }
29627
- async function runUpdatePlan(plan, options = {}) {
29685
+ async function runUpdatePlan(plan) {
29628
29686
  let exitCode = 1;
29629
29687
  if (plan.kind === "npm-global") {
29630
- exitCode = await runCommand(plan.command, plan.args, process.env, options);
29688
+ exitCode = await runNpmInstallWithRegistryFallback({
29689
+ npmCommand: plan.command,
29690
+ installArgs: plan.args,
29691
+ primaryRegistryUrl: plan.primaryRegistryUrl,
29692
+ fallbackRegistryUrl: plan.fallbackRegistryUrl
29693
+ });
29631
29694
  } else if (plan.kind === "python-sidecar") {
29632
- exitCode = await runPythonSidecarUpdatePlan(plan, options);
29695
+ exitCode = await runPythonSidecarUpdatePlan(plan);
29633
29696
  }
29634
29697
  if (exitCode === 0) {
29635
29698
  clearAutoUpdateFailure(plan);
@@ -71,7 +71,6 @@ interface PlayStaticColumnProducer {
71
71
  field: string;
72
72
  toolId?: string;
73
73
  playId?: string;
74
- dependsOnFields?: string[];
75
74
  conditional?: boolean;
76
75
  sourceRange?: PlayStaticSourceRange;
77
76
  steps?: PlayStaticColumnProducer[];
@@ -93,7 +92,6 @@ interface PlayStaticSourceRange {
93
92
  type PlayStaticSubstepMetadata = {
94
93
  conditional?: boolean;
95
94
  disabled?: boolean;
96
- dependsOnFields?: string[];
97
95
  };
98
96
  /**
99
97
  * One arm of a conditional `control_flow` substep — an `if`/`else if`/`else`
@@ -71,7 +71,6 @@ interface PlayStaticColumnProducer {
71
71
  field: string;
72
72
  toolId?: string;
73
73
  playId?: string;
74
- dependsOnFields?: string[];
75
74
  conditional?: boolean;
76
75
  sourceRange?: PlayStaticSourceRange;
77
76
  steps?: PlayStaticColumnProducer[];
@@ -93,7 +92,6 @@ interface PlayStaticSourceRange {
93
92
  type PlayStaticSubstepMetadata = {
94
93
  conditional?: boolean;
95
94
  disabled?: boolean;
96
- dependsOnFields?: string[];
97
95
  };
98
96
  /**
99
97
  * One arm of a conditional `control_flow` substep — an `if`/`else if`/`else`
package/dist/index.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- import { a as PlayCompilerManifest } from './compiler-manifest-DlE7dnRm.mjs';
1
+ import { a as PlayCompilerManifest } from './compiler-manifest-BjopNIqx.mjs';
2
2
 
3
3
  type PlayRuntimeSelection = {
4
4
  environment: 'preview';
package/dist/index.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { a as PlayCompilerManifest } from './compiler-manifest-DlE7dnRm.js';
1
+ import { a as PlayCompilerManifest } from './compiler-manifest-BjopNIqx.js';
2
2
 
3
3
  type PlayRuntimeSelection = {
4
4
  environment: 'preview';
package/dist/index.js CHANGED
@@ -435,7 +435,7 @@ var SDK_RELEASE = {
435
435
  // Deepline-native radars. Older clients must update before discovering,
436
436
  // checking, or deploying an unlaunched monitor integration.
437
437
  // 0.1.253 makes play-page browser opening opt-in and retires --no-open.
438
- version: "0.1.255",
438
+ version: "0.1.257",
439
439
  apiContract: "2026-07-native-monitor-launch-hard-cutover",
440
440
  supportPolicy: {
441
441
  minimumSupported: "0.1.53",
@@ -443,8 +443,11 @@ var SDK_RELEASE = {
443
443
  commandMinimumSupported: [
444
444
  {
445
445
  command: "enrich",
446
- minimumSupported: "0.1.253",
447
- reason: 'Older SDK CLI enrich generated stale play source; SDK CLI enrich 0.1.153 generated removed StepOptions fields in play source; SDK CLI enrich before 0.1.175 could silently succeed on the empty-waterfall bug when a requested waterfall returned no values for selected rows; SDK CLI enrich before 0.1.230 could convert extractor failures into successful unmatched results; SDK CLI enrich before 0.1.238 could drop a nested provider email match during generic pick("email") extraction and materialize it as NO_MATCH; SDK CLI enrich before 0.1.253 opens the generated play page by default and accepts the removed --no-open flag.'
446
+ // Compatibility window through 2026-08-22 (owner: Chirag): versions
447
+ // 0.1.238-0.1.252 differ only in local browser-opening behavior and
448
+ // already contain the enrich data-correctness fixes below.
449
+ minimumSupported: "0.1.238",
450
+ reason: 'Older SDK CLI enrich generated stale play source; SDK CLI enrich 0.1.153 generated removed StepOptions fields in play source; SDK CLI enrich before 0.1.175 could silently succeed on the empty-waterfall bug when a requested waterfall returned no values for selected rows; SDK CLI enrich before 0.1.230 could convert extractor failures into successful unmatched results; SDK CLI enrich before 0.1.238 could drop a nested provider email match during generic pick("email") extraction and materialize it as NO_MATCH.'
448
451
  },
449
452
  {
450
453
  command: "plays",
package/dist/index.mjs CHANGED
@@ -365,7 +365,7 @@ var SDK_RELEASE = {
365
365
  // Deepline-native radars. Older clients must update before discovering,
366
366
  // checking, or deploying an unlaunched monitor integration.
367
367
  // 0.1.253 makes play-page browser opening opt-in and retires --no-open.
368
- version: "0.1.255",
368
+ version: "0.1.257",
369
369
  apiContract: "2026-07-native-monitor-launch-hard-cutover",
370
370
  supportPolicy: {
371
371
  minimumSupported: "0.1.53",
@@ -373,8 +373,11 @@ var SDK_RELEASE = {
373
373
  commandMinimumSupported: [
374
374
  {
375
375
  command: "enrich",
376
- minimumSupported: "0.1.253",
377
- reason: 'Older SDK CLI enrich generated stale play source; SDK CLI enrich 0.1.153 generated removed StepOptions fields in play source; SDK CLI enrich before 0.1.175 could silently succeed on the empty-waterfall bug when a requested waterfall returned no values for selected rows; SDK CLI enrich before 0.1.230 could convert extractor failures into successful unmatched results; SDK CLI enrich before 0.1.238 could drop a nested provider email match during generic pick("email") extraction and materialize it as NO_MATCH; SDK CLI enrich before 0.1.253 opens the generated play page by default and accepts the removed --no-open flag.'
376
+ // Compatibility window through 2026-08-22 (owner: Chirag): versions
377
+ // 0.1.238-0.1.252 differ only in local browser-opening behavior and
378
+ // already contain the enrich data-correctness fixes below.
379
+ minimumSupported: "0.1.238",
380
+ reason: 'Older SDK CLI enrich generated stale play source; SDK CLI enrich 0.1.153 generated removed StepOptions fields in play source; SDK CLI enrich before 0.1.175 could silently succeed on the empty-waterfall bug when a requested waterfall returned no values for selected rows; SDK CLI enrich before 0.1.230 could convert extractor failures into successful unmatched results; SDK CLI enrich before 0.1.238 could drop a nested provider email match during generic pick("email") extraction and materialize it as NO_MATCH.'
378
381
  },
379
382
  {
380
383
  command: "plays",
@@ -1,5 +1,5 @@
1
- import { P as PlayArtifactKind$1, a as PlayCompilerManifest } from '../compiler-manifest-DlE7dnRm.mjs';
2
- export { b as PLAY_ARTIFACT_KINDS } from '../compiler-manifest-DlE7dnRm.mjs';
1
+ import { P as PlayArtifactKind$1, a as PlayCompilerManifest } from '../compiler-manifest-BjopNIqx.mjs';
2
+ export { b as PLAY_ARTIFACT_KINDS } from '../compiler-manifest-BjopNIqx.mjs';
3
3
 
4
4
  type PlayPackageImport = {
5
5
  name: string;
@@ -1,5 +1,5 @@
1
- import { P as PlayArtifactKind$1, a as PlayCompilerManifest } from '../compiler-manifest-DlE7dnRm.js';
2
- export { b as PLAY_ARTIFACT_KINDS } from '../compiler-manifest-DlE7dnRm.js';
1
+ import { P as PlayArtifactKind$1, a as PlayCompilerManifest } from '../compiler-manifest-BjopNIqx.js';
2
+ export { b as PLAY_ARTIFACT_KINDS } from '../compiler-manifest-BjopNIqx.js';
3
3
 
4
4
  type PlayPackageImport = {
5
5
  name: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "deepline",
3
- "version": "0.1.255",
3
+ "version": "0.1.257",
4
4
  "description": "Deepline SDK + CLI — B2B data enrichment powered by durable cloud execution",
5
5
  "license": "MIT",
6
6
  "repository": {