Problem
The exact Linux package gate crashes in many otherwise independent V8 test executables during runtime destruction. GDB from run 35511487622 identifies a stale persistent handle released after its isolate:
v8::internal::GlobalHandles::NodeSpace<...>::Release
webscene_native::v8_dom_runtime::implementation::~implementation()
v8_dom_runtime::~v8_dom_runtime()
webscene_engine::run_core
implementation::~implementation() disposes its owned isolate inside the destructor body, but several v8::Global owners remain populated and are therefore destroyed later with the C++ object. The generated meter/output/progress element templates are direct omissions. Active drag state, outbound drag state, and the discrete wheel animation can also retain persistent handles across teardown.
Proposed fix
- Release every direct generated DOM template before isolate disposal.
- Reset optional/owned interaction state that contains
v8::Global handles before isolate disposal.
- Keep async worker shutdown and handle release ordered before
Isolate::Dispose().
- Audit every direct and nested persistent handle owner in runtime state against the destructor.
Acceptance
- Focused native V8 runtime tests exit normally on Linux without
GlobalHandles::NodeSpace::Release faults.
- The exact package gate has no teardown SIGSEGV across independent V8 executables.
- Shared-isolate and owned-isolate lifetimes both retain their existing order.
- No additional steady-state work or memory is introduced.
Evidence
Parent tracker: #687
Problem
The exact Linux package gate crashes in many otherwise independent V8 test executables during runtime destruction. GDB from run
35511487622identifies a stale persistent handle released after its isolate:implementation::~implementation()disposes its owned isolate inside the destructor body, but severalv8::Globalowners remain populated and are therefore destroyed later with the C++ object. The generated meter/output/progress element templates are direct omissions. Active drag state, outbound drag state, and the discrete wheel animation can also retain persistent handles across teardown.Proposed fix
v8::Globalhandles before isolate disposal.Isolate::Dispose().Acceptance
GlobalHandles::NodeSpace::Releasefaults.Evidence
Parent tracker: #687