mirror of
https://github.com/n8n-io/n8n.git
synced 2026-07-27 19:15:01 +02:00
chore: Migrate part of backend packages to Typescript 7 (#34131)
Some checks are pending
Build: Benchmark Image / build (push) Waiting to run
CI: Master (Build, Test, Lint) / Build for Github Cache (push) Waiting to run
CI: Master (Build, Test, Lint) / Unit tests (22.22.3) (push) Waiting to run
CI: Master (Build, Test, Lint) / Unit tests (24.16.0) (push) Waiting to run
CI: Master (Build, Test, Lint) / Lint (push) Waiting to run
CI: Master (Build, Test, Lint) / Performance (push) Waiting to run
CI: Master (Build, Test, Lint) / Notify Slack on failure (push) Blocked by required conditions
Util: Sync API Docs / sync-public-api (push) Waiting to run
Some checks are pending
Build: Benchmark Image / build (push) Waiting to run
CI: Master (Build, Test, Lint) / Build for Github Cache (push) Waiting to run
CI: Master (Build, Test, Lint) / Unit tests (22.22.3) (push) Waiting to run
CI: Master (Build, Test, Lint) / Unit tests (24.16.0) (push) Waiting to run
CI: Master (Build, Test, Lint) / Lint (push) Waiting to run
CI: Master (Build, Test, Lint) / Performance (push) Waiting to run
CI: Master (Build, Test, Lint) / Notify Slack on failure (push) Blocked by required conditions
Util: Sync API Docs / sync-public-api (push) Waiting to run
This commit is contained in:
parent
4ef0d05f1c
commit
2fc48bdfd5
|
|
@ -27,7 +27,7 @@
|
|||
"@n8n/config": "workspace:*",
|
||||
"@n8n/vitest-config": "workspace:*",
|
||||
"@vitest/coverage-v8": "catalog:",
|
||||
"typescript": "catalog:",
|
||||
"typescript": "catalog:typescript",
|
||||
"vite": "catalog:",
|
||||
"vitest": "catalog:",
|
||||
"vitest-mock-extended": "catalog:",
|
||||
|
|
|
|||
|
|
@ -71,7 +71,7 @@ describe('passwordSchema with N8N_PASSWORD_MIN_LENGTH', () => {
|
|||
|
||||
const importFreshSchema = async () => {
|
||||
vi.resetModules();
|
||||
return await import('../password.schema');
|
||||
return await import('../password.schema.js');
|
||||
};
|
||||
|
||||
test('should use custom min length from env var', async () => {
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
"extends": ["./tsconfig.json", "@n8n/typescript-config/tsconfig.build.json"],
|
||||
"extends": ["./tsconfig.json", "@n8n/typescript-config/tsconfig.build.go.json"],
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.go.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vitest/globals", "vite/client"]
|
||||
},
|
||||
|
|
|
|||
|
|
@ -44,7 +44,7 @@
|
|||
"@types/yargs-parser": "21.0.0",
|
||||
"@n8n/vitest-config": "workspace:*",
|
||||
"@vitest/coverage-v8": "catalog:",
|
||||
"typescript": "catalog:",
|
||||
"typescript": "catalog:typescript",
|
||||
"vitest": "catalog:",
|
||||
"vitest-mock-extended": "catalog:",
|
||||
"zod": "catalog:"
|
||||
|
|
|
|||
|
|
@ -103,10 +103,10 @@ export class ModuleRegistry {
|
|||
|
||||
for (const moduleName of modules ?? this.eligibleModules) {
|
||||
try {
|
||||
await import(`${modulesDir}/${moduleName}/${moduleName}.module`);
|
||||
await import(`${modulesDir}/${moduleName}/${moduleName}.module.js`);
|
||||
} catch (primaryError) {
|
||||
try {
|
||||
await import(`${modulesDir}/${moduleName}.ee/${moduleName}.module`);
|
||||
await import(`${modulesDir}/${moduleName}.ee/${moduleName}.module.js`);
|
||||
} catch (error) {
|
||||
const loggedError =
|
||||
primaryError instanceof Error &&
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
"extends": ["./tsconfig.json", "@n8n/typescript-config/tsconfig.build.json"],
|
||||
"extends": ["./tsconfig.json", "@n8n/typescript-config/tsconfig.build.go.json"],
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.go.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vitest/globals"],
|
||||
"experimentalDecorators": true,
|
||||
|
|
|
|||
|
|
@ -73,7 +73,7 @@ describe('outbound-user-agent', () => {
|
|||
|
||||
const di = await import('@n8n/di');
|
||||
const config = await import('@n8n/config');
|
||||
const mod = await import('../user-agent');
|
||||
const mod = await import('../user-agent.js');
|
||||
|
||||
di.Container.set(config.HttpRequestConfig, {
|
||||
enforceGlobalUserAgent: true,
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@
|
|||
/* eslint-disable @typescript-eslint/no-unsafe-return */
|
||||
/* eslint-disable @typescript-eslint/no-unsafe-member-access */
|
||||
|
||||
import type { AxiosHeaders, AxiosRequestConfig } from 'axios';
|
||||
import type { AxiosRequestConfig, AxiosRequestHeaders } from 'axios';
|
||||
import crypto from 'crypto';
|
||||
import type FormData from 'form-data';
|
||||
import { type AgentOptions } from 'https';
|
||||
|
|
@ -57,7 +57,7 @@ export async function buildAxiosConfigFromLegacyRequest(
|
|||
const axiosConfig: AxiosRequestConfig = {};
|
||||
|
||||
if (requestObject.headers !== undefined) {
|
||||
axiosConfig.headers = requestObject.headers as AxiosHeaders;
|
||||
axiosConfig.headers = requestObject.headers as AxiosRequestHeaders;
|
||||
}
|
||||
|
||||
// Let's start parsing the hardest part, which is the request body.
|
||||
|
|
|
|||
|
|
@ -37,7 +37,7 @@
|
|||
},
|
||||
"devDependencies": {
|
||||
"@n8n/typescript-config": "workspace:*",
|
||||
"typescript": "catalog:"
|
||||
"typescript": "catalog:typescript"
|
||||
},
|
||||
"license": "LicenseRef-n8n-sustainable-use"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
"extends": ["./tsconfig.json", "@n8n/typescript-config/tsconfig.build.json"],
|
||||
"extends": ["./tsconfig.json", "@n8n/typescript-config/tsconfig.build.go.json"],
|
||||
"compilerOptions": {
|
||||
"composite": true,
|
||||
"rootDir": "src",
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
{
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.json",
|
||||
"extends": "@n8n/typescript-config/tsconfig.common.go.json",
|
||||
"compilerOptions": {
|
||||
"types": ["node", "vitest/globals"],
|
||||
"tsBuildInfoFile": "dist/typecheck.tsbuildinfo",
|
||||
|
|
|
|||
|
|
@ -84,7 +84,7 @@
|
|||
"source-map-support": "^0.5.21",
|
||||
"sqlite3": "5.1.7",
|
||||
"ts-node": "^10.9.1",
|
||||
"typescript": "catalog:"
|
||||
"typescript": "catalog:typescript"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"pg": "^8.17.0",
|
||||
|
|
|
|||
|
|
@ -5,11 +5,11 @@ import { MissingDriverError } from '../error/MissingDriverError';
|
|||
const getDriver = async (type: DataSource['options']['type']): Promise<DriverConstructor> => {
|
||||
switch (type) {
|
||||
case 'postgres':
|
||||
return (await import('./postgres/PostgresDriver')).PostgresDriver;
|
||||
return (await import('./postgres/PostgresDriver.js')).PostgresDriver;
|
||||
case 'sqlite':
|
||||
return (await import('./sqlite/SqliteDriver')).SqliteDriver;
|
||||
return (await import('./sqlite/SqliteDriver.js')).SqliteDriver;
|
||||
case 'sqlite-pooled':
|
||||
return (await import('./sqlite-pooled/SqliteReadWriteDriver')).SqliteReadWriteDriver;
|
||||
return (await import('./sqlite-pooled/SqliteReadWriteDriver.js')).SqliteReadWriteDriver;
|
||||
default:
|
||||
throw new MissingDriverError(type, ['postgres', 'sqlite', 'sqlite-pooled']);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
import { ObjectLiteral } from '../common/ObjectLiteral';
|
||||
import type { ObjectLiteral } from '../common/ObjectLiteral';
|
||||
|
||||
/**
|
||||
* Make all properties in T optional
|
||||
|
|
@ -7,22 +7,28 @@ export type QueryPartialEntity<T> = {
|
|||
[P in keyof T]?: T[P] | (() => string);
|
||||
};
|
||||
|
||||
type _QueryDeepPartialEntityDecr = [never, 0, 1, 2, 3, 4, 5, 6, 7, 8, 9];
|
||||
|
||||
type _QueryDeepPartialEntity<T, Depth extends number = 10> = [Depth] extends [never]
|
||||
? T
|
||||
: {
|
||||
[P in keyof T]?:
|
||||
| (T[P] extends Array<infer U>
|
||||
? Array<_QueryDeepPartialEntity<U, _QueryDeepPartialEntityDecr[Depth]>>
|
||||
: T[P] extends ReadonlyArray<infer U>
|
||||
? ReadonlyArray<_QueryDeepPartialEntity<U, _QueryDeepPartialEntityDecr[Depth]>>
|
||||
: _QueryDeepPartialEntity<T[P], _QueryDeepPartialEntityDecr[Depth]>)
|
||||
| (() => string);
|
||||
};
|
||||
|
||||
/**
|
||||
* Make all properties in T optional. Deep version.
|
||||
*
|
||||
* Recursion is bounded by a fixed depth budget instead of a growing `Seen`
|
||||
* union (expensive for the checker) or unbounded recursion (trips the
|
||||
* compiler's own depth limiter with TS2589 on deep payloads such as INode[]).
|
||||
* At the depth floor the full `T` is returned so deep writes stay assignable.
|
||||
*/
|
||||
export type QueryDeepPartialEntity<T> = _QueryDeepPartialEntity<
|
||||
ObjectLiteral extends T ? unknown : T,
|
||||
never
|
||||
ObjectLiteral extends T ? unknown : T
|
||||
>;
|
||||
|
||||
type _QueryDeepPartialEntity<Entity, Seen = never> = {
|
||||
[Property in keyof Entity]?:
|
||||
| (Entity[Property] extends Seen
|
||||
? Entity[Property] // break cycle
|
||||
: Entity[Property] extends Array<infer ArrayItem>
|
||||
? Array<_QueryDeepPartialEntity<ArrayItem, Seen | Entity[Property]>>
|
||||
: Entity[Property] extends ReadonlyArray<infer ArrayItem>
|
||||
? ReadonlyArray<_QueryDeepPartialEntity<ArrayItem, Seen | Entity[Property]>>
|
||||
: _QueryDeepPartialEntity<Entity[Property], Seen | Entity[Property]>)
|
||||
| (() => string);
|
||||
};
|
||||
|
|
|
|||
|
|
@ -5,12 +5,11 @@
|
|||
"lib": ["ES2022.Error"],
|
||||
"allowSyntheticDefaultImports": true,
|
||||
"declaration": true,
|
||||
"downlevelIteration": true,
|
||||
"emitDecoratorMetadata": true,
|
||||
"experimentalDecorators": true,
|
||||
"importHelpers": true,
|
||||
"module": "commonjs",
|
||||
"moduleResolution": "node",
|
||||
"module": "NodeNext",
|
||||
"moduleResolution": "NodeNext",
|
||||
"noFallthroughCasesInSwitch": true,
|
||||
"noImplicitAny": true,
|
||||
"noImplicitReturns": true,
|
||||
|
|
|
|||
114
pnpm-lock.yaml
114
pnpm-lock.yaml
|
|
@ -1331,8 +1331,8 @@ importers:
|
|||
specifier: 1.34.1
|
||||
version: 1.34.1(patch_hash=bc707e2c34a2464da2c9c93ead33e80fd9883a00434ef64907ddc45208a08b33)
|
||||
typescript:
|
||||
specifier: 'catalog:'
|
||||
version: 6.0.2
|
||||
specifier: catalog:typescript
|
||||
version: 7.0.2
|
||||
vite:
|
||||
specifier: 'catalog:'
|
||||
version: 8.0.2(@types/node@20.19.41)(esbuild@0.28.1)(jiti@2.6.1)(sass-embedded@1.98.0)(sass@1.98.0)(terser@5.16.1)(tsx@4.19.3)(yaml@2.8.3)
|
||||
|
|
@ -1341,7 +1341,7 @@ importers:
|
|||
version: 4.1.9(@opentelemetry/api@1.9.0)(@types/node@20.19.41)(@vitest/browser-playwright@4.1.9)(@vitest/coverage-v8@4.1.9)(jsdom@23.0.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(vite@8.0.2(@types/node@20.19.41)(esbuild@0.28.1)(jiti@2.6.1)(sass-embedded@1.98.0)(sass@1.98.0)(terser@5.16.1)(tsx@4.19.3)(yaml@2.8.3))
|
||||
vitest-mock-extended:
|
||||
specifier: 'catalog:'
|
||||
version: 3.1.0(typescript@6.0.2)(vitest@4.1.9)
|
||||
version: 3.1.0(typescript@7.0.2)(vitest@4.1.9)
|
||||
zod:
|
||||
specifier: 3.25.67
|
||||
version: 3.25.67
|
||||
|
|
@ -1407,14 +1407,14 @@ importers:
|
|||
specifier: 'catalog:'
|
||||
version: 4.1.9(@vitest/browser@4.1.9)(vitest@4.1.9)
|
||||
typescript:
|
||||
specifier: 'catalog:'
|
||||
version: 6.0.2
|
||||
specifier: catalog:typescript
|
||||
version: 7.0.2
|
||||
vitest:
|
||||
specifier: 'catalog:'
|
||||
version: 4.1.9(@opentelemetry/api@1.9.0)(@types/node@20.19.41)(@vitest/browser-playwright@4.1.9)(@vitest/coverage-v8@4.1.9)(jsdom@23.0.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(vite@8.0.2(@types/node@20.19.41)(esbuild@0.28.1)(jiti@2.6.1)(sass-embedded@1.98.0)(sass@1.98.0)(terser@5.16.1)(tsx@4.19.3)(yaml@2.8.3))
|
||||
vitest-mock-extended:
|
||||
specifier: 'catalog:'
|
||||
version: 3.1.0(typescript@6.0.2)(vitest@4.1.9)
|
||||
version: 3.1.0(typescript@7.0.2)(vitest@4.1.9)
|
||||
zod:
|
||||
specifier: 3.25.67
|
||||
version: 3.25.67
|
||||
|
|
@ -1538,14 +1538,14 @@ importers:
|
|||
version: 4.1.9(@opentelemetry/api@1.9.0)(@types/node@20.19.41)(@vitest/browser-playwright@4.1.9)(@vitest/coverage-v8@4.1.9)(jsdom@23.0.1(bufferutil@4.0.9)(utf-8-validate@5.0.10))(vite@8.0.2(@types/node@20.19.41)(esbuild@0.28.1)(jiti@2.6.1)(sass-embedded@1.98.0)(sass@1.98.0)(terser@5.16.1)(tsx@4.19.3)(yaml@2.8.3))
|
||||
vitest-mock-extended:
|
||||
specifier: 'catalog:'
|
||||
version: 3.1.0(typescript@6.0.2)(vitest@4.1.9)
|
||||
version: 3.1.0(typescript@7.0.2)(vitest@4.1.9)
|
||||
devDependencies:
|
||||
'@n8n/typescript-config':
|
||||
specifier: workspace:*
|
||||
version: link:../typescript-config
|
||||
typescript:
|
||||
specifier: 'catalog:'
|
||||
version: 6.0.2
|
||||
specifier: catalog:typescript
|
||||
version: 7.0.2
|
||||
|
||||
packages/@n8n/benchmark:
|
||||
dependencies:
|
||||
|
|
@ -3654,7 +3654,7 @@ importers:
|
|||
version: 9.0.8
|
||||
'@typescript-eslint/eslint-plugin':
|
||||
specifier: ^8.35.0
|
||||
version: 8.35.0(@typescript-eslint/parser@8.35.0(eslint@8.57.1)(typescript@6.0.2))(eslint@8.57.1)(typescript@6.0.2)
|
||||
version: 8.35.0(@typescript-eslint/parser@8.35.0(eslint@8.57.1)(typescript@7.0.2))(eslint@8.57.1)(typescript@7.0.2)
|
||||
chai:
|
||||
specifier: ^4.3.7
|
||||
version: 4.5.0
|
||||
|
|
@ -3693,10 +3693,10 @@ importers:
|
|||
version: 5.1.7
|
||||
ts-node:
|
||||
specifier: ^10.9.1
|
||||
version: 10.9.2(@swc/core@1.15.8(@swc/helpers@0.5.17))(@types/node@20.19.41)(typescript@6.0.2)
|
||||
version: 10.9.2(@swc/core@1.15.8(@swc/helpers@0.5.17))(@types/node@20.19.41)(typescript@7.0.2)
|
||||
typescript:
|
||||
specifier: 'catalog:'
|
||||
version: 6.0.2
|
||||
specifier: catalog:typescript
|
||||
version: 7.0.2
|
||||
|
||||
packages/@n8n/typescript-config: {}
|
||||
|
||||
|
|
@ -29631,20 +29631,20 @@ snapshots:
|
|||
'@types/node': 20.19.41
|
||||
optional: true
|
||||
|
||||
'@typescript-eslint/eslint-plugin@8.35.0(@typescript-eslint/parser@8.35.0(eslint@8.57.1)(typescript@6.0.2))(eslint@8.57.1)(typescript@6.0.2)':
|
||||
'@typescript-eslint/eslint-plugin@8.35.0(@typescript-eslint/parser@8.35.0(eslint@8.57.1)(typescript@7.0.2))(eslint@8.57.1)(typescript@7.0.2)':
|
||||
dependencies:
|
||||
'@eslint-community/regexpp': 4.12.1
|
||||
'@typescript-eslint/parser': 8.35.0(eslint@8.57.1)(typescript@6.0.2)
|
||||
'@typescript-eslint/parser': 8.35.0(eslint@8.57.1)(typescript@7.0.2)
|
||||
'@typescript-eslint/scope-manager': 8.35.0
|
||||
'@typescript-eslint/type-utils': 8.35.0(eslint@8.57.1)(typescript@6.0.2)
|
||||
'@typescript-eslint/utils': 8.35.0(eslint@8.57.1)(typescript@6.0.2)
|
||||
'@typescript-eslint/type-utils': 8.35.0(eslint@8.57.1)(typescript@7.0.2)
|
||||
'@typescript-eslint/utils': 8.35.0(eslint@8.57.1)(typescript@7.0.2)
|
||||
'@typescript-eslint/visitor-keys': 8.35.0
|
||||
eslint: 8.57.1
|
||||
graphemer: 1.4.0
|
||||
ignore: 7.0.5
|
||||
natural-compare: 1.4.0
|
||||
ts-api-utils: 2.1.0(typescript@6.0.2)
|
||||
typescript: 6.0.2
|
||||
ts-api-utils: 2.1.0(typescript@7.0.2)
|
||||
typescript: 7.0.2
|
||||
transitivePeerDependencies:
|
||||
- supports-color
|
||||
|
||||
|
|
@ -29665,15 +29665,15 @@ snapshots:
|
|||
transitivePeerDependencies:
|
||||
- supports-color
|
||||
|
||||
'@typescript-eslint/parser@8.35.0(eslint@8.57.1)(typescript@6.0.2)':
|
||||
'@typescript-eslint/parser@8.35.0(eslint@8.57.1)(typescript@7.0.2)':
|
||||
dependencies:
|
||||
'@typescript-eslint/scope-manager': 8.35.0
|
||||
'@typescript-eslint/types': 8.35.0
|
||||
'@typescript-eslint/typescript-estree': 8.35.0(typescript@6.0.2)
|
||||
'@typescript-eslint/typescript-estree': 8.35.0(typescript@7.0.2)
|
||||
'@typescript-eslint/visitor-keys': 8.35.0
|
||||
debug: 4.4.3(supports-color@8.1.1)
|
||||
eslint: 8.57.1
|
||||
typescript: 6.0.2
|
||||
typescript: 7.0.2
|
||||
transitivePeerDependencies:
|
||||
- supports-color
|
||||
|
||||
|
|
@ -29707,6 +29707,15 @@ snapshots:
|
|||
transitivePeerDependencies:
|
||||
- supports-color
|
||||
|
||||
'@typescript-eslint/project-service@8.35.0(typescript@7.0.2)':
|
||||
dependencies:
|
||||
'@typescript-eslint/tsconfig-utils': 8.35.0(typescript@7.0.2)
|
||||
'@typescript-eslint/types': 8.35.0
|
||||
debug: 4.4.3(supports-color@8.1.1)
|
||||
typescript: 7.0.2
|
||||
transitivePeerDependencies:
|
||||
- supports-color
|
||||
|
||||
'@typescript-eslint/rule-tester@8.35.0(eslint@9.29.0(jiti@2.6.1))(typescript@6.0.2)':
|
||||
dependencies:
|
||||
'@typescript-eslint/parser': 8.35.0(eslint@9.29.0(jiti@2.6.1))(typescript@6.0.2)
|
||||
|
|
@ -29734,14 +29743,18 @@ snapshots:
|
|||
dependencies:
|
||||
typescript: 6.0.2
|
||||
|
||||
'@typescript-eslint/type-utils@8.35.0(eslint@8.57.1)(typescript@6.0.2)':
|
||||
'@typescript-eslint/tsconfig-utils@8.35.0(typescript@7.0.2)':
|
||||
dependencies:
|
||||
'@typescript-eslint/typescript-estree': 8.35.0(typescript@6.0.2)
|
||||
'@typescript-eslint/utils': 8.35.0(eslint@8.57.1)(typescript@6.0.2)
|
||||
typescript: 7.0.2
|
||||
|
||||
'@typescript-eslint/type-utils@8.35.0(eslint@8.57.1)(typescript@7.0.2)':
|
||||
dependencies:
|
||||
'@typescript-eslint/typescript-estree': 8.35.0(typescript@7.0.2)
|
||||
'@typescript-eslint/utils': 8.35.0(eslint@8.57.1)(typescript@7.0.2)
|
||||
debug: 4.4.3(supports-color@8.1.1)
|
||||
eslint: 8.57.1
|
||||
ts-api-utils: 2.1.0(typescript@6.0.2)
|
||||
typescript: 6.0.2
|
||||
ts-api-utils: 2.1.0(typescript@7.0.2)
|
||||
typescript: 7.0.2
|
||||
transitivePeerDependencies:
|
||||
- supports-color
|
||||
|
||||
|
|
@ -29790,14 +29803,30 @@ snapshots:
|
|||
transitivePeerDependencies:
|
||||
- supports-color
|
||||
|
||||
'@typescript-eslint/utils@8.35.0(eslint@8.57.1)(typescript@6.0.2)':
|
||||
'@typescript-eslint/typescript-estree@8.35.0(typescript@7.0.2)':
|
||||
dependencies:
|
||||
'@typescript-eslint/project-service': 8.35.0(typescript@7.0.2)
|
||||
'@typescript-eslint/tsconfig-utils': 8.35.0(typescript@7.0.2)
|
||||
'@typescript-eslint/types': 8.35.0
|
||||
'@typescript-eslint/visitor-keys': 8.35.0
|
||||
debug: 4.4.3(supports-color@8.1.1)
|
||||
fast-glob: 3.3.3
|
||||
is-glob: 4.0.3
|
||||
minimatch: 9.0.9
|
||||
semver: 7.7.3
|
||||
ts-api-utils: 2.1.0(typescript@7.0.2)
|
||||
typescript: 7.0.2
|
||||
transitivePeerDependencies:
|
||||
- supports-color
|
||||
|
||||
'@typescript-eslint/utils@8.35.0(eslint@8.57.1)(typescript@7.0.2)':
|
||||
dependencies:
|
||||
'@eslint-community/eslint-utils': 4.7.0(eslint@8.57.1)
|
||||
'@typescript-eslint/scope-manager': 8.35.0
|
||||
'@typescript-eslint/types': 8.35.0
|
||||
'@typescript-eslint/typescript-estree': 8.35.0(typescript@6.0.2)
|
||||
'@typescript-eslint/typescript-estree': 8.35.0(typescript@7.0.2)
|
||||
eslint: 8.57.1
|
||||
typescript: 6.0.2
|
||||
typescript: 7.0.2
|
||||
transitivePeerDependencies:
|
||||
- supports-color
|
||||
|
||||
|
|
@ -39970,6 +39999,10 @@ snapshots:
|
|||
dependencies:
|
||||
typescript: 6.0.2
|
||||
|
||||
ts-api-utils@2.1.0(typescript@7.0.2):
|
||||
dependencies:
|
||||
typescript: 7.0.2
|
||||
|
||||
ts-dedent@2.2.0: {}
|
||||
|
||||
ts-error@1.0.6: {}
|
||||
|
|
@ -40028,6 +40061,27 @@ snapshots:
|
|||
yn: 3.1.1
|
||||
optionalDependencies:
|
||||
'@swc/core': 1.15.8(@swc/helpers@0.5.17)
|
||||
optional: true
|
||||
|
||||
ts-node@10.9.2(@swc/core@1.15.8(@swc/helpers@0.5.17))(@types/node@20.19.41)(typescript@7.0.2):
|
||||
dependencies:
|
||||
'@cspotcode/source-map-support': 0.8.1
|
||||
'@tsconfig/node10': 1.0.11
|
||||
'@tsconfig/node12': 1.0.11
|
||||
'@tsconfig/node14': 1.0.3
|
||||
'@tsconfig/node16': 1.0.4
|
||||
'@types/node': 20.19.41
|
||||
acorn: 8.14.0
|
||||
acorn-walk: 8.3.4
|
||||
arg: 4.1.3
|
||||
create-require: 1.1.1
|
||||
diff: 8.0.3
|
||||
make-error: 1.3.6
|
||||
typescript: 7.0.2
|
||||
v8-compile-cache-lib: 3.0.1
|
||||
yn: 3.1.1
|
||||
optionalDependencies:
|
||||
'@swc/core': 1.15.8(@swc/helpers@0.5.17)
|
||||
|
||||
ts-pattern@5.8.0: {}
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
# TypeScript 6 → 7 migration benchmarks
|
||||
|
||||
Generated 2026-07-09T13:19:07.559Z from `scripts/typescript-migration/results/`.
|
||||
Generated 2026-07-14T09:31:26.831Z from `scripts/typescript-migration/results/`.
|
||||
|
||||
| Package | typecheck Δ | build Δ |
|
||||
| --- | --- | --- |
|
||||
|
|
@ -8,10 +8,15 @@ Generated 2026-07-09T13:19:07.559Z from `scripts/typescript-migration/results/`.
|
|||
| `@n8n/ai-node-sdk` | -53.1% | -54.3% |
|
||||
| `@n8n/ai-utilities` | -66.9% | -63.2% |
|
||||
| `@n8n/ai-workflow-builder` | -69.3% | -33.1% |
|
||||
| `@n8n/api-types` | -64.6% | -66.6% |
|
||||
| `@n8n/backend-common` | -57.0% | -54.5% |
|
||||
| `@n8n/backend-network` | -57.0% | -54.9% |
|
||||
| `@n8n/backend-test-utils` | -51.4% | -53.1% |
|
||||
| `@n8n/codemirror-lang` | -36.3% | -31.4% |
|
||||
| `@n8n/codemirror-lang-html` | — | -17.0% |
|
||||
| `@n8n/codemirror-lang-sql` | -42.7% | -39.2% |
|
||||
| `@n8n/instance-ai` | -70.0% | -40.3% |
|
||||
| `@n8n/typeorm` | -37.9% | -68.7% |
|
||||
|
||||
```
|
||||
=== @n8n/agents — median times (Δ vs "before") ===
|
||||
|
|
@ -61,6 +66,54 @@ build:
|
|||
after 2.17s -1078ms (-33.1%)
|
||||
```
|
||||
|
||||
```
|
||||
=== @n8n/api-types — median times (Δ vs "before") ===
|
||||
|
||||
typecheck:
|
||||
before 2.55s
|
||||
after 903ms -1651ms (-64.6%)
|
||||
|
||||
build:
|
||||
before 2.64s
|
||||
after 882ms -1757ms (-66.6%)
|
||||
```
|
||||
|
||||
```
|
||||
=== @n8n/backend-common — median times (Δ vs "before") ===
|
||||
|
||||
typecheck:
|
||||
before 1.34s
|
||||
after 576ms -765ms (-57.0%)
|
||||
|
||||
build:
|
||||
before 1.19s
|
||||
after 541ms -649ms (-54.5%)
|
||||
```
|
||||
|
||||
```
|
||||
=== @n8n/backend-network — median times (Δ vs "before") ===
|
||||
|
||||
typecheck:
|
||||
before 1.52s
|
||||
after 656ms -868ms (-57.0%)
|
||||
|
||||
build:
|
||||
before 1.28s
|
||||
after 576ms -701ms (-54.9%)
|
||||
```
|
||||
|
||||
```
|
||||
=== @n8n/backend-test-utils — median times (Δ vs "before") ===
|
||||
|
||||
typecheck:
|
||||
before 1.54s
|
||||
after 748ms -792ms (-51.4%)
|
||||
|
||||
build:
|
||||
before 1.60s
|
||||
after 751ms -850ms (-53.1%)
|
||||
```
|
||||
|
||||
```
|
||||
=== @n8n/codemirror-lang — median times (Δ vs "before") ===
|
||||
|
||||
|
|
@ -105,3 +158,15 @@ build:
|
|||
after 1.91s -1293ms (-40.3%)
|
||||
```
|
||||
|
||||
```
|
||||
=== @n8n/typeorm — median times (Δ vs "before") ===
|
||||
|
||||
typecheck:
|
||||
before 1.45s
|
||||
after 898ms -547ms (-37.9%)
|
||||
|
||||
build:
|
||||
before 2.84s
|
||||
after 890ms -1949ms (-68.7%)
|
||||
```
|
||||
|
||||
|
|
|
|||
61
scripts/typescript-migration/results/_n8n_api-types.json
Normal file
61
scripts/typescript-migration/results/_n8n_api-types.json
Normal file
|
|
@ -0,0 +1,61 @@
|
|||
{
|
||||
"package": "@n8n/api-types",
|
||||
"runs": {
|
||||
"before": {
|
||||
"label": "before",
|
||||
"tsVersion": "6.0.2",
|
||||
"node": "v24.13.0",
|
||||
"timestamp": "2026-07-14T08:13:33.024Z",
|
||||
"tasks": {
|
||||
"typecheck": {
|
||||
"runsMs": [
|
||||
2731,
|
||||
2554,
|
||||
2526
|
||||
],
|
||||
"min": 2526,
|
||||
"median": 2554,
|
||||
"mean": 2604
|
||||
},
|
||||
"build": {
|
||||
"runsMs": [
|
||||
2513,
|
||||
3418,
|
||||
2639
|
||||
],
|
||||
"min": 2513,
|
||||
"median": 2639,
|
||||
"mean": 2857
|
||||
}
|
||||
}
|
||||
},
|
||||
"after": {
|
||||
"label": "after",
|
||||
"tsVersion": "7.0.2",
|
||||
"node": "v24.13.0",
|
||||
"timestamp": "2026-07-14T08:14:34.864Z",
|
||||
"tasks": {
|
||||
"typecheck": {
|
||||
"runsMs": [
|
||||
903,
|
||||
857,
|
||||
1156
|
||||
],
|
||||
"min": 857,
|
||||
"median": 903,
|
||||
"mean": 972
|
||||
},
|
||||
"build": {
|
||||
"runsMs": [
|
||||
826,
|
||||
927,
|
||||
882
|
||||
],
|
||||
"min": 826,
|
||||
"median": 882,
|
||||
"mean": 878
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,61 @@
|
|||
{
|
||||
"package": "@n8n/backend-common",
|
||||
"runs": {
|
||||
"before": {
|
||||
"label": "before",
|
||||
"tsVersion": "6.0.2",
|
||||
"node": "v24.13.0",
|
||||
"timestamp": "2026-07-14T08:15:35.193Z",
|
||||
"tasks": {
|
||||
"typecheck": {
|
||||
"runsMs": [
|
||||
1352,
|
||||
1323,
|
||||
1341
|
||||
],
|
||||
"min": 1323,
|
||||
"median": 1341,
|
||||
"mean": 1338
|
||||
},
|
||||
"build": {
|
||||
"runsMs": [
|
||||
1190,
|
||||
1227,
|
||||
1190
|
||||
],
|
||||
"min": 1190,
|
||||
"median": 1190,
|
||||
"mean": 1202
|
||||
}
|
||||
}
|
||||
},
|
||||
"after": {
|
||||
"label": "after",
|
||||
"tsVersion": "7.0.2",
|
||||
"node": "v24.13.0",
|
||||
"timestamp": "2026-07-14T08:16:31.011Z",
|
||||
"tasks": {
|
||||
"typecheck": {
|
||||
"runsMs": [
|
||||
629,
|
||||
562,
|
||||
576
|
||||
],
|
||||
"min": 562,
|
||||
"median": 576,
|
||||
"mean": 589
|
||||
},
|
||||
"build": {
|
||||
"runsMs": [
|
||||
572,
|
||||
541,
|
||||
519
|
||||
],
|
||||
"min": 519,
|
||||
"median": 541,
|
||||
"mean": 544
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,61 @@
|
|||
{
|
||||
"package": "@n8n/backend-network",
|
||||
"runs": {
|
||||
"before": {
|
||||
"label": "before",
|
||||
"tsVersion": "6.0.2",
|
||||
"node": "v24.13.0",
|
||||
"timestamp": "2026-07-14T08:17:32.701Z",
|
||||
"tasks": {
|
||||
"typecheck": {
|
||||
"runsMs": [
|
||||
1598,
|
||||
1524,
|
||||
1514
|
||||
],
|
||||
"min": 1514,
|
||||
"median": 1524,
|
||||
"mean": 1545
|
||||
},
|
||||
"build": {
|
||||
"runsMs": [
|
||||
1302,
|
||||
1262,
|
||||
1277
|
||||
],
|
||||
"min": 1262,
|
||||
"median": 1277,
|
||||
"mean": 1281
|
||||
}
|
||||
}
|
||||
},
|
||||
"after": {
|
||||
"label": "after",
|
||||
"tsVersion": "7.0.2",
|
||||
"node": "v24.13.0",
|
||||
"timestamp": "2026-07-14T08:42:01.850Z",
|
||||
"tasks": {
|
||||
"typecheck": {
|
||||
"runsMs": [
|
||||
656,
|
||||
625,
|
||||
659
|
||||
],
|
||||
"min": 625,
|
||||
"median": 656,
|
||||
"mean": 646
|
||||
},
|
||||
"build": {
|
||||
"runsMs": [
|
||||
582,
|
||||
576,
|
||||
575
|
||||
],
|
||||
"min": 575,
|
||||
"median": 576,
|
||||
"mean": 578
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,61 @@
|
|||
{
|
||||
"package": "@n8n/backend-test-utils",
|
||||
"runs": {
|
||||
"before": {
|
||||
"label": "before",
|
||||
"tsVersion": "6.0.2",
|
||||
"node": "v24.13.0",
|
||||
"timestamp": "2026-07-14T09:27:33.022Z",
|
||||
"tasks": {
|
||||
"typecheck": {
|
||||
"runsMs": [
|
||||
1602,
|
||||
1534,
|
||||
1540
|
||||
],
|
||||
"min": 1534,
|
||||
"median": 1540,
|
||||
"mean": 1558
|
||||
},
|
||||
"build": {
|
||||
"runsMs": [
|
||||
1601,
|
||||
1556,
|
||||
1617
|
||||
],
|
||||
"min": 1556,
|
||||
"median": 1601,
|
||||
"mean": 1592
|
||||
}
|
||||
}
|
||||
},
|
||||
"after": {
|
||||
"label": "after",
|
||||
"tsVersion": "7.0.2",
|
||||
"node": "v24.13.0",
|
||||
"timestamp": "2026-07-14T09:28:19.744Z",
|
||||
"tasks": {
|
||||
"typecheck": {
|
||||
"runsMs": [
|
||||
795,
|
||||
748,
|
||||
748
|
||||
],
|
||||
"min": 748,
|
||||
"median": 748,
|
||||
"mean": 764
|
||||
},
|
||||
"build": {
|
||||
"runsMs": [
|
||||
758,
|
||||
751,
|
||||
737
|
||||
],
|
||||
"min": 737,
|
||||
"median": 751,
|
||||
"mean": 749
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
61
scripts/typescript-migration/results/_n8n_typeorm.json
Normal file
61
scripts/typescript-migration/results/_n8n_typeorm.json
Normal file
|
|
@ -0,0 +1,61 @@
|
|||
{
|
||||
"package": "@n8n/typeorm",
|
||||
"runs": {
|
||||
"before": {
|
||||
"label": "before",
|
||||
"tsVersion": "6.0.2",
|
||||
"node": "v24.13.0",
|
||||
"timestamp": "2026-07-14T09:29:28.550Z",
|
||||
"tasks": {
|
||||
"typecheck": {
|
||||
"runsMs": [
|
||||
1624,
|
||||
1408,
|
||||
1445
|
||||
],
|
||||
"min": 1408,
|
||||
"median": 1445,
|
||||
"mean": 1493
|
||||
},
|
||||
"build": {
|
||||
"runsMs": [
|
||||
1963,
|
||||
2839,
|
||||
2851
|
||||
],
|
||||
"min": 1963,
|
||||
"median": 2839,
|
||||
"mean": 2551
|
||||
}
|
||||
}
|
||||
},
|
||||
"after": {
|
||||
"label": "after",
|
||||
"tsVersion": "7.0.2",
|
||||
"node": "v24.13.0",
|
||||
"timestamp": "2026-07-14T09:31:23.564Z",
|
||||
"tasks": {
|
||||
"typecheck": {
|
||||
"runsMs": [
|
||||
1000,
|
||||
898,
|
||||
799
|
||||
],
|
||||
"min": 799,
|
||||
"median": 898,
|
||||
"mean": 899
|
||||
},
|
||||
"build": {
|
||||
"runsMs": [
|
||||
808,
|
||||
890,
|
||||
1087
|
||||
],
|
||||
"min": 808,
|
||||
"median": 890,
|
||||
"mean": 928
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Reference in New Issue
Block a user