You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Getting ._handle through --inspect with chrome developer tools crashes Node.js #16949
If you try to get the value of ._handle through chrome devtools using the --inspect flag Node.js will crash with the error: C:\Program Files\nodejs\node.exe: c:\ws\src\util-inl.h:243: Assertion (object->InternalFieldCount()) > (0)' failed.
For example entering process.stdin._handle or http.createServer().listen()._handle will crash Node.js. If you try to inspect process.stdin or someting else with a .handle and you expand it in devtool it will crash Node.js as well.
Probably the same issue as node-canvas was facing in #15099. We just need to do more of #16860 (in fact #16860 might have already fixed this, will need to confirm).
Edit: Indeed, #16860 fixes this. On current master the following is shown:
Why did this start asserting anyway? Can we go back to the way things were?
In 8.8.1 process.stdin._handle.__proto__.bytesRead simply returns undefined:
8.8.1:
In 8.9.2, it throws.
8.9.2:
This is an issue when, for example, using node-config to configure bunyan; somewhere in the chain node-config clones by accessing properties in the protohttps://github.com/lorenwest/node-config/blob/master/lib/config.js#L1216, this now throws. Catching the error thrown here means that parent !== child and circular structures aren't caught (and that blows the call stack).
To summarise, why can't it just be undefined again?
Activity
TimothyGu commentedon Nov 11, 2017
Probably the same issue as node-canvas was facing in #15099. We just need to do more of #16860 (in fact #16860 might have already fixed this,
will need to confirm).Edit: Indeed, #16860 fixes this. On current master the following is shown:
roderickObrist commentedon Nov 24, 2017
Version: 8.9.1
Platform: Ubuntu 17.10 x86
Command: node --inspect=9222 index.js
I'm not sure if the "me too" is appreciated but I thought I might as well add my stack trace of seemingly the same problem
TimothyGu commentedon Nov 24, 2017
@roderickObrist Upgrading to 8.9.2 (when it is released) should fix this.
jure commentedon Dec 8, 2017
Why did this start asserting anyway? Can we go back to the way things were?
In 8.8.1
process.stdin._handle.__proto__.bytesReadsimply returns undefined:8.8.1:

In 8.9.2, it throws.
8.9.2:

This is an issue when, for example, using node-config to configure bunyan; somewhere in the chain node-config clones by accessing properties in the proto https://github.com/lorenwest/node-config/blob/master/lib/config.js#L1216, this now throws. Catching the error thrown here means that parent !== child and circular structures aren't caught (and that blows the call stack).
To summarise, why can't it just be undefined again?
Edited by @TimothyGu to fix formatting.
TimothyGu commentedon Jan 4, 2018
Has this been fixed in #17665?
TimothyGu commentedon Jan 4, 2018
Actually the OP was fixed in 8.9.2, and #16949 (comment) in #17665. Closing.