nx 20.5.0-canary.20250129-3f5e863 → 20.5.0-canary.20250201-05e0679

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nx",
3
- "version": "20.5.0-canary.20250129-3f5e863",
3
+ "version": "20.5.0-canary.20250201-05e0679",
4
4
  "private": false,
5
5
  "description": "The core Nx plugin contains the core functionality of Nx like the project graph, nx commands and task orchestration.",
6
6
  "repository": {
@@ -82,16 +82,16 @@
82
82
  }
83
83
  },
84
84
  "optionalDependencies": {
85
- "@nx/nx-darwin-arm64": "20.5.0-canary.20250129-3f5e863",
86
- "@nx/nx-darwin-x64": "20.5.0-canary.20250129-3f5e863",
87
- "@nx/nx-freebsd-x64": "20.5.0-canary.20250129-3f5e863",
88
- "@nx/nx-linux-arm-gnueabihf": "20.5.0-canary.20250129-3f5e863",
89
- "@nx/nx-linux-arm64-gnu": "20.5.0-canary.20250129-3f5e863",
90
- "@nx/nx-linux-arm64-musl": "20.5.0-canary.20250129-3f5e863",
91
- "@nx/nx-linux-x64-gnu": "20.5.0-canary.20250129-3f5e863",
92
- "@nx/nx-linux-x64-musl": "20.5.0-canary.20250129-3f5e863",
93
- "@nx/nx-win32-arm64-msvc": "20.5.0-canary.20250129-3f5e863",
94
- "@nx/nx-win32-x64-msvc": "20.5.0-canary.20250129-3f5e863"
85
+ "@nx/nx-darwin-arm64": "20.5.0-canary.20250201-05e0679",
86
+ "@nx/nx-darwin-x64": "20.5.0-canary.20250201-05e0679",
87
+ "@nx/nx-freebsd-x64": "20.5.0-canary.20250201-05e0679",
88
+ "@nx/nx-linux-arm-gnueabihf": "20.5.0-canary.20250201-05e0679",
89
+ "@nx/nx-linux-arm64-gnu": "20.5.0-canary.20250201-05e0679",
90
+ "@nx/nx-linux-arm64-musl": "20.5.0-canary.20250201-05e0679",
91
+ "@nx/nx-linux-x64-gnu": "20.5.0-canary.20250201-05e0679",
92
+ "@nx/nx-linux-x64-musl": "20.5.0-canary.20250201-05e0679",
93
+ "@nx/nx-win32-arm64-msvc": "20.5.0-canary.20250201-05e0679",
94
+ "@nx/nx-win32-x64-msvc": "20.5.0-canary.20250201-05e0679"
95
95
  },
96
96
  "nx-migrations": {
97
97
  "migrations": "./migrations.json",
Binary file
@@ -33,7 +33,7 @@ export declare function getTranspiler(compilerOptions: CompilerOptions, tsConfig
33
33
  *
34
34
  * @returns cleanup method
35
35
  */
36
- export declare function registerTranspiler(compilerOptions: CompilerOptions, tsConfigRaw?: unknown): () => void;
36
+ export declare function registerTranspiler(compilerOptions: CompilerOptions): () => void;
37
37
  /**
38
38
  * @param tsConfigPath Adds the paths from a tsconfig file into node resolutions
39
39
  * @returns cleanup function
@@ -203,7 +203,7 @@ function getTranspiler(compilerOptions, tsConfigRaw) {
203
203
  *
204
204
  * @returns cleanup method
205
205
  */
206
- function registerTranspiler(compilerOptions, tsConfigRaw) {
206
+ function registerTranspiler(compilerOptions) {
207
207
  // Function to register transpiler that returns cleanup function
208
208
  const transpiler = getTranspiler(compilerOptions);
209
209
  if (!transpiler) {
@@ -1,6 +1,7 @@
1
1
  import type * as ts from 'typescript';
2
2
  import type { Node, SyntaxKind } from 'typescript';
3
3
  export declare function readTsConfig(tsConfigPath: string): ts.ParsedCommandLine;
4
+ export declare function readTsConfigOptions(tsConfigPath: string): ts.CompilerOptions;
4
5
  /**
5
6
  * Find a module based on its import
6
7
  *
@@ -1,6 +1,7 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.readTsConfig = readTsConfig;
4
+ exports.readTsConfigOptions = readTsConfigOptions;
4
5
  exports.resolveModuleByImport = resolveModuleByImport;
5
6
  exports.getRootTsConfigFileName = getRootTsConfigFileName;
6
7
  exports.getRootTsConfigPath = getRootTsConfigPath;
@@ -75,9 +75,9 @@ class LoadedNxPlugin {
75
75
  }
76
76
  return updates;
77
77
  };
78
- if (plugin.postTasksExecution) {
79
- this.postTasksExecution = async (context) => plugin.postTasksExecution(this.options, context);
80
- }
78
+ }
79
+ if (plugin.postTasksExecution) {
80
+ this.postTasksExecution = async (context) => plugin.postTasksExecution(this.options, context);
81
81
  }
82
82
  }
83
83
  }
@@ -23,16 +23,16 @@ function registerPluginTSTranspiler() {
23
23
  if (!tsConfigName) {
24
24
  return;
25
25
  }
26
- const tsConfig = tsConfigName
27
- ? (0, typescript_1.readTsConfig)(tsConfigName)
26
+ const tsConfigOptions = tsConfigName
27
+ ? (0, typescript_1.readTsConfigOptions)(tsConfigName)
28
28
  : {};
29
29
  const cleanupFns = [
30
30
  (0, register_1.registerTsConfigPaths)(tsConfigName),
31
31
  (0, register_1.registerTranspiler)({
32
32
  experimentalDecorators: true,
33
33
  emitDecoratorMetadata: true,
34
- ...tsConfig.options,
35
- }, tsConfig.raw),
34
+ ...tsConfigOptions,
35
+ }),
36
36
  ];
37
37
  exports.unregisterPluginTSTranspiler = () => {
38
38
  cleanupFns.forEach((fn) => fn?.());
@@ -437,18 +437,19 @@ function tryAndRetry(fn) {
437
437
  let attempts = 0;
438
438
  // Generate a random number between 2 and 4 to raise to the power of attempts
439
439
  const baseExponent = Math.random() * 2 + 2;
440
+ const baseTimeout = 15;
440
441
  const _try = async () => {
441
442
  try {
442
443
  attempts++;
443
444
  return await fn();
444
445
  }
445
446
  catch (e) {
446
- // Max time is 5 * 4^3 = 20480ms
447
+ // Max time is 15 * (4 + 4² + 4³ + 4⁴ + 4⁵) = 20460ms
447
448
  if (attempts === 6) {
448
449
  // After enough attempts, throw the error
449
450
  throw e;
450
451
  }
451
- await new Promise((res) => setTimeout(res, baseExponent ** attempts));
452
+ await new Promise((res) => setTimeout(res, baseTimeout * baseExponent ** attempts));
452
453
  return await _try();
453
454
  }
454
455
  };