-
Notifications
You must be signed in to change notification settings - Fork 71
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Snapshot test failures #237
Comments
For example, one of the errors:
|
Looks like it's caused by an unknown external reference somewhere. I'll try to build it locally to see what the reference is. Do I simply need to build the canary branch from this repo? |
Yes |
Traced this back to https://chromium-review.googlesource.com/c/v8/v8/+/3776678, which added a v8::External to the V8Console, and this band-aid makes the crash go away
I'll see if we can do something like what's been done for |
After looking into it a bit I think we should simply remove the inspector console methods during serialization because V8 is always going to re-install them when another inspector client is created during deserialization - with a new reference to the new inspector console. I created a commit that works on both the canary branch here and the main branch in the main repo (these methods are renamed in the new version of V8 so we can't hard-code the methods to remove) at https://github.com/joyeecheung/node/tree/fix-createtask, which depends on nodejs/node#44203 (which is also necessary to fix the two additional failures in snapshot-warning and snapshot-typescript tests in the canary, as the newer version of V8 is also less permissive with re-installing Error.stackTraceLimit in the release builds). I'll open a PR to the upstream after nodejs/node#44203 lands. |
Opened nodejs/node#44279 |
Some console methods are created by the V8 inspector after an inspector client is created, reset them to undefined during sereialization to avoid holding on to invalid references in the snapshot. V8 will take care of the re-initialization when another inspector client is created during deserialization. PR-URL: #44279 Fixes: nodejs/node-v8#237 Reviewed-By: Chengzhong Wu <legendecas@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Some console methods are created by the V8 inspector after an inspector client is created, reset them to undefined during sereialization to avoid holding on to invalid references in the snapshot. V8 will take care of the re-initialization when another inspector client is created during deserialization. PR-URL: nodejs#44279 Fixes: nodejs/node-v8#237 Reviewed-By: Chengzhong Wu <legendecas@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Some console methods are created by the V8 inspector after an inspector client is created, reset them to undefined during sereialization to avoid holding on to invalid references in the snapshot. V8 will take care of the re-initialization when another inspector client is created during deserialization. PR-URL: #44279 Fixes: nodejs/node-v8#237 Reviewed-By: Chengzhong Wu <legendecas@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Some console methods are created by the V8 inspector after an inspector client is created, reset them to undefined during sereialization to avoid holding on to invalid references in the snapshot. V8 will take care of the re-initialization when another inspector client is created during deserialization. PR-URL: #44279 Fixes: nodejs/node-v8#237 Reviewed-By: Chengzhong Wu <legendecas@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
https://github.com/nodejs/node-v8/runs/7761703491?check_suite_focus=true
/cc @joyeecheung
The text was updated successfully, but these errors were encountered: