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

Crash on iOS when app built in release, works in debug #377

Closed
omatrot opened this issue Apr 1, 2019 · 3 comments

Comments

@omatrot
Copy link

commented Apr 1, 2019

I have this weird problem where the app works fine when compiled in debug, but crashes when run in release:

it happens either when I click the menu burger icon, or when I swipe to close the menu or I choose a menu item.

com.facebook.react.JavaScript (8): EXC_BAD_ACCESS (code=2, address=0x22566a988)

stack:

#1	0x0000000101c06554 in facebook::react::RCTNativeModule::invoke(unsigned int, folly::dynamic&&, int) at /Users/omatrot/Projects/sensoriaanalytics/MyHeartSigns/node_modules/react-native/React/CxxModule/RCTNativeModule.mm:79
#2	0x0000000101baa1a8 in facebook::react::JsToNativeBridge::callNativeModules(facebook::react::JSExecutor&, folly::dynamic&&, bool) at /Users/omatrot/Projects/sensoriaanalytics/MyHeartSigns/node_modules/react-native/ReactCommon/cxxreact/NativeToJsBridge.cpp:56
#3	0x0000000101ba01b4 in facebook::react::JSIExecutor::callNativeModules(facebook::jsi::Value const&, bool) at /Users/omatrot/Projects/sensoriaanalytics/MyHeartSigns/node_modules/react-native/ReactCommon/jsiexecutor/jsireact/JSIExecutor.cpp:320
#4	0x0000000101ba1398 in facebook::react::JSIExecutor::loadApplicationScript(std::__1::unique_ptr<facebook::react::JSBigString const, std::__1::default_delete<facebook::react::JSBigString const> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >)::$_1::operator()(facebook::jsi::Runtime&, facebook::jsi::Value const&, facebook::jsi::Value const*, unsigned long) const [inlined] at /Users/omatrot/Projects/sensoriaanalytics/MyHeartSigns/node_modules/react-native/ReactCommon/jsiexecutor/jsireact/JSIExecutor.cpp:101
#5	0x0000000101ba1390 in decltype(std::__1::forward<facebook::react::JSIExecutor::loadApplicationScript(std::__1::unique_ptr<facebook::react::JSBigString const, std::__1::default_delete<facebook::react::JSBigString const> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >)::$_1&>(fp)(std::__1::forward<facebook::jsi::Runtime&>(fp0), std::__1::forward<facebook::jsi::Value const&>(fp0), std::__1::forward<facebook::jsi::Value const*>(fp0), std::__1::forward<unsigned long>(fp0))) std::__1::__invoke<facebook::react::JSIExecutor::loadApplicationScript(std::__1::unique_ptr<facebook::react::JSBigString const, std::__1::default_delete<facebook::react::JSBigString const> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >)::$_1&, facebook::jsi::Runtime&, facebook::jsi::Value const&, facebook::jsi::Value const*, unsigned long>(facebook::react::JSIExecutor::loadApplicationScript(std::__1::unique_ptr<facebook::react::JSBigString const, std::__1::default_delete<facebook::react::JSBigString const> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >)::$_1&, facebook::jsi::Runtime&, facebook::jsi::Value const&, facebook::jsi::Value const*&&, unsigned long&&) [inlined] at /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/type_traits:4339
#6	0x0000000101ba137c in facebook::jsi::Value std::__1::__invoke_void_return_wrapper<facebook::jsi::Value>::__call<facebook::react::JSIExecutor::loadApplicationScript(std::__1::unique_ptr<facebook::react::JSBigString const, std::__1::default_delete<facebook::react::JSBigString const> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >)::$_1&, facebook::jsi::Runtime&, facebook::jsi::Value const&, facebook::jsi::Value const*, unsigned long>(facebook::react::JSIExecutor::loadApplicationScript(std::__1::unique_ptr<facebook::react::JSBigString const, std::__1::default_delete<facebook::react::JSBigString const> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >)::$_1&, facebook::jsi::Runtime&, facebook::jsi::Value const&, facebook::jsi::Value const*&&, unsigned long&&) [inlined] at /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/__functional_base:318
#7	0x0000000101ba137c in std::__1::__function::__func<facebook::react::JSIExecutor::loadApplicationScript(std::__1::unique_ptr<facebook::react::JSBigString const, std::__1::default_delete<facebook::react::JSBigString const> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >)::$_1, std::__1::allocator<facebook::react::JSIExecutor::loadApplicationScript(std::__1::unique_ptr<facebook::react::JSBigString const, std::__1::default_delete<facebook::react::JSBigString const> >, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >)::$_1>, facebook::jsi::Value (facebook::jsi::Runtime&, facebook::jsi::Value const&, facebook::jsi::Value const*, unsigned long)>::operator()(facebook::jsi::Runtime&, facebook::jsi::Value const&, facebook::jsi::Value const*&&, unsigned long&&) at /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/functional:1562
#8	0x0000000101b98cf0 in std::__1::function<facebook::jsi::Value (facebook::jsi::Runtime&, facebook::jsi::Value const&, facebook::jsi::Value const*, unsigned long)>::operator()(facebook::jsi::Runtime&, facebook::jsi::Value const&, facebook::jsi::Value const*, unsigned long) const at /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/functional:1913
#9	0x0000000101b98a30 in facebook::jsc::JSCRuntime::createFunctionFromHostFunction(facebook::jsi::PropNameID const&, unsigned int, std::__1::function<facebook::jsi::Value (facebook::jsi::Runtime&, facebook::jsi::Value const&, facebook::jsi::Value const*, unsigned long)>)::HostFunctionMetadata::call(OpaqueJSContext const*, OpaqueJSValue*, OpaqueJSValue*, unsigned long, OpaqueJSValue const* const*, OpaqueJSValue const**) at /Users/omatrot/Projects/sensoriaanalytics/MyHeartSigns/node_modules/react-native/ReactCommon/jsi/JSCRuntime.cpp:954
#10	0x00000001f3b9fcbc in JSC::JSCallbackObject<JSC::JSDestructibleObject>::call(JSC::ExecState*) ()
#11	0x00000001f415874c in JSC::LLInt::setUpCall(JSC::ExecState*, JSC::CodeSpecializationKind, JSC::JSValue, JSC::LLIntCallLinkInfo*) ()
#12	0x00000001f3b753b0 in llint_entry ()
#13	0x00000001f3b75324 in llint_entry ()
#14	0x00000001f3b75324 in llint_entry ()
#15	0x00000001f3b75324 in llint_entry ()
#16	0x00000001f3b75324 in llint_entry ()
#17	0x00000001f3b75324 in llint_entry ()
#18	0x00000001f3b75324 in llint_entry ()
#19	0x00000001f3b75324 in llint_entry ()
#20	0x00000001f3b75324 in llint_entry ()
#21	0x00000001f3b75324 in llint_entry ()
#22	0x00000001f3b75324 in llint_entry ()
#23	0x00000001f3b76064 in llint_entry ()
#24	0x00000001f3b75324 in llint_entry ()
#25	0x00000001f3b753c4 in llint_entry ()
#26	0x00000001f3b75324 in llint_entry ()
#27	0x00000001f3b60e6c in vmEntryToJavaScript ()
#28	0x00000001f40920bc in JSC::Interpreter::executeCall(JSC::ExecState*, JSC::JSObject*, JSC::CallType, JSC::CallData const&, JSC::JSValue, JSC::ArgList const&) ()
#29	0x00000001f42f0aa4 in JSC::boundThisNoArgsFunctionCall(JSC::ExecState*) ()
#30	0x00000001f3b61014 in vmEntryToNative ()
#31	0x00000001f4092110 in JSC::Interpreter::executeCall(JSC::ExecState*, JSC::JSObject*, JSC::CallType, JSC::CallData const&, JSC::JSValue, JSC::ArgList const&) ()
#32	0x00000001f4273e74 in JSC::profiledCall(JSC::ExecState*, JSC::ProfilingReason, JSC::JSValue, JSC::CallType, JSC::CallData const&, JSC::JSValue, JSC::ArgList const&) ()
#33	0x00000001f3ba6194 in JSObjectCallAsFunction ()
#34	0x0000000101b96ab8 in facebook::jsc::JSCRuntime::call(facebook::jsi::Function const&, facebook::jsi::Value const&, facebook::jsi::Value const*, unsigned long) at /Users/omatrot/Projects/sensoriaanalytics/MyHeartSigns/node_modules/react-native/ReactCommon/jsi/JSCRuntime.cpp:1056
#35	0x0000000101ba1f9c in facebook::jsi::Function::call(facebook::jsi::Runtime&, facebook::jsi::Value const*, unsigned long) const [inlined] at /Users/omatrot/Projects/sensoriaanalytics/MyHeartSigns/node_modules/react-native/ReactCommon/jsi/jsi-inl.h:219
#36	0x0000000101ba1f70 in facebook::jsi::Function::call(facebook::jsi::Runtime&, std::initializer_list<facebook::jsi::Value>) const [inlined] at /Users/omatrot/Projects/sensoriaanalytics/MyHeartSigns/node_modules/react-native/ReactCommon/jsi/jsi-inl.h:224
#37	0x0000000101ba1f70 in facebook::jsi::Value facebook::jsi::Function::call<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, facebook::jsi::Value>(facebook::jsi::Runtime&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, facebook::jsi::Value&&) const at /Users/omatrot/Projects/sensoriaanalytics/MyHeartSigns/node_modules/react-native/ReactCommon/jsi/jsi-inl.h:233
#38	0x0000000101ba1dfc in facebook::react::JSIExecutor::callFunction(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, folly::dynamic const&)::$_5::operator()() const [inlined] at /Users/omatrot/Projects/sensoriaanalytics/MyHeartSigns/node_modules/react-native/ReactCommon/jsiexecutor/jsireact/JSIExecutor.cpp:223
#39	0x0000000101ba1db8 in decltype(std::__1::forward<facebook::react::JSIExecutor::callFunction(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, folly::dynamic const&)::$_5&>(fp)()) std::__1::__invoke<facebook::react::JSIExecutor::callFunction(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, folly::dynamic const&)::$_5&>(facebook::react::JSIExecutor::callFunction(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, folly::dynamic const&)::$_5&) [inlined] at /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/type_traits:4339
#40	0x0000000101ba1db8 in void std::__1::__invoke_void_return_wrapper<void>::__call<facebook::react::JSIExecutor::callFunction(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, folly::dynamic const&)::$_5&>(facebook::react::JSIExecutor::callFunction(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, folly::dynamic const&)::$_5&) [inlined] at /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/__functional_base:349
#41	0x0000000101ba1db8 in std::__1::__function::__func<facebook::react::JSIExecutor::callFunction(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, folly::dynamic const&)::$_5, std::__1::allocator<facebook::react::JSIExecutor::callFunction(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, folly::dynamic const&)::$_5>, void ()>::operator()() at /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/functional:1562
#42	0x0000000101b94840 in decltype(std::__1::forward<void (*&)(std::__1::function<void ()> const&, std::__1::function<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > ()>)>(fp)(std::__1::forward<std::__1::function<void ()> const&>(fp0), std::__1::forward<std::__1::function<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > ()> >(fp0))) std::__1::__invoke<void (*&)(std::__1::function<void ()> const&, std::__1::function<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > ()>), std::__1::function<void ()> const&, std::__1::function<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > ()> >(void (*&)(std::__1::function<void ()> const&, std::__1::function<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > ()>), std::__1::function<void ()> const&, std::__1::function<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > ()>&&) [inlined] at /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/type_traits:4339
#43	0x0000000101b94820 in void std::__1::__invoke_void_return_wrapper<void>::__call<void (*&)(std::__1::function<void ()> const&, std::__1::function<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > ()>), std::__1::function<void ()> const&, std::__1::function<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > ()> >(void (*&)(std::__1::function<void ()> const&, std::__1::function<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > ()>), std::__1::function<void ()> const&, std::__1::function<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > ()>&&) at /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/__functional_base:349
#44	0x0000000101b9fdc8 in std::__1::function<void (std::__1::function<void ()> const&, std::__1::function<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > ()>)>::operator()(std::__1::function<void ()> const&, std::__1::function<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > ()>) const [inlined] at /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/functional:1913
#45	0x0000000101b9fda8 in facebook::react::JSIExecutor::callFunction(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, folly::dynamic const&) at /Users/omatrot/Projects/sensoriaanalytics/MyHeartSigns/node_modules/react-native/ReactCommon/jsiexecutor/jsireact/JSIExecutor.cpp:221
#46	0x0000000101bab75c in std::__1::function<void (facebook::react::JSExecutor*)>::operator()(facebook::react::JSExecutor*) const [inlined] at /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/functional:1913
#47	0x0000000101bab744 in facebook::react::NativeToJsBridge::runOnExecutorQueue(std::__1::function<void (facebook::react::JSExecutor*)>)::$_7::operator()() const [inlined] at /Users/omatrot/Projects/sensoriaanalytics/MyHeartSigns/node_modules/react-native/ReactCommon/cxxreact/NativeToJsBridge.cpp:268
#48	0x0000000101bab72c in decltype(std::__1::forward<facebook::react::NativeToJsBridge::runOnExecutorQueue(std::__1::function<void (facebook::react::JSExecutor*)>)::$_7&>(fp)()) std::__1::__invoke<facebook::react::NativeToJsBridge::runOnExecutorQueue(std::__1::function<void (facebook::react::JSExecutor*)>)::$_7&>(facebook::react::NativeToJsBridge::runOnExecutorQueue(std::__1::function<void (facebook::react::JSExecutor*)>)::$_7&) [inlined] at /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/type_traits:4339
#49	0x0000000101bab72c in void std::__1::__invoke_void_return_wrapper<void>::__call<facebook::react::NativeToJsBridge::runOnExecutorQueue(std::__1::function<void (facebook::react::JSExecutor*)>)::$_7&>(facebook::react::NativeToJsBridge::runOnExecutorQueue(std::__1::function<void (facebook::react::JSExecutor*)>)::$_7&) [inlined] at /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/__functional_base:349
#50	0x0000000101bab72c in std::__1::__function::__func<facebook::react::NativeToJsBridge::runOnExecutorQueue(std::__1::function<void (facebook::react::JSExecutor*)>)::$_7, std::__1::allocator<facebook::react::NativeToJsBridge::runOnExecutorQueue(std::__1::function<void (facebook::react::JSExecutor*)>)::$_7>, void ()>::operator()() at /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/functional:1562
#51	0x0000000101bd8f28 in std::__1::function<void ()>::operator()() const [inlined] at /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/functional:1913
#52	0x0000000101bd8f14 in facebook::react::tryAndReturnError(std::__1::function<void ()> const&) at /Users/omatrot/Projects/sensoriaanalytics/MyHeartSigns/node_modules/react-native/React/CxxModule/RCTCxxUtils.mm:72
#53	0x0000000101bf8684 in facebook::react::RCTMessageThread::tryFunc(std::__1::function<void ()> const&) at /Users/omatrot/Projects/sensoriaanalytics/MyHeartSigns/node_modules/react-native/React/CxxBridge/RCTMessageThread.mm:59
#54	0x00000001ec80e10c in __CFRUNLOOP_IS_CALLING_OUT_TO_A_BLOCK__ ()
#55	0x00000001ec80da10 in __CFRunLoopDoBlocks ()
#56	0x00000001ec808a74 in __CFRunLoopRun ()
#57	0x00000001ec808354 in CFRunLoopRunSpecific ()
#58	0x0000000100cabab8 in ::+[RCTCxxBridge runRunLoop]() at /Users/omatrot/Projects/sensoriaanalytics/MyHeartSigns/node_modules/react-native/React/CxxBridge/RCTCxxBridge.mm:249
#59	0x00000001ed3026e4 in __NSThread__start__ ()
#60	0x00000001ec49c2c0 in _pthread_body ()
#61	0x00000001ec49c220 in _pthread_start ()
#62	0x00000001ec49fcdc in thread_start ()

What can I do to help diagnose the problem?

@omatrot

This comment has been minimized.

Copy link
Author

commented Apr 2, 2019

Resolved my manually integrating the module.

@omatrot omatrot closed this Apr 2, 2019

@mharrisweb

This comment has been minimized.

Copy link

commented May 3, 2019

Resolved my manually integrating the module.

Which modules did you integrate manually and how did you do it?

@omatrot

This comment has been minimized.

Copy link
Author

commented May 3, 2019

I recreated the iOS project, then following the each module instructions for a manual integration.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
2 participants
You can’t perform that action at this time.