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

Use emitter.setmaxlisteners() to increase limit #110

Closed
cinnamon-bun opened this issue May 22, 2019 · 6 comments
Closed

Use emitter.setmaxlisteners() to increase limit #110

cinnamon-bun opened this issue May 22, 2019 · 6 comments

Comments

@cinnamon-bun
Copy link
Member

cinnamon-bun commented May 22, 2019

This warning gets printed to the screen occasionally, messing up the display.

Use emitter.setmaxlisteners() to increase limit

Node v10.8.0 on OSX 10.11.6. This is not the latest version of Node.

Discussion about hiding warnings in node here, but with no good solution: nodejs/node#10802

@hackergrrl
Copy link
Member

One workaround for now is to tack 2> /dev/null on the end of your command when you run cabal, since the warnings are written to stderr.

@hackergrrl
Copy link
Member

If it's the same output as me, the full warning text is

MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 update listeners added. Use emitter.setMaxListeners() to increase limit

So we could be looking for emissions of the 'update' event.

@hackergrrl
Copy link
Member

I think the culprit is probably here, where we have a listener inside of a listener:

https://github.com/cabal-club/cabal-cli/blob/master/neat-screen.js#L237

@hackergrrl
Copy link
Member

I think I've fixed it. @cinnamon-bun can you try cabal 6.3.4?

@cinnamon-bun
Copy link
Member Author

@noffle The error message doesn't appear every single time so it's hard to test, but I'm not seeing it now! 🌟

@cblgh
Copy link
Member

cblgh commented Jun 29, 2019

🎈 🍄

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

No branches or pull requests

3 participants