Skip to content

fix: allow all listener to be executed for AsyncEmitter#13079

Merged
tortmayr merged 1 commit intoeclipse-theia:masterfrom
Maddobun:master
Nov 28, 2023
Merged

fix: allow all listener to be executed for AsyncEmitter#13079
tortmayr merged 1 commit intoeclipse-theia:masterfrom
Maddobun:master

Conversation

@Maddobun
Copy link
Contributor

What it does

With AsyncEmitters, if a listener callback does not call event.waitUntil, other listeners that are registered after this one will fail to be called due to early loop termination.

How to test

Register two separate callbacks without waitUntil for FileService.onDidRunUserOperation or any other AsyncEmitter.event and fire an event. Verify that both callbacks are called correctly.

Review checklist

Reminder for reviewers

Copy link
Contributor

@tortmayr tortmayr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Looks good to me.
AsyncEmitters now work as expected and all listener callback are invoked when an event is fired even if some of them don't use Event.waitUntil in the callback.
Nice catch!

@JonasHelming
Copy link
Contributor

@tortmayr Thank you for the reivew, do you want to merge?

@tortmayr tortmayr merged commit 178d74e into eclipse-theia:master Nov 28, 2023
@vince-fugnitto vince-fugnitto added this to the 1.44.0 milestone Nov 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

4 participants