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
// TODO(joyeecheung): when we snapshot the bootstrapped context,
// the inspector and diagnostics setup should after after deserialization.
#if HAVE_INSPECTOR
*exit_code = env->InitializeInspector({});
#endif
Environment* CreateEnvironment(IsolateData* isolate_data,
Local<Context> context,
int argc,
constchar* const* argv,
int exec_argc,
constchar* const* exec_argv) {
Isolate* isolate = context->GetIsolate();
HandleScope handle_scope(isolate);
Context::Scope context_scope(context);
// TODO(addaleax): This is a much better place for parsing per-Environment// options than the global parse call.
std::vector<std::string> args(argv, argv + argc);
std::vector<std::string> exec_args(exec_argv, exec_argv + exec_argc);
// TODO(addaleax): Provide more sensible flags, in an embedder-accessible way.
Environment* env = newEnvironment(
isolate_data,
context,
args,
exec_args,
static_cast<Environment::Flags>(Environment::kIsMainThread |
Environment::kOwnsProcessState |
Environment::kOwnsInspector));
env->InitializeLibuv(per_process::v8_is_profiling);
// ========== START SUGGEST ==========
env->InitializeDiagnostics();
// TODO(joyeecheung): when we snapshot the bootstrapped context,// the inspector and diagnostics setup should after after deserialization.
#if HAVE_INSPECTOR && NODE_USE_V8_PLATFORM
//TODO(jc-lab): If InitializeInspector fails, the caller must be informed of the return_code.
env->InitializeInspector(nullptr);
#endif
I thought about the above suggestions.
However, the above proposal does not pass the EnvironmentTest.MultipleEnvironmentsPerIsolate test.
Inspector does not initialize when using CreateEnvironment.
So occur crash in the code below. (inspector_agent()->client_ is null)
Initialization takes place only here.
I thought about the above suggestions.
However, the above proposal does not pass the EnvironmentTest.MultipleEnvironmentsPerIsolate test.
node/src/inspector_agent.cc
Line 770 in 1a552f6
The text was updated successfully, but these errors were encountered: