Commit Graph
4 Commits
Author SHA1 Message Date
Will Schurman e958ff848c Update eslint-config-universe to 4.0.0 (#2396) 2020-07-24 15:25:32 -07:00
Evan Bacon 5c3339592c [dev-tools] Upgrade dev-tools (#1633)
* Migrate dev-tools to typescript

* fix scripts

* fix tests

* upgrade to next.js v8
2020-03-04 17:15:58 -08:00
Ville Immonen d23bf45ab8 fix(dev-tools): fix an EventEmitter memory leak (#1530)
Fix a memory leak resulting in warnings like this to be generated by
Node:
```
(node:14054) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 ADDED listeners added to [Issues]. Use emitter.setMaxListeners() to increase limit
(node:14054) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 UPDATED listeners added to [Issues]. Use emitter.setMaxListeners() to increase limit
(node:14054) MaxListenersExceededWarning: Possible EventEmitter memory leak detected. 11 DELETED listeners added to [Issues]. Use emitter.setMaxListeners() to increase limit
```

To reproduce the bug I refreshed the browser tab with Dev Tools in it
10+ times. After this, the warning shown above was printed in the
terminal.

The underlying cause was that each time the browser subscribed to the
logs, `addListener` was called in `eventEmitterToAsyncIterator`, but
the corresponding `removeListener` was never called.

There was code wrapping async iterators in the Dev Tools server, which
did not implement the `return()` and `throw()` methods of the async
iterator. For this reason, whenever a client disconnected, the async
iterator was not cleaned up.
2020-02-10 18:01:06 +02:00
Ville Immonen 5c1ca0be51 Move all packages to packages/ folder 2018-08-24 00:02:43 +03:00