Skip to content

exceptions in inspector callback cause fatal errorΒ #14965

@bcoates

Description

@bcoates
  • Version: v.8.4.0
  • Platform: Linux 3.13.0-92-generic x86_64 (Ubuntu 14.04.4 LTS)
  • Subsystem: inspector

An exception (either with "throw" or due to an error) inside the callback from an inspector event sometimes causes a fatal error (if there is not a fatal, it appears to eat the exception)

Possibly same issue as #12024

This case seems to reliably trigger it:

let inspector = require('inspector')
let sess = new inspector.Session()

sess.on('inspectorNotification', ()=>{
 console.log('note')
 throw "barf"
})

sess.connect()
sess.post('Debugger.enable', {}, (err,res) => {console.log(err,res)} )

console.log('done')

output:

note


#
# Fatal error in ../deps/v8/src/builtins/builtins-console.cc, line 53
# Check failed: !isolate->has_scheduled_exception().
#

==== C stack trace ===============================

    node(v8::base::debug::StackTrace::StackTrace()+0x16) [0x15c8c36]
    node() [0x1451857]
    node(V8_Fatal+0xd8) [0x15c3998]
    node(v8::internal::Builtin_ConsoleLog(int, v8::internal::Object**, v8::internal::Isolate*)+0x10c) [0xc4d10c]
    [0xaf03813c8dd]
Illegal instruction (core dumped)

Metadata

Metadata

Assignees

No one assigned

    Labels

    inspectorIssues and PRs related to the V8 inspector protocol

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions