Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

close keypress stream when rl close #835

Merged
merged 1 commit into from
Aug 11, 2019
Merged

Conversation

pgherveou
Copy link

In our CLI we capture SIGINT events and cancel any active prompt when this happens.
I noticed that when we do that, Inquirer leak the prompts,
This happens because rl event streams (created when calling observe(this.rl)) never complete, thus causing underlying streams not to complete as well.

@SBoudrias
Copy link
Owner

Good find thanks!

@SBoudrias SBoudrias merged commit 7bcb7d3 into SBoudrias:master Aug 11, 2019
@pgherveou
Copy link
Author

Thanks Simon! Would you mind publishing the patch on npm?

jdoyle65 pushed a commit to jdoyle65/Inquirer.js that referenced this pull request Jan 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants