Version
v20.0.0
Platform
Microsoft Windows NT 10.0.22621.0 x64
Subsystem
vm
What steps will reproduce the bug?
const vm = require("vm");
const context = vm.createContext();
const contextGlobalThis = vm.runInContext("this", context);
console.log("before");
contextGlobalThis.__proto__ = null;
console.log("after?");
This will only log "before" in Node v19.9.0 and v20.0.0. It will log both "before" and "after?" in Node v19.8.1.
If you log the exit code after a failed run I get 5.
How often does it reproduce? Is there a required condition?
Every time.
What is the expected behavior? Why is that the expected behavior?
Setting the proto to null should work.
What do you see instead?
A crash
Additional information
This causes jsdom's test suite to crash as this sort of behavior is part of web platform tests.
Version
v20.0.0
Platform
Microsoft Windows NT 10.0.22621.0 x64
Subsystem
vm
What steps will reproduce the bug?
This will only log "before" in Node v19.9.0 and v20.0.0. It will log both "before" and "after?" in Node v19.8.1.
If you log the exit code after a failed run I get 5.
How often does it reproduce? Is there a required condition?
Every time.
What is the expected behavior? Why is that the expected behavior?
Setting the proto to null should work.
What do you see instead?
A crash
Additional information
This causes jsdom's test suite to crash as this sort of behavior is part of web platform tests.