Skip to content
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

make "test^js^step0" fails -- Fatal error in , line 0 -- Check failed: result.second. #612

Closed
purplejacket opened this issue Mar 13, 2022 · 1 comment

Comments

@purplejacket
Copy link

purplejacket commented Mar 13, 2022

I've cloned the mal project and am attempting a few basic tests. These three work:

make "test^ruby^step0"
make "test^perl^step0"
make "test^python^step0"

I'm running MacOS:

$ uname -a
Darwin crystolith 21.3.0 Darwin Kernel Version 21.3.0: Wed Jan  5 21:37:58 PST 2022; root:xnu-8019.80.24~20/RELEASE_X86_64 x86_64

These versions of node, python:

$ node --version
v16.13.2
$ python --version
Python 2.7.18

(I tried deleting node_modules and ran make all in the impls/js directory, no help.)

This is what I'm getting, from a fresh clone of the repo:

$ make "test^js^step0"
/Library/Developer/CommandLineTools/usr/bin/make -C impls/js step0_repl.js
npm install

added 12 packages, and audited 13 packages in 9s

found 0 vulnerabilities
(call STEP_TEST_FILES,js,step0): impls/tests/step0_repl.mal
----------------------------------------------
Testing test^js^step0; step file: impls/js/step0_repl.js, test file: tests/step0_repl.mal
Running: env STEP=step0_repl MAL_IMPL=js ../../runtest.py  --deferrable --optional   ../tests/step0_repl.mal -- ../js/run
Started with:


#
# Fatal error in , line 0
# Check failed: result.second.
#
#
#
#FailureMessage Object: 0x7ff7b05d9060
 1: 0x10fa614f2 node::NodePlatform::GetStackTracePrinter()::$_3::__invoke() [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
 2: 0x110a2bb03 V8_Fatal(char const*, ...) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
 3: 0x10fe4c5be v8::internal::GlobalBackingStoreRegistry::Register(std::__1::shared_ptr<v8::internal::BackingStore>) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
 4: 0x10fb851e6 v8::ArrayBuffer::GetBackingStore() [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
 5: 0x10f9ad78e napi_get_typedarray_info [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
 6: 0x114770a5a Napi::Buffer<
Testing basic string
TEST: 'abcABC123' -> ['',abcABC123] -> TIMEOUT (line 3)

Exception: TestTimeout('TIMEOUT (line 3)',)
Output before exception:
Napi::Buffer<char>::New<Napi::Value FFI::WrapPointer<_ffi_type>(Napi::Env, _ffi_type*, unsigned long)::'lambda'(Napi::Env, char*)>(napi_env__*, char*, unsigned long, _ffi_type) [/private/tmp/mal/impls/js/node_modules/ffi-napi/build/Release/ffi_bindings.node]
 7: 0x11476ba1b FFI::FFI::InitializeBindings(Napi::Env, Napi::Object) [/private/tmp/mal/impls/js/node_modules/ffi-napi/build/Release/ffi_bindings.node]
 8: 0x11476f403 __napi_Init(napi_env__*, napi_valueabcABC123
__*) [/private/tmp/mal/impls/js/node_modules/ffi-napi/build/Release/ffi_bindings.node]
 9: 0x10f9be9c6 napi_module_register_by_symbol(v8::Local<v8::Object>, v8::Local<v8::Value>, v8::Local<v8::Context>, napi_value__* (*)(napi_env__*, napi_value__*)) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
10: 0x10f9c3b47 std::__1::__function::__func<node::binding::DLOpen(v8::FunctionCallbackInfo<v8::Value> const&)::$_0, std::__1::allocator<node::binding::DLOpen(v8::FunctionCallbackInfo<v8::Value> const&)::$_0>, bool (node::binding::DLib*)>::operator()(node::binding::DLib*&&) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
11: 0x10f9c2750 node::Environment::TryLoadAddon(char const*, int, std::__1::function<bool (node::binding::DLib*)> const&) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
12: 0x10f9c252b node::binding::DLOpen(v8::FunctionCallbackInfo<v8::Value> const&) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
13: 0x10fbdb4a9 v8::internal::FunctionCallbackArguments::Call(v8::internal::CallHandlerInfo) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
14: 0x10fbdaf76 v8::internal::MaybeHandle<v8::internal::Object> v8::internal::(anonymous namespace)::HandleApiCallHelper<false>(v8::internal::Isolate*, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::FunctionTemplateInfo>, v8::internal::Handle<v8::internal::Object>, v8::internal::BuiltinArguments) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
15: 0x10fbda6ef v8::internal::Builtin_HandleApiCall(int, unsigned long*, v8::internal::Isolate*) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
16: 0x11044b5f9 Builtins_CEntry_Return1_DontSaveFPRegs_ArgvOnStack_BuiltinExit [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]

make: *** [test^js^step0] Error 1

Interesting, I note that this also fails, and in almost the same way:

$ make "test^mal^step0"
/Library/Developer/CommandLineTools/usr/bin/make -C impls/mal step0_repl.mal
make[1]: `step0_repl.mal' is up to date.
(call STEP_TEST_FILES,mal,step0): impls/tests/step0_repl.mal
----------------------------------------------
Testing test^mal^step0; step file: impls/mal/step0_repl.mal, test file: tests/step0_repl.mal
Running: env STEP=step0_repl MAL_IMPL=js RAW=1 ../../runtest.py  --deferrable --optional --start-timeout 60 --test-timeout 120  ../tests/step0_repl.mal -- ../mal/run
Started with:


#
# Fatal error in , line 0
# Check failed: result.second.
#
#
#
#FailureMessage Object: 0x7ff7b5403000
 1: 0x10ac374f2 node::NodePlatform::GetStackTracePrinter()::$_3::__invoke() [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
 2: 0x10bc01b03 V8_Fatal(char const*, ...) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
 3: 0x10b0225be v8::internal::GlobalBackingStoreRegistry::Register(std::__1::shared_ptr<v8::internal::BackingStore>) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
 4: 0x10ad5b1e6 v8::ArrayBuffer::GetBackingStore() [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
 5: 0x10ab8378e napi_get_typedarray_info [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
 6: 0x10f946a5a Napi::Buffer<
Testing basic string
TEST: 'abcABC123' -> ['',abcABC123]

Exception: TestTimeout('TIMEOUT (line 3)',)
Output before exception:
Napi::Buffer<char>::New<Napi::Value FFI::WrapPointer<_ffi_type>(Napi::Env, _ffi_type*, unsigned long)::'lambda'(Napi::Env, char*)>(napi_env__*, char*, unsigned long, _ffi_type) [/private/tmp/mal/impls/js/node_modules/ffi-napi/build/Release/ffi_bindings.node]
 7: 0x10f941a1b FFI::FFI::InitializeBindings(Napi::Env, Napi::Object) [/private/tmp/mal/impls/js/node_modules/ffi-napi/build/Release/ffi_bindings.node]
 8: 0x10f945403 __napi_Init(napi_env_abcABC123
_*, napi_value__*) [/private/tmp/mal/impls/js/node_modules/ffi-napi/build/Release/ffi_bindings.node]
 9: 0x10ab949c6 napi_module_register_by_symbol(v8::Local<v8::Object>, v8::Local<v8::Value>, v8::Local<v8::Context>, napi_value__* (*)(napi_env__*, napi_value__*)) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
10: 0x10ab99b47 std::__1::__function::__func<node::binding::DLOpen(v8::FunctionCallbackInfo<v8::Value> const&)::$_0, std::__1::allocator<node::binding::DLOpen(v8::FunctionCallbackInfo<v8::Value> const&)::$_0>, bool (node::binding::DLib*)>::operator()(node::binding::DLib*&&) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
11: 0x10ab98750 node::Environment::TryLoadAddon(char const*, int, std::__1::function<bool (node::binding::DLib*)> const&) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
12: 0x10ab9852b node::binding::DLOpen(v8::FunctionCallbackInfo<v8::Value> const&) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
13: 0x10adb14a9 v8::internal::FunctionCallbackArguments::Call(v8::internal::CallHandlerInfo) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
14: 0x10adb0f76 v8::internal::MaybeHandle<v8::internal::Object> v8::internal::(anonymous namespace)::HandleApiCallHelper<false>(v8::internal::Isolate*, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::HeapObject>, v8::internal::Handle<v8::internal::FunctionTemplateInfo>, v8::internal::Handle<v8::internal::Object>, v8::internal::BuiltinArguments) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
15: 0x10adb06ef v8::internal::Builtin_HandleApiCall(int, unsigned long*, v8::internal::Isolate*) [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]
16: 0x10b6215f9 Builtins_CEntry_Return1_DontSaveFPRegs_ArgvOnStack_BuiltinExit [/Users/kai/.nvm/versions/node/v16.13.2/bin/node]

make: *** [test^mal^step0] Error 1
@purplejacket
Copy link
Author

Huh. This was a problem with the node version. Version 16 seems to fail but version 17 works. Above the failure is with v16.13.2 but it also fails with v16.14.0 -- and that's an LTS version. However, this works:

$ node --version
v17.7.1

$ make "test^js^step0"
/Library/Developer/CommandLineTools/usr/bin/make -C impls/js step0_repl.js
make[1]: Nothing to be done for `step0_repl.js'.
(call STEP_TEST_FILES,js,step0): impls/tests/step0_repl.mal
----------------------------------------------
Testing test^js^step0; step file: impls/js/step0_repl.js, test file: tests/step0_repl.mal
Running: env STEP=step0_repl MAL_IMPL=js ../../runtest.py  --deferrable --optional   ../tests/step0_repl.mal -- ../js/run
Testing basic string
TEST: 'abcABC123' -> ['',abcABC123] -> SUCCESS
Testing string containing spaces
TEST: 'hello mal world' -> ['',hello mal world] -> SUCCESS
Testing string containing symbols
TEST: '[]{}"\'* ;:()' -> ['',[]{}"'* ;:()] -> SUCCESS
Test long string
TEST: 'hello world abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ 0123456789 (;:() []{}"\'* ;:() []{}"\'* ;:() []{}"\'*)' -> ['',hello world abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ 0123456789 (;:() []{}"'* ;:() []{}"'* ;:() []{}"'*)] -> SUCCESS
Non alphanumeric characters
TEST: '!' -> ['',!] -> SUCCESS
TEST: '&' -> ['',&] -> SUCCESS
TEST: '+' -> ['',+] -> SUCCESS
TEST: ',' -> ['',,] -> SUCCESS
TEST: '-' -> ['',-] -> SUCCESS
TEST: '/' -> ['',/] -> SUCCESS
TEST: '<' -> ['',<] -> SUCCESS
TEST: '=' -> ['',=] -> SUCCESS
TEST: '>' -> ['',>] -> SUCCESS
TEST: '?' -> ['',?] -> SUCCESS
TEST: '@' -> ['',@] -> SUCCESS
TEST: '^' -> ['',^] -> SUCCESS
TEST: '_' -> ['',_] -> SUCCESS
TEST: '`' -> ['',`] -> SUCCESS
TEST: '~' -> ['',~] -> SUCCESS
------- Optional Functionality --------------
------- (Not needed for self-hosting) -------
Non alphanumeric characters
TEST: '#' -> ['',#] -> SUCCESS
TEST: '$' -> ['',$] -> SUCCESS
TEST: '%' -> ['',%] -> SUCCESS
TEST: '.' -> ['',.] -> SUCCESS
TEST: '|' -> ['',|] -> SUCCESS

TEST RESULTS (for ../tests/step0_repl.mal):
    0: soft failing tests
    0: failing tests
   24: passing tests
   24: total tests

$ make "test^mal^step0"
/Library/Developer/CommandLineTools/usr/bin/make -C impls/mal step0_repl.mal
make[1]: `step0_repl.mal' is up to date.
(call STEP_TEST_FILES,mal,step0): impls/tests/step0_repl.mal
----------------------------------------------
Testing test^mal^step0; step file: impls/mal/step0_repl.mal, test file: tests/step0_repl.mal
Running: env STEP=step0_repl MAL_IMPL=js RAW=1 ../../runtest.py  --deferrable --optional --start-timeout 60 --test-timeout 120  ../tests/step0_repl.mal -- ../mal/run
Testing basic string
TEST: 'abcABC123' -> ['',abcABC123] -> SUCCESS
Testing string containing spaces
TEST: 'hello mal world' -> ['',hello mal world] -> SUCCESS
Testing string containing symbols
TEST: '[]{}"\'* ;:()' -> ['',[]{}"'* ;:()] -> SUCCESS
Test long string
TEST: 'hello world abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ 0123456789 (;:() []{}"\'* ;:() []{}"\'* ;:() []{}"\'*)' -> ['',hello world abcdefghijklmnopqrstuvwxyz ABCDEFGHIJKLMNOPQRSTUVWXYZ 0123456789 (;:() []{}"'* ;:() []{}"'* ;:() []{}"'*)] -> SUCCESS
Non alphanumeric characters
TEST: '!' -> ['',!] -> SUCCESS
TEST: '&' -> ['',&] -> SUCCESS
TEST: '+' -> ['',+] -> SUCCESS
TEST: ',' -> ['',,] -> SUCCESS
TEST: '-' -> ['',-] -> SUCCESS
TEST: '/' -> ['',/] -> SUCCESS
TEST: '<' -> ['',<] -> SUCCESS
TEST: '=' -> ['',=] -> SUCCESS
TEST: '>' -> ['',>] -> SUCCESS
TEST: '?' -> ['',?] -> SUCCESS
TEST: '@' -> ['',@] -> SUCCESS
TEST: '^' -> ['',^] -> SUCCESS
TEST: '_' -> ['',_] -> SUCCESS
TEST: '`' -> ['',`] -> SUCCESS
TEST: '~' -> ['',~] -> SUCCESS
------- Optional Functionality --------------
------- (Not needed for self-hosting) -------
Non alphanumeric characters
TEST: '#' -> ['',#] -> SUCCESS
TEST: '$' -> ['',$] -> SUCCESS
TEST: '%' -> ['',%] -> SUCCESS
TEST: '.' -> ['',.] -> SUCCESS
TEST: '|' -> ['',|] -> SUCCESS

TEST RESULTS (for ../tests/step0_repl.mal):
    0: soft failing tests
    0: failing tests
   24: passing tests
   24: total tests

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant