Skip to content

Commit

Permalink
fix(core): Do not display error when stopping jobless execution in qu…
Browse files Browse the repository at this point in the history
…eue mode (#8007)

No need to surface error to user when stopping a job no longer in queue.

https://linear.app/n8n/issue/PAY-1104
  • Loading branch information
ivov committed Dec 19, 2023
1 parent 9d22c7a commit 8e6b951
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/cli/src/Server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ import type {
IExecutionsSummary,
IN8nUISettings,
} from 'n8n-workflow';
import { ApplicationError, jsonParse } from 'n8n-workflow';
import { jsonParse } from 'n8n-workflow';

// @ts-ignore
import timezones from 'google-timezones-json';
Expand Down Expand Up @@ -681,8 +681,8 @@ export class Server extends AbstractServer {
const job = currentJobs.find((job) => job.data.executionId === req.params.id);

if (!job) {
throw new ApplicationError('Could not stop job because it is no longer in queue.', {
extra: { jobId: req.params.id },
this.logger.debug('Could not stop job because it is no longer in queue', {
jobId: req.params.id,
});
} else {
await queue.stopJob(job);
Expand Down

0 comments on commit 8e6b951

Please sign in to comment.