feat: Do not show errors not processed by n8n (no-changelog) (#9598)

Co-authored-by: कारतोफ्फेलस्क्रिप्ट™ <aditya@netroy.in>
This commit is contained in:
Michael Kret
2024-06-20 08:45:00 +03:00
committed by GitHub
parent 4740162232
commit b7aea957b8
317 changed files with 471 additions and 454 deletions

View File

@@ -114,7 +114,7 @@ export async function conversationalAgentExecute(
} catch (error) {
throwIfToolSchema(this, error);
if (this.continueOnFail()) {
if (this.continueOnFail(error)) {
returnData.push({ json: { error: error.message }, pairedItem: { item: itemIndex } });
continue;
}

View File

@@ -116,7 +116,7 @@ export async function openAiFunctionsAgentExecute(
returnData.push({ json: response });
} catch (error) {
if (this.continueOnFail()) {
if (this.continueOnFail(error)) {
returnData.push({ json: { error: error.message }, pairedItem: { item: itemIndex } });
continue;
}

View File

@@ -93,7 +93,7 @@ export async function planAndExecuteAgentExecute(
returnData.push({ json: response });
} catch (error) {
throwIfToolSchema(this, error);
if (this.continueOnFail()) {
if (this.continueOnFail(error)) {
returnData.push({ json: { error: error.message }, pairedItem: { item: itemIndex } });
continue;
}

View File

@@ -114,7 +114,7 @@ export async function reActAgentAgentExecute(
returnData.push({ json: response });
} catch (error) {
throwIfToolSchema(this, error);
if (this.continueOnFail()) {
if (this.continueOnFail(error)) {
returnData.push({ json: { error: error.message }, pairedItem: { item: itemIndex } });
continue;
}

View File

@@ -142,7 +142,7 @@ export async function sqlAgentAgentExecute(
returnData.push({ json: response });
} catch (error) {
if (this.continueOnFail()) {
if (this.continueOnFail(error)) {
returnData.push({ json: { error: error.message }, pairedItem: { item: i } });
continue;
}

View File

@@ -181,11 +181,8 @@ export async function toolsAgentExecute(this: IExecuteFunctions): Promise<INodeE
),
});
} catch (error) {
if (this.continueOnFail()) {
returnData.push({
json: { error: error?.message },
pairedItem: { item: itemIndex },
});
if (this.continueOnFail(error)) {
returnData.push({ json: { error: error.message }, pairedItem: { item: itemIndex } });
continue;
}