-
-
Notifications
You must be signed in to change notification settings - Fork 33.3k
Closed
Labels
utilIssues and PRs related to the built-in util module.Issues and PRs related to the built-in util module.
Description
When debugging in node.js 5.3.0 the script bug.js
var util = require('util');
util.inspect({level: "info "});
console.log("Test");
with node debug bug.js
, the debugging session exits. I tried the same in node.js 4.2.4 and it doesn't. When debugging the difference in lib/util.js
, line 324 in 5.3.0 looks like this:
var promiseInternals = inspectPromise(value);
and line 319 in 4.2.4 looks like:
var promiseInternals = value instanceof Promise && inspectPromise(value);
As value is not an instance of Promise, inspectPromise(value)
is called in 5.3.0. Then inspectPromise
calls ensureDebugIsInitialized()
which on the other hand calls require('vm').runInDebugContext('Debug')
. This causes the debugging session to exit. The issue was tested in Ubuntu 14.04 LTS.
Metadata
Metadata
Assignees
Labels
utilIssues and PRs related to the built-in util module.Issues and PRs related to the built-in util module.