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

emitter.setMaxListeners() #354

Open
drgould opened this issue Jul 14, 2014 · 5 comments
Open

emitter.setMaxListeners() #354

drgould opened this issue Jul 14, 2014 · 5 comments

Comments

@drgould
Copy link

drgould commented Jul 14, 2014

Just thought I'd drop this here since it took me FOREVER to figure this out.

If you're getting these errors:

warning: possible EventEmitter memory leak detected. 11 listeners added. Use emitter.setMaxListeners() to increase limit.

just set the maxListeners option in your watch config to something large. Like this:

watch: {
  options: {
    maxListeners: 99,
    ...
  }
}

Hope this helps.

@jamesplease
Copy link
Member

Thanks, @drgould! @shama, what do you think about processing this warning in the task to tell people to set maxListeners instead of emitter.setMaxListeners()?

@shama
Copy link
Member

shama commented Jul 14, 2014

Sounds good to me.

@rubensbiork
Copy link

if (process.setMaxListeners) {
process.setMaxListeners(10000);
}

@arifulhb
Copy link

was searching for this as Smeagol was searching for his precious.

@Josufst
Copy link

Josufst commented Aug 23, 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

6 participants