eslint-plugin-n8n-nodes-base
Advanced tools
Comparing version 1.16.2 to 1.16.3
@@ -176,3 +176,8 @@ "use strict"; | ||
}; | ||
const N8N_NODE_ERROR_TYPES = ["NodeOperationError", "NodeApiError"]; | ||
const N8N_NODE_ERROR_TYPES = [ | ||
"ApplicationError", | ||
"NodeOperationError", | ||
"NodeApiError", | ||
"TriggerCloseError" | ||
]; | ||
const CREDS_EXEMPTED_FROM_API_SUFFIX = [ | ||
@@ -179,0 +184,0 @@ "Amqp", |
@@ -32,3 +32,3 @@ "use strict"; | ||
docs: { | ||
description: "The `execute()` method in a node may only throw `NodeApiError` for failed API requests and `NodeOperationError` for internal errors, not the built-in `Error`. Refer to [`NodeErrors.ts`](https://github.com/n8n-io/n8n/blob/master/packages/workflow/src/NodeErrors.ts).", | ||
description: "The `execute()` method in a node may only throw `ApplicationError`, NodeApiError`, `NodeOperationError`, or `TriggerCloseError`.", | ||
recommended: "strict" | ||
@@ -38,3 +38,3 @@ }, | ||
messages: { | ||
useProperError: "Use `NodeApiError` or `NodeOperationError` [non-autofixable]" | ||
useProperError: "Use `ApplicationError`, NodeApiError`, `NodeOperationError`, or `TriggerCloseError` [non-autofixable]" | ||
} | ||
@@ -41,0 +41,0 @@ }, |
@@ -36,6 +36,5 @@ "use strict"; | ||
}, | ||
fixable: "code", | ||
schema: [], | ||
messages: { | ||
sortItems: "Alphabetize by 'name'. Order: {{ displayOrder }} [autofixable]" | ||
sortItems: "Alphabetize by 'name'. Order: {{ displayOrder }} [non-autofixable]" | ||
} | ||
@@ -63,4 +62,2 @@ }, | ||
)) { | ||
const baseIndentation = import_utils.utils.getBaseIndentationForOption(options); | ||
const sorted = import_utils.utils.formatItems(sortedOptions, baseIndentation); | ||
const displayOrder = import_utils.utils.toDisplayOrderForCollection(sortedOptions); | ||
@@ -70,4 +67,3 @@ context.report({ | ||
node: options.ast, | ||
data: { displayOrder }, | ||
fix: (fixer) => fixer.replaceText(options.ast, `options: ${sorted}`) | ||
data: { displayOrder } | ||
}); | ||
@@ -74,0 +70,0 @@ } |
{ | ||
"name": "eslint-plugin-n8n-nodes-base", | ||
"version": "1.16.2", | ||
"version": "1.16.3", | ||
"main": "dist/index.js", | ||
@@ -5,0 +5,0 @@ "engines": { |
@@ -124,7 +124,7 @@ # eslint-plugin-n8n-nodes-base | ||
| [node-execute-block-missing-continue-on-fail](docs/rules/node-execute-block-missing-continue-on-fail.md) | The `execute()` method in a node must implement `continueOnFail` in a try-catch block. | No | | ||
| [node-execute-block-wrong-error-thrown](docs/rules/node-execute-block-wrong-error-thrown.md) | The `execute()` method in a node may only throw `NodeApiError` for failed API requests and `NodeOperationError` for internal errors, not the built-in `Error`. Refer to [`NodeErrors.ts`](https://github.com/n8n-io/n8n/blob/master/packages/workflow/src/NodeErrors.ts). | No | | ||
| [node-execute-block-wrong-error-thrown](docs/rules/node-execute-block-wrong-error-thrown.md) | The `execute()` method in a node may only throw `ApplicationError`, NodeApiError`, `NodeOperationError`, or `TriggerCloseError`. | No | | ||
| [node-filename-against-convention](docs/rules/node-filename-against-convention.md) | `name` in node class description must match the node filename without the `.node.ts` suffix. Example: If `description.name` is `Test`, then filename must be `Test.node.ts`. Version suffix in filename (e.g. `-V2`) is disregarded. | No | | ||
| [node-param-array-type-assertion](docs/rules/node-param-array-type-assertion.md) | Array of node parameters must be typed, not type-asserted. | Yes | | ||
| [node-param-collection-type-item-required](docs/rules/node-param-collection-type-item-required.md) | Items in collection-type node parameter must not have a `required` property. | Yes | | ||
| [node-param-collection-type-unsorted-items](docs/rules/node-param-collection-type-unsorted-items.md) | Items in collection-type node parameter must be alphabetized by `name` if five or more than five. | Yes | | ||
| [node-param-collection-type-unsorted-items](docs/rules/node-param-collection-type-unsorted-items.md) | Items in collection-type node parameter must be alphabetized by `name` if five or more than five. | No | | ||
| [node-param-color-type-unused](docs/rules/node-param-color-type-unused.md) | `string`-type color-related node parameter must be `color`-type. | Yes | | ||
@@ -131,0 +131,0 @@ | [node-param-default-missing](docs/rules/node-param-default-missing.md) | `default` must be present in a node parameter, except in node parameters under `modes`. | Yes | |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
12219
515397