-
Notifications
You must be signed in to change notification settings - Fork 9.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'master' of https://github.com/n8n-io/n8n into node-2187-…
…form-node-completion-redirect-page-returns-an-error
- Loading branch information
Showing
477 changed files
with
2,317 additions
and
652 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,6 +22,10 @@ on: | |
required: false | ||
default: false | ||
type: boolean | ||
ignoreTurboCache: | ||
required: false | ||
default: false | ||
type: boolean | ||
secrets: | ||
CODECOV_TOKEN: | ||
description: 'Codecov upload token.' | ||
|
@@ -32,6 +36,7 @@ jobs: | |
name: Unit tests | ||
runs-on: ubuntu-latest | ||
env: | ||
TURBO_FORCE: ${{ inputs.ignoreTurboCache }} | ||
COVERAGE_ENABLED: ${{ inputs.collectCoverage }} | ||
steps: | ||
- uses: actions/[email protected] | ||
|
@@ -73,6 +78,6 @@ jobs: | |
|
||
- name: Upload coverage to Codecov | ||
if: inputs.collectCoverage | ||
uses: codecov/codecov-action@v4.5.0 | ||
uses: codecov/codecov-action@v5.1.2 | ||
with: | ||
token: ${{ secrets.CODECOV_TOKEN }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,60 @@ | ||
codecov: | ||
max_report_age: off | ||
require_ci_to_pass: true | ||
|
||
coverage: | ||
status: | ||
patch: false | ||
project: | ||
default: | ||
threshold: 0.5% | ||
|
||
github_checks: | ||
annotations: false | ||
|
||
flags: | ||
tests: | ||
paths: | ||
- "**" | ||
carryforward: true | ||
|
||
component_management: | ||
default_rules: | ||
statuses: | ||
- type: project | ||
target: auto | ||
branches: | ||
- "!master" | ||
individual_components: | ||
- component_id: backend_packages | ||
name: Backend | ||
paths: | ||
- packages/@n8n/api-types/** | ||
- packages/@n8n/config/** | ||
- packages/@n8n/client-oauth2/** | ||
- packages/@n8n/di/** | ||
- packages/@n8n/imap/** | ||
- packages/@n8n/permissions/** | ||
- packages/@n8n/task-runner/** | ||
- packages/workflow/** | ||
- packages/core/** | ||
- packages/cli/** | ||
- component_id: frontend_packages | ||
name: Frontend | ||
paths: | ||
- packages/@n8n/chat/** | ||
- packages/@n8n/codemirror-lang/** | ||
- packages/design-system/** | ||
- packages/editor-ui/** | ||
- component_id: nodes_packages | ||
name: Nodes | ||
paths: | ||
- packages/node-dev/** | ||
- packages/nodes-base/** | ||
- packages/@n8n/json-schema-to-zod/** | ||
- packages/@n8n/nodes-langchain/** | ||
|
||
ignore: | ||
- (?s:.*/[^\/]*\.spec\.ts.*)\Z | ||
- (?s:.*/[^\/]*\.test\.ts.*)\Z | ||
- (?s:.*/[^\/]*e2e[^\/]*\.ts.*)\Z |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -84,7 +84,6 @@ | |
"ws": ">=8.17.1" | ||
}, | ||
"patchedDependencies": { | ||
"[email protected]": "patches/[email protected]", | ||
"[email protected]": "patches/[email protected]", | ||
"[email protected]": "patches/[email protected]", | ||
"@types/[email protected]": "patches/@[email protected]", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
const sharedOptions = require('@n8n_io/eslint-config/shared'); | ||
|
||
/** @type {import('@types/eslint').ESLint.ConfigData} */ | ||
module.exports = { | ||
extends: ['@n8n_io/eslint-config/base'], | ||
...sharedOptions(__dirname), | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
## @n8n/di | ||
|
||
`@n8n/di` is a dependency injection (DI) container library, based on [`typedi`](https://github.com/typestack/typedi). | ||
|
||
n8n no longer uses `typedi` because: | ||
|
||
- `typedi` is no longer officially maintained | ||
- Need for future-proofing, e.g. stage-3 decorators | ||
- Small enough that it is worth the maintenance burden | ||
- Easier to customize, e.g. to simplify unit tests | ||
|
||
### Usage | ||
|
||
```typescript | ||
// from https://github.com/typestack/typedi/blob/develop/README.md | ||
import { Container, Service } from 'typedi'; | ||
|
||
@Service() | ||
class ExampleInjectedService { | ||
printMessage() { | ||
console.log('I am alive!'); | ||
} | ||
} | ||
|
||
@Service() | ||
class ExampleService { | ||
constructor( | ||
// because we annotated ExampleInjectedService with the @Service() | ||
// decorator TypeDI will automatically inject an instance of | ||
// ExampleInjectedService here when the ExampleService class is requested | ||
// from TypeDI. | ||
public injectedService: ExampleInjectedService | ||
) {} | ||
} | ||
|
||
const serviceInstance = Container.get(ExampleService); | ||
// we request an instance of ExampleService from TypeDI | ||
|
||
serviceInstance.injectedService.printMessage(); | ||
// logs "I am alive!" to the console | ||
``` | ||
|
||
Requires enabling these flags in `tsconfig.json`: | ||
|
||
```json | ||
{ | ||
"compilerOptions": { | ||
"experimentalDecorators": true, | ||
"emitDecoratorMetadata": true | ||
} | ||
} | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
/** @type {import('jest').Config} */ | ||
module.exports = require('../../../jest.config'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
{ | ||
"name": "@n8n/di", | ||
"version": "0.1.0", | ||
"scripts": { | ||
"clean": "rimraf dist .turbo", | ||
"dev": "pnpm watch", | ||
"typecheck": "tsc --noEmit", | ||
"build": "tsc -p tsconfig.build.json", | ||
"format": "biome format --write .", | ||
"format:check": "biome ci .", | ||
"lint": "eslint .", | ||
"lintfix": "eslint . --fix", | ||
"watch": "tsc -p tsconfig.build.json --watch", | ||
"test": "jest", | ||
"test:dev": "jest --watch" | ||
}, | ||
"main": "dist/di.js", | ||
"module": "src/di.ts", | ||
"types": "dist/di.d.ts", | ||
"files": [ | ||
"dist/**/*" | ||
], | ||
"dependencies": { | ||
"reflect-metadata": "catalog:" | ||
} | ||
} |
Oops, something went wrong.