Repository navigation
12.9.0 MaxListenersExceededWarning #29239
Description
Activity
Do you have a minimal code example to reproduce this?
Sorry, I don't :/ I just noticed this with a simple npm install.
Simple to reproduce:
npm i -g grunt-cli (node:31849) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:31849) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:31849) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:31849) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:31849) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:31849) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:31849) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:31849) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit /home/ex1st/.nvm/versions/node/v12.9.0/bin/grunt -> /home/ex1st/.nvm/versions/node/v12.9.0/lib/node_modules/grunt-cli/bin/grunt + grunt-cli@1.3.2 updated 1 package in 3.342sReacted by Marcio dos Santos Amorim and Nicholas WesterhausenI can reproduce.
Here's the stack trace:
(node:1445) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit at _addListener (events.js:267:17) at TLSSocket.addListener (events.js:283:10) at TLSSocket.Readable.on (_stream_readable.js:863:35) at tickOnSocket (_http_client.js:670:10) at onSocketNT (_http_client.js:717:5) at processTicksAndRejections (internal/process/task_queues.js:77:11)- addedhttpIssues and PRs related to the http subsystem.Issues and PRs related to the http subsystem.windowsIssues and PRs related to the Windows platform.Issues and PRs related to the Windows platform.
on Aug 21, 2019 Hi @targos, I've caught same warning on Linux.
Reacted by Marco Massarotto, Aleksei Gorb, Joshua V Sherman, Scott Tadman, Benjamin DANIEL, Davi Figueiredo, Zach Zodkoy, mipesom, Subrata Aich, codemaster101 and 2 more- removedwindowsIssues and PRs related to the Windows platform.Issues and PRs related to the Windows platform.
on Aug 21, 2019 I suspect I know what it is. My computer broke so I need to sort that out. Will have a PR later today.
@targos let’s do a revert with fast-track and get 12.9.1 out of the door asap :/.
Reacted by Robert Nagy, Trivikram Kamat, Joshua V Sherman, Jiawen Geng, David J. M. Karlsen, Bernardo Revelles, Rein and roman- added a commit that references this issue
on Aug 21, 2019 If I had a Windows binary I could :)
25 remaining items
juarezfrench commented
on Aug 25, 2019 on Aug 25, 2019 · Hidden as off-topicshow commentMore actions12.9.1 release which fixes this is being prepared and should be out in the next 36 hours or so (although that's merely a prediction based on passed experience, not a promise/guarantee).
Reproducing the FAQ above for visibility:
What version/OS/etc. does this affect?
Node.js 12.9.0, all environments Windows, macOS, Linux, Docker, yarn, npm, you-name-it, if it's using Node.js 12.9.0, it's affected.
What are the ramifications of this bug?
If you're hitting it through
npmoryarn, probably nothing other than seeing the warnings. Your package installations should work just fine.I am hitting this same bug on this or that platform using this or that tool.
Thanks. Please don't post "this is affecting me too" comments and please don't be offended if your comment gets hidden as "off topic" to try to keep this issue as usable as possible. As noted above, this affects everything on Node.js 12.9.0.
When is a fix coming out?
Probably some time on August 27 (UTC).
I'm hitting this bug in some other version than Node.js 12.9.0.
Probably not, but you may have a different issue triggering the same warning. Open a separate issue in https://github.com/nodejs/help or (if you are reasonably certain the issue is with Node.js itself) in this repository.
Reacted by Mardari Grigore, Levi Durfee, Robbert Korving, Guilherme Schatz Rodrigues, Christhopher Lion, Matheus Alcantara, Francisco Magalhães, Pedro Costa, Zoltan Kochan, ExE Boss and 12 moreReacted by Rick Bowen, Silvermind, Aronne Brivio, Rintaro Hasegawa, Samson Endale, Matheus Geres and x11joeReacted by ExE Boss, XhmikosR, Jarek Lipski and Matheus Geresv12.9.1 is out, thanks for the fix!
Reacted by Ashley Wilson, ExE Boss, 翎栋, Benjamin DANIEL, Ali Imron, Silvermind, Marco Arduini, Jarek Lipski, Levi Durfee, Rintaro Hasegawa and 11 moreReacted by ExE Boss, escalonn, Rick Bowen, Brandon Doran, Kelly Fox, Silvermind, Marco Arduini, Aronne Brivio, Levi Durfee, Oliver Jessner and 5 moreHey guys
I just wanna confirm that I had the same bug a couple of hours ago with a message like this
(node:15310) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:15310) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:15310) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:15310) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:15310) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:15310) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:15310) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:15310) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:15310) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit (node:15310) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 drain listeners added to [TLSSocket]. Use emitter.setMaxListeners() to increase limit npm notice created a lockfile as package-lock.json. You should commit this file. npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules/fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"}) added 1004 packages from 485 contributors and audited 17139 packages in 35.296s found 0 vulnerabilitiesI was on
Linux Mint 19.1andNode 12.9.0-1nodesource1I have updated my nodejs to
12.9.1-1nodesource1and run the same install and everything is working great with noMaxListenersExceededWarning🥇
Reacted by ZeBobo5, Mauricio Sánchez, Pawel Biernacki, Kevin Bost and mahcliReacted by Eingress Ltd@SVendittelli: If you are getting this on v10 please open a separate issue. This specific issue was cause by a regression introduced in 12.9.0.
Reacted by Sam Vendittelli and ExE BossIf you are seeing this message and running Node,js 12.9.0, update to the most recent 12.x.
If you are seeing this message with some other version of Node.js, it is not this issue. It is most likely that you have a bug in your code (or there's a bug in one of your dependencies). Or there's no bug but your code is creating a lot of listeners. Or maybe it's a different bug in Node.js. Open an issue in https://github.com/nodejs/help. (Or if you are very certain the bug is in Node.js itself, open an issue in this issue tracker.)
I am going to lock this issue.
- locked as resolved and limited conversation to collaborators
on Sep 20, 2019
Started to happen after updating to 12.9.0. I'm getting:
even when doing
npm iin a project:Going back to 12.8.1 and the warnings are gone.