Intermittent debugger crash involving async_hooks and Chrome DevTools integration.
The issue involves a debugger crash when using Chrome DevTools with Node's inspector, specifically during Step-Out operations. The problem appears related to async_hooks checks and has intermittent reproduction across different environments. Main blockers are the inconsistent reproduction and potential deep interaction between debugger internals and async_hooks.
Webstorm 2017.2.5 Chrome: 62.0.3202.94
No crash using Webstorm 2017.1.4
While using the Chrome DevTools and node --inspect, the node process crashes right after Chrome auto-detected the debug session as a network target.
/usr/local/bin/node[28426]: ../src/node.cc:1449:void node::InternalCallbackScope::Close(): Assertion `(env_->trigger_async_id()) == (0)' failed.
1: node::Abort() [/usr/local/bin/node]
2: node::(anonymous namespace)::DomainEnter(node::Environment*, v8::Local<v8::Object>) [/usr/local/bin/node]
3: node::InternalCallbackScope::Close() [/usr/local/bin/node]
4: node::InternalCallbackScope::~InternalCallbackScope() [/usr/local/bin/node]
5: node::RunForegroundTask(v8::Task*) [/usr/local/bin/node]
6: node::NodePlatform::FlushForegroundTasksInternal() [/usr/local/bin/node]
7: node::inspector::NodeInspectorClient::runMessageLoopOnPause(int) [/usr/local/bin/node]
8: v8_inspector::V8Debugger::handleProgramBreak(v8::Local<v8::Context>, v8::Local<v8::Value>, std::__1::vector<int, std::__1::allocator<int> > const&, bool, bool) [/usr/local/bin/node]
9: v8::internal::Debug::OnDebugBreak(v8::internal::Handle<v8::internal::FixedArray>) [/usr/local/bin/node]
10: v8::internal::Debug::Break(v8::internal::JavaScriptFrame*) [/usr/local/bin/node]
Claim this issue to let others know you're working on it. You'll earn 10 points when you complete it!