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
ENETUNREACH not handled for http.request in 7.10.0 #12841
As the title says that error is not delivered via the returned event emitter, an exception is thrown instead. Other errors are properly handled, e.g., using {port: 0} which causes ECONNREFUSED. Also the net subsystem doesn't seem to be affected when I try with net.connect using the same options.
$ nvm use 7.10.0Now using node v7.10.0
$ node issue.jsevents.js:163 throw er; // Unhandled 'error' event ^Error: connect ENETUNREACH 255.255.255.255:80 - Local (0.0.0.0:0) at Object.exports._errnoException (util.js:1050:11) at exports._exceptionWithHostPort (util.js:1073:20) at internalConnect (net.js:889:16) at lookupAndConnect (net.js:977:5) at Socket.realConnect (net.js:945:5) at Agent.connect [as createConnection] (net.js:77:22) at Agent.createSocket (_http_agent.js:195:26) at Agent.addRequest (_http_agent.js:157:10) at new ClientRequest (_http_client.js:212:16) at Object.request (http.js:26:10)
Expected behavior
$ nvm use 7.9.0Now using node v7.9.0
$ node issue.js{ Error: connect ENETUNREACH 255.255.255.255:80 - Local (0.0.0.0:0) at Object.exports._errnoException (util.js:1050:11) at exports._exceptionWithHostPort (util.js:1073:20) at internalConnect (net.js:894:16) at net.js:980:9 at _combinedTickCallback (internal/process/next_tick.js:73:7) at process._tickCallback (internal/process/next_tick.js:104:9) at Module.runMain (module.js:607:11) at run (bootstrap_node.js:423:7) at startup (bootstrap_node.js:147:9) at bootstrap_node.js:538:3 code: 'ENETUNREACH', errno: 'ENETUNREACH', syscall: 'connect', address: '255.255.255.255', port: 80 }
Activity
mscdex commentedon May 5, 2017
Works fine in v7.9.0. Looks like a regression somewhere...
mscdex commentedon May 5, 2017
Bisecting reveals d0b1be1 is the culprit.
FWIW this is also happening in master.
/cc @bnoordhuis
Temporarily disable Travis CI testing on Node.js current branch
Revert "net: remove unnecessary process.nextTick()"
test: add regression test for immediate socket errors
Revert "net: remove unnecessary process.nextTick()"
test: add regression test for immediate socket errors
Revert "net: remove unnecessary process.nextTick()"
test: add regression test for immediate socket errors
Actually catch the boot-time ENETUNREACH mDNS crash