Skip to content

Commit

Permalink
fix(ui): event listeners for filters prematurely cleared
Browse files Browse the repository at this point in the history
  • Loading branch information
psychedelicious committed Sep 24, 2024
1 parent a7ce420 commit b95be09
Showing 1 changed file with 9 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -326,10 +326,6 @@ export class CanvasStateApiModule extends CanvasModuleBase {
return;
}

// event.status is 'failed', 'canceled' or 'completed' - something has gone awry
_clearTimeout();
clearListeners();

if (event.status === 'completed') {
/**
* The invocation_complete event should have been received before the queue item completed event, and the
Expand All @@ -342,9 +338,16 @@ export class CanvasStateApiModule extends CanvasModuleBase {
*
* For now, we'll just log a warning instead of rejecting the promise. This should be super rare anyways.
*/
this.log.warn('Queue item completed without output node completion event');
// reject(new Error('Queue item completed without output node completion event'));
} else if (event.status === 'failed') {
this.log.warn('Queue item completed without output node completion event');
return;
}

// event.status is 'failed', 'canceled' - something has gone awry
_clearTimeout();
clearListeners();

if (event.status === 'failed') {
// We expect the event to have error details, but technically it's possible that it doesn't
const { error_type, error_message, error_traceback } = event;
if (error_type && error_message && error_traceback) {
Expand Down

0 comments on commit b95be09

Please sign in to comment.