-
Notifications
You must be signed in to change notification settings - Fork 72
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
Unit tests fail on Node.js v14.x and v15.x - Check failed: result.second. #717
Comments
I did some investigation locally, this crash happens when we use TypedArray when receiving topics and calling #
# Fatal error in , line 0
# Check failed: length == backing_store->byte_length().
#
#
#
#FailureMessage Object: 0x7fffffff8c00
1: 0xa70141 [/home/minggang/.nvm/versions/node/v14.15.0/bin/node]
2: 0x19cf084 V8_Fatal(char const*, ...) [/home/minggang/.nvm/versions/node/v14.15.0/bin/node]
3: 0xe599ea v8::internal::GlobalBackingStoreRegistry::Lookup(void*, unsigned long) [/home/minggang/.nvm/versions/node/v14.15.0/bin/node]
4: 0xba44af [/home/minggang/.nvm/versions/node/v14.15.0/bin/node]
5: 0xba46b4 v8::ArrayBuffer::New(v8::Isolate*, void*, unsigned long, v8::ArrayBufferCreationMode) [/home/minggang/.nvm/versions/node/v14.15.0/bin/node]
6: 0x7ffff52134af rclnodejs::CreateArrayBufferFromAddress(Nan::FunctionCallbackInfo<v8::Value> const&) [/home/minggang/proj/ros2/rclnodejs-1/build/Release/rclnodejs.node]
7: 0x7ffff52049ac [/home/minggang/proj/ros2/rclnodejs-1/build/Release/rclnodejs.node]
8: 0xbe369b [/home/minggang/.nvm/versions/node/v14.15.0/bin/node]
9: 0xbe4c46 [/home/minggang/.nvm/versions/node/v14.15.0/bin/node]
10: 0xbe52c6 v8::internal::Builtin_HandleApiCall(int, unsigned long*, v8::internal::Isolate*) [/home/minggang/.nvm/versions/node/v14.15.0/bin/node]
11: 0x13ff259 [/home/minggang/.nvm/versions/node/v14.15.0/bin/node]
Thread 1 "node" received signal SIGILL, Illegal instruction. |
I think I may find the root cause of this issue. Since v8 8.4.371(node14.15.0), there is a new static constructor used to create a
|
Actually, this issue is ever reported #694 in Aug |
New discussions from node-ffi-napi/ref-napi#54 |
rclnodejs on window 10, node 16 experiences the following error when sending array data. Does this look familiar? Anything I can help with in investigating this in more depth?
|
Looking through the back trace, I guess this has the same root cause with what this issue described originally. The
Personally, I prefer the second one because it remove dependency completely, the |
Out of curiosity I replaced ref-napi with this recently patched version https://github.com/alphacep/ref-napi. On windows it fails with this stack-trace when deserializing an array or complex msg type:
|
Thanks for trying the patches out, it seems that we have to make some changes accordingly. We may consider applying #723 (the situation may have changed since it was implemented in last year). BTW, what is your nodejs versoin? |
opps accidentally omitted that the stack trace above was generated on ros2 foxy, window 10, vsc 2017, node 16.3.0. |
Hi @koonpeng thanks for updating the status and it seems that we'd better try to fix the bug of |
After forking |
I think the issue was fixed, so close it. |
When using the latest Node.js LTS Fermium v14.15.0, the unit test began to fail consistently and it also reproduces on v15.x versions. Backtrace is
and the corresponding PR #716
The text was updated successfully, but these errors were encountered: