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

EventEmitter possible eventemitter memory leak #74

Closed
jihoonl opened this issue Apr 4, 2014 · 1 comment
Closed

EventEmitter possible eventemitter memory leak #74

jihoonl opened this issue Apr 4, 2014 · 1 comment
Labels

Comments

@jihoonl
Copy link
Member

jihoonl commented Apr 4, 2014

Warning while mochatest.

  ROS
    callOnConnection
(node) warning: possible EventEmitter memory leak detected. 11 listeners added. Use emitter.setMaxListeners() to increase limit.
Trace
    at EventEmitter.on (/home/jihoonl/research/node/roslibjs/node_modules/eventemitter2/lib/eventemitter2.js:391:19)
    at Context.<anonymous> (/home/jihoonl/research/node/roslibjs/test/ros.test.js:14:22)
    at callFn (/home/jihoonl/research/node/roslibjs/node_modules/grunt-mocha-test/node_modules/mocha/lib/runnable.js:223:21)
    at Test.Runnable.run (/home/jihoonl/research/node/roslibjs/node_modules/grunt-mocha-test/node_modules/mocha/lib/runnable.js:216:7)
    at Runner.runTest (/home/jihoonl/research/node/roslibjs/node_modules/grunt-mocha-test/node_modules/mocha/lib/runner.js:374:10)
    at /home/jihoonl/research/node/roslibjs/node_modules/grunt-mocha-test/node_modules/mocha/lib/runner.js:452:12
    at next (/home/jihoonl/research/node/roslibjs/node_modules/grunt-mocha-test/node_modules/mocha/lib/runner.js:299:14)
    at /home/jihoonl/research/node/roslibjs/node_modules/grunt-mocha-test/node_modules/mocha/lib/runner.js:309:7
    at next (/home/jihoonl/research/node/roslibjs/node_modules/grunt-mocha-test/node_modules/mocha/lib/runner.js:247:23)
    at Object._onImmediate (/home/jihoonl/research/node/roslibjs/node_modules/grunt-mocha-test/node_modules/mocha/lib/runner.js:276:5)
    at processImmediate [as _immediateCallback] (timers.js:330:15)
      ✓ should accept more than EventEmitter2's default listeners 
@syrnick
Copy link

syrnick commented May 31, 2014

The test subscribes 50 times and the warning triggers at 11. The warning is expected given what the test is doing. The fix for the test is to silence console output.

@syrnick syrnick closed this as completed Jul 8, 2014
k-aguete pushed a commit to k-aguete/roslibjs that referenced this issue Oct 21, 2022
MarkerClient: Subscribe to MarkerArray topic
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants