Skip to content

node --inspect ignores debugger statements and breakpoints inside vm.runInContext #12096

@clarabstract

Description

@clarabstract
  • Version: 7.73
  • Platform: Windows (10, 64bit)
  • Subsystem: v8-debug (?)

The chrome-devtools:// view correctly displays the console output, is aware of the files being executed using vm.runInContext (with filename set), even lets me set breakpoints in them, it just doesn't actually break for them.

I forward the outer console object into the vm context so console.log statements get correctly printed out by the inspector and I can dig through objects, assign them etc. (though it crashes when accessing certain objects - by the looks of it, it doesn't keep a GC reference to them so they are probably just no longer there).

I'm hoping there is a similar mechanism I can use to have the VM's debug context share the outer one?

Metadata

Metadata

Assignees

Labels

inspectorIssues and PRs related to the V8 inspector protocolvmIssues and PRs related to the vm subsystem.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions