mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-21 11:49:59 +00:00
build: Upgrade some of the backend dev-tooling (no-changelog) (#4589)
* upgrade ts-node * move tslint and typescript to a single place * source-map-support should be loaded in the `n8n` bin script, and not in core * upgrade jest * Support only node.js 14, 16, or 18
This commit is contained in:
committed by
GitHub
parent
edebad1a89
commit
0148631d28
@@ -32,7 +32,7 @@ export interface IProcessMessage {
|
||||
|
||||
export interface IExecuteFunctions extends IExecuteFunctionsBase {
|
||||
helpers: {
|
||||
httpRequest(requestOptions: IHttpRequestOptions): Promise<any>; // tslint:disable-line:no-any
|
||||
httpRequest(requestOptions: IHttpRequestOptions): Promise<any>;
|
||||
prepareBinaryData(
|
||||
binaryData: Buffer,
|
||||
filePath?: string,
|
||||
@@ -40,7 +40,7 @@ export interface IExecuteFunctions extends IExecuteFunctionsBase {
|
||||
): Promise<IBinaryData>;
|
||||
getBinaryDataBuffer(itemIndex: number, propertyName: string): Promise<Buffer>;
|
||||
setBinaryDataBuffer(data: IBinaryData, binaryData: Buffer): Promise<IBinaryData>;
|
||||
request: (uriOrObject: string | IDataObject | any, options?: IDataObject) => Promise<any>; // tslint:disable-line:no-any
|
||||
request: (uriOrObject: string | IDataObject | any, options?: IDataObject) => Promise<any>;
|
||||
requestWithAuthentication(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
@@ -52,12 +52,12 @@ export interface IExecuteFunctions extends IExecuteFunctionsBase {
|
||||
credentialsType: string,
|
||||
requestOptions: OptionsWithUri | RequestPromiseOptions,
|
||||
oAuth2Options?: IOAuth2Options,
|
||||
): Promise<any>; // tslint:disable-line:no-any
|
||||
): Promise<any>;
|
||||
requestOAuth1(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
requestOptions: OptionsWithUrl | RequestPromiseOptions,
|
||||
): Promise<any>; // tslint:disable-line:no-any
|
||||
): Promise<any>;
|
||||
returnJsonArray(jsonData: IDataObject | IDataObject[]): INodeExecutionData[];
|
||||
normalizeItems(items: INodeExecutionData | INodeExecutionData[]): INodeExecutionData[];
|
||||
httpRequestWithAuthentication(
|
||||
@@ -76,13 +76,13 @@ export interface IExecuteSingleFunctions extends IExecuteSingleFunctionsBase {
|
||||
helpers: {
|
||||
getBinaryDataBuffer(propertyName: string, inputIndex?: number): Promise<Buffer>;
|
||||
setBinaryDataBuffer(data: IBinaryData, binaryData: Buffer): Promise<IBinaryData>;
|
||||
httpRequest(requestOptions: IHttpRequestOptions): Promise<any>; // tslint:disable-line:no-any
|
||||
httpRequest(requestOptions: IHttpRequestOptions): Promise<any>;
|
||||
prepareBinaryData(
|
||||
binaryData: Buffer,
|
||||
filePath?: string,
|
||||
mimeType?: string,
|
||||
): Promise<IBinaryData>;
|
||||
request: (uriOrObject: string | IDataObject | any, options?: IDataObject) => Promise<any>; // tslint:disable-line:no-any
|
||||
request: (uriOrObject: string | IDataObject | any, options?: IDataObject) => Promise<any>;
|
||||
requestWithAuthentication(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
@@ -94,12 +94,12 @@ export interface IExecuteSingleFunctions extends IExecuteSingleFunctionsBase {
|
||||
credentialsType: string,
|
||||
requestOptions: OptionsWithUri | RequestPromiseOptions,
|
||||
oAuth2Options?: IOAuth2Options,
|
||||
): Promise<any>; // tslint:disable-line:no-any
|
||||
): Promise<any>;
|
||||
requestOAuth1(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
requestOptions: OptionsWithUrl | RequestPromiseOptions,
|
||||
): Promise<any>; // tslint:disable-line:no-any
|
||||
): Promise<any>;
|
||||
httpRequestWithAuthentication(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
@@ -110,13 +110,13 @@ export interface IExecuteSingleFunctions extends IExecuteSingleFunctionsBase {
|
||||
|
||||
export interface IPollFunctions extends IPollFunctionsBase {
|
||||
helpers: {
|
||||
httpRequest(requestOptions: IHttpRequestOptions): Promise<any>; // tslint:disable-line:no-any
|
||||
httpRequest(requestOptions: IHttpRequestOptions): Promise<any>;
|
||||
prepareBinaryData(
|
||||
binaryData: Buffer,
|
||||
filePath?: string,
|
||||
mimeType?: string,
|
||||
): Promise<IBinaryData>;
|
||||
request: (uriOrObject: string | IDataObject | any, options?: IDataObject) => Promise<any>; // tslint:disable-line:no-any
|
||||
request: (uriOrObject: string | IDataObject | any, options?: IDataObject) => Promise<any>;
|
||||
requestWithAuthentication(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
@@ -128,12 +128,12 @@ export interface IPollFunctions extends IPollFunctionsBase {
|
||||
credentialsType: string,
|
||||
requestOptions: OptionsWithUri | RequestPromiseOptions,
|
||||
oAuth2Options?: IOAuth2Options,
|
||||
): Promise<any>; // tslint:disable-line:no-any
|
||||
): Promise<any>;
|
||||
requestOAuth1(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
requestOptions: OptionsWithUrl | RequestPromiseOptions,
|
||||
): Promise<any>; // tslint:disable-line:no-any
|
||||
): Promise<any>;
|
||||
returnJsonArray(jsonData: IDataObject | IDataObject[]): INodeExecutionData[];
|
||||
httpRequestWithAuthentication(
|
||||
this: IAllExecuteFunctions,
|
||||
@@ -149,13 +149,13 @@ export interface IResponseError extends Error {
|
||||
|
||||
export interface ITriggerFunctions extends ITriggerFunctionsBase {
|
||||
helpers: {
|
||||
httpRequest(requestOptions: IHttpRequestOptions): Promise<any>; // tslint:disable-line:no-any
|
||||
httpRequest(requestOptions: IHttpRequestOptions): Promise<any>;
|
||||
prepareBinaryData(
|
||||
binaryData: Buffer,
|
||||
filePath?: string,
|
||||
mimeType?: string,
|
||||
): Promise<IBinaryData>;
|
||||
request: (uriOrObject: string | IDataObject | any, options?: IDataObject) => Promise<any>; // tslint:disable-line:no-any
|
||||
request: (uriOrObject: string | IDataObject | any, options?: IDataObject) => Promise<any>;
|
||||
requestWithAuthentication(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
@@ -167,12 +167,12 @@ export interface ITriggerFunctions extends ITriggerFunctionsBase {
|
||||
credentialsType: string,
|
||||
requestOptions: OptionsWithUri | RequestPromiseOptions,
|
||||
oAuth2Options?: IOAuth2Options,
|
||||
): Promise<any>; // tslint:disable-line:no-any
|
||||
): Promise<any>;
|
||||
requestOAuth1(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
requestOptions: OptionsWithUrl | RequestPromiseOptions,
|
||||
): Promise<any>; // tslint:disable-line:no-any
|
||||
): Promise<any>;
|
||||
returnJsonArray(jsonData: IDataObject | IDataObject[]): INodeExecutionData[];
|
||||
httpRequestWithAuthentication(
|
||||
this: IAllExecuteFunctions,
|
||||
@@ -190,8 +190,8 @@ export interface IUserSettings {
|
||||
|
||||
export interface ILoadOptionsFunctions extends ILoadOptionsFunctionsBase {
|
||||
helpers: {
|
||||
httpRequest(requestOptions: IHttpRequestOptions): Promise<any>; // tslint:disable-line:no-any
|
||||
request?: (uriOrObject: string | IDataObject | any, options?: IDataObject) => Promise<any>; // tslint:disable-line:no-any
|
||||
httpRequest(requestOptions: IHttpRequestOptions): Promise<any>;
|
||||
request?: (uriOrObject: string | IDataObject | any, options?: IDataObject) => Promise<any>;
|
||||
requestWithAuthentication(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
@@ -203,12 +203,12 @@ export interface ILoadOptionsFunctions extends ILoadOptionsFunctionsBase {
|
||||
credentialsType: string,
|
||||
requestOptions: OptionsWithUri | RequestPromiseOptions,
|
||||
oAuth2Options?: IOAuth2Options,
|
||||
) => Promise<any>; // tslint:disable-line:no-any
|
||||
) => Promise<any>;
|
||||
requestOAuth1?(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
requestOptions: OptionsWithUrl | RequestPromiseOptions,
|
||||
): Promise<any>; // tslint:disable-line:no-any
|
||||
): Promise<any>;
|
||||
httpRequestWithAuthentication(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
@@ -225,8 +225,8 @@ export interface ICredentialTestFunctions extends ICredentialTestFunctionsBase {
|
||||
|
||||
export interface IHookFunctions extends IHookFunctionsBase {
|
||||
helpers: {
|
||||
httpRequest(requestOptions: IHttpRequestOptions): Promise<any>; // tslint:disable-line:no-any
|
||||
request: (uriOrObject: string | IDataObject | any, options?: IDataObject) => Promise<any>; // tslint:disable-line:no-any
|
||||
httpRequest(requestOptions: IHttpRequestOptions): Promise<any>;
|
||||
request: (uriOrObject: string | IDataObject | any, options?: IDataObject) => Promise<any>;
|
||||
requestWithAuthentication(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
@@ -238,12 +238,12 @@ export interface IHookFunctions extends IHookFunctionsBase {
|
||||
credentialsType: string,
|
||||
requestOptions: OptionsWithUri | RequestPromiseOptions,
|
||||
oAuth2Options?: IOAuth2Options,
|
||||
): Promise<any>; // tslint:disable-line:no-any
|
||||
): Promise<any>;
|
||||
requestOAuth1(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
requestOptions: OptionsWithUrl | RequestPromiseOptions,
|
||||
): Promise<any>; // tslint:disable-line:no-any
|
||||
): Promise<any>;
|
||||
httpRequestWithAuthentication(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
@@ -254,13 +254,13 @@ export interface IHookFunctions extends IHookFunctionsBase {
|
||||
|
||||
export interface IWebhookFunctions extends IWebhookFunctionsBase {
|
||||
helpers: {
|
||||
httpRequest(requestOptions: IHttpRequestOptions): Promise<any>; // tslint:disable-line:no-any
|
||||
httpRequest(requestOptions: IHttpRequestOptions): Promise<any>;
|
||||
prepareBinaryData(
|
||||
binaryData: Buffer,
|
||||
filePath?: string,
|
||||
mimeType?: string,
|
||||
): Promise<IBinaryData>;
|
||||
request: (uriOrObject: string | IDataObject | any, options?: IDataObject) => Promise<any>; // tslint:disable-line:no-any
|
||||
request: (uriOrObject: string | IDataObject | any, options?: IDataObject) => Promise<any>;
|
||||
requestWithAuthentication(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
@@ -272,12 +272,12 @@ export interface IWebhookFunctions extends IWebhookFunctionsBase {
|
||||
credentialsType: string,
|
||||
requestOptions: OptionsWithUri | RequestPromiseOptions,
|
||||
oAuth2Options?: IOAuth2Options,
|
||||
): Promise<any>; // tslint:disable-line:no-any
|
||||
): Promise<any>;
|
||||
requestOAuth1(
|
||||
this: IAllExecuteFunctions,
|
||||
credentialsType: string,
|
||||
requestOptions: OptionsWithUrl | RequestPromiseOptions,
|
||||
): Promise<any>; // tslint:disable-line:no-any
|
||||
): Promise<any>;
|
||||
returnJsonArray(jsonData: IDataObject | IDataObject[]): INodeExecutionData[];
|
||||
httpRequestWithAuthentication(
|
||||
this: IAllExecuteFunctions,
|
||||
|
||||
@@ -559,7 +559,6 @@ function digestAuthAxiosConfig(
|
||||
async function proxyRequestToAxios(
|
||||
uriOrObject: string | IDataObject,
|
||||
options?: IDataObject,
|
||||
// tslint:disable-next-line:no-any
|
||||
): Promise<any> {
|
||||
// Check if there's a better way of getting this config here
|
||||
if (process.env.N8N_USE_DEPRECATED_REQUEST_LIB) {
|
||||
|
||||
@@ -292,7 +292,6 @@ export class WorkflowExecute {
|
||||
*/
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
async executeHook(hookName: string, parameters: any[]): Promise<void> {
|
||||
// tslint:disable-line:no-any
|
||||
if (this.additionalData.hooks === undefined) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -1,12 +1,6 @@
|
||||
import * as NodeExecuteFunctions from './NodeExecuteFunctions';
|
||||
import * as UserSettings from './UserSettings';
|
||||
|
||||
try {
|
||||
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access, @typescript-eslint/no-unsafe-call, import/no-extraneous-dependencies, global-require, @typescript-eslint/no-var-requires
|
||||
require('source-map-support').install();
|
||||
// eslint-disable-next-line no-empty
|
||||
} catch (error) {}
|
||||
|
||||
export * from './ActiveWorkflows';
|
||||
export * from './ActiveWebhooks';
|
||||
export * from './BinaryDataManager';
|
||||
|
||||
Reference in New Issue
Block a user