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

RN: Crashing APP using Hermes Debugger in Flipper client 0.138.0 or 0.139.0 #3549

Open
alfredarcifa opened this issue Mar 17, 2022 · 15 comments

Comments

@alfredarcifa
Copy link

🐛 Bug Report

React Native: Crashing APP using Hermes Debugger in Flipper client 0.138.0 or 0.139.0

To Reproduce

Podfile :

  • flipperkit_version = '0.138.0'
  • use_flipper!({ 'Flipper' => flipperkit_version, 'Flipper-Folly' => '2.6.10', 'Flipper-DoubleConversion' => '3.2.0', 'Flipper-Glog' => '0.5.0.3', 'Flipper-PeerTalk' => '0.0.4', 'OpenSSL-Universal' => '1.1.1100' })

Environment

"react-native": "0.64.1",
"react-native-flipper": "^0.138.0",
"relativeDependencies": {
"react-native-flipper": "../react-native-flipper"
},
"resolutions": {
"@types/react": "^17",
"react-devtools-core": "4.24.0"
},
...

More info from Mac Crash console:

Termination Reason: SIGNAL 11 Segmentation fault: 11
Terminating Process: exc handler [22017]

Pod installed:

Installing CocoaAsyncSocket (7.6.5)
Installing DoubleConversion (1.1.6)
Installing FBLazyVector (0.64.1)
Installing FBReactNativeSpec (0.64.1)
Installing Firebase (8.10.0)
Installing FirebaseAnalytics (8.10.0)
Installing FirebaseCore (8.10.0)
Installing FirebaseCoreDiagnostics (8.13.0)
Installing FirebaseCrashlytics (8.10.0)
Installing FirebaseInstallations (8.13.0)
Installing Flipper (0.138.0)
Installing Flipper-Boost-iOSX (1.76.0.1.11)
Installing Flipper-DoubleConversion (3.2.0)
Installing Flipper-Fmt (7.1.7)
Installing Flipper-Folly (2.6.10)
Installing Flipper-Glog (0.5.0.3)
Installing Flipper-PeerTalk (0.0.4)
Installing Flipper-RSocket (1.4.3)
Installing FlipperKit (0.138.0)
Installing GoogleAnalytics (3.20.0)
Installing GoogleAppMeasurement (8.10.0)
Installing GoogleDataTransport (9.1.2)
Installing GoogleTagManager (7.4.0)
Installing GoogleUtilities (7.7.0)
Installing OpenSSL-Universal (1.1.1100)
Installing Permission-Notifications (3.2.0)
Installing PromisesObjC (2.0.0)
Installing RCT-Folly (2020.01.13.00)
Installing RCTRequired (0.64.1)
Installing RCTTypeSafety (0.64.1)
Installing RNDateTimePicker (3.5.2)
Installing RNDeviceInfo (8.4.5)
Installing RNFBAnalytics (14.2.2)
Installing RNFBApp (14.2.2)
Installing RNFBCrashlytics (14.2.2)
Installing RNFS (2.18.0)
Installing RNFastImage (8.5.11)
Installing RNGestureHandler (1.10.3)
Installing RNInAppBrowser (3.6.3)
Installing RNPermissions (3.2.0)
Installing RNReanimated (2.2.3)
Installing RNSVG (12.1.1)
Installing RNScreens (2.15.2)
Installing RNVectorIcons (8.1.0)
Installing React (0.64.1)
Installing React-Core (0.64.1)
Installing React-CoreModules (0.64.1)
Installing React-RCTActionSheet (0.64.1)
Installing React-RCTAnimation (0.64.1)
Installing React-RCTBlob (0.64.1)
Installing React-RCTImage (0.64.1)
Installing React-RCTLinking (0.64.1)
Installing React-RCTNetwork (0.64.1)
Installing React-RCTSettings (0.64.1)
Installing React-RCTText (0.64.1)
Installing React-RCTVibration (0.64.1)
Installing React-callinvoker (0.64.1)
Installing React-cxxreact (0.64.1)
Installing React-jsi (0.64.1)
Installing React-jsiexecutor (0.64.1)
Installing React-jsinspector (0.64.1)
Installing React-perflogger (0.64.1)
Installing React-runtimeexecutor (0.64.1)
Installing ReactCommon (0.64.1)
Installing SDWebImage (5.11.1)
Installing SDWebImageWebPCoder (0.8.4)
Installing SocketRocket (0.6.0)
Installing Yoga (1.14.0)
Installing YogaKit (1.18.1)
Installing boost-for-react-native (1.63.0)
Installing glog (0.3.5)
Installing hermes-engine (0.7.2)
Installing libevent (2.1.12)
Installing libwebp (1.2.1)
Installing nanopb (2.30908.0)
Installing react-native-blob-util (0.13.16)
Installing react-native-blur (0.8.0)
Installing react-native-encrypted-storage (4.0.2)
Installing react-native-flipper (0.138.0)
Installing react-native-geolocation-service (5.3.0-beta.3)
Installing react-native-maps (0.29.3)
Installing react-native-restart (0.0.22)
Installing react-native-safe-area-context (3.1.9)
Installing react-native-video (5.2.0)
Installing react-native-voice (3.2.2)
Installing react-native-webview (11.14.2)
Installing sparkfabrik-react-native-idfa-aaid (0.8.3)

@alfredarcifa
Copy link
Author

_LIBCPP_INLINE_VISIBILITY
__value_func& operator=(nullptr_t)
{
__func* __f = _f;
_f = nullptr;
if ((void*)__f == &_buf)
__f->destroy();
else if (__f)
__f->destroy_deallocate(); >>>> hermes-chrome-inspector-conn (16): EXC_BAD_ACCESS (code=1, address=0x464019d4a100)
return *this;
}

@alfredarcifa
Copy link
Author

alfredarcifa commented Mar 21, 2022

hermes-chrome-inspector-conn (20): EXC_BAD_ACCESS (code=EXC_I386_GPFLT)

And in flipper I see this error:
Debugging connection was closed. Reason: Websocket disconnected...

Plugin Status > Hermesdebuggerrn 0.138.0

versions/node/v12.22.8/lib/node_modules/react-devtools/node_modules/react-devtools-core

@alfredarcifa
Copy link
Author

alfredarcifa commented Mar 22, 2022

More info from console:

Error: Unknown device with ID 1
at WebSocketServer. (..../node_modules/metro-inspector-proxy/src/InspectorProxy.js:331:21)
at Generator.next ()
at asyncGeneratorStep (..../node_modules/metro-inspector-proxy/src/InspectorProxy.js:14:24)
at _next (..../node_modules/metro-inspector-proxy/src/InspectorProxy.js:36:9)
at ..../node_modules/metro-inspector-proxy/src/InspectorProxy.js:43:7
at new Promise ()
at WebSocketServer. (..../node_modules/metro-inspector-proxy/src/InspectorProxy.js:32:12)
at WebSocketServer. (..../node_modules/metro-inspector-proxy/src/InspectorProxy.js:342:24)
at WebSocketServer.emit (events.js:314:20)
at ..../metro-inspector-proxy/node_modules/ws/lib/WebSocketServer.js:91:14
..../node_modules/metro-hermes-compiler/src/emhermesc.js:81
throw ex;
^

RuntimeError: abort(TypeError [ERR_INVALID_ARG_TYPE]: The "string" argument must be of type string or an instance of Buffer or ArrayBuffer. Received an instance of Error). Build with -s ASSERTIONS=1 for more info.
at process.abort (..../metro-hermes-compiler/src/emhermesc.js:796:13)
at process.emit (events.js:314:20)
at processPromiseRejections (internal/process/promises.js:209:33)
at processTicksAndRejections (internal/process/task_queues.js:98:32)
error Command failed with exit code 7.

Version installed:

"name": "metro-inspector-proxy",
"version": "0.64.0",

@bfricka
Copy link

bfricka commented May 2, 2022

I had this issue on Android RN 0.67.4, Flipper 0.144.0. I ran ./gradlew clean and then rebuilt and everything started working again. Without the clean first, it continued to fail, even running the normal assemble debug task, and it was working fine when I left for the weekend. Not sure what changed, but perhaps doing an Xcode clean / rebuild might help?

@Nantris
Copy link

Nantris commented Jun 3, 2022

Same issue with Android RN 0.68.2 and Flipper 0.147.1.

@youniaogu
Copy link

I had this issue on Android RN 0.67.4, Flipper 0.144.0. I ran ./gradlew clean and then rebuilt and everything started working again. Without the clean first, it continued to fail, even running the normal assemble debug task, and it was working fine when I left for the weekend. Not sure what changed, but perhaps doing an Xcode clean / rebuild might help?

same issue and I try it, but useless
In my case with RN 0.68.1 and Flipper 0.149.0, crash android but ios is fine

@alfredarcifa
Copy link
Author

Unfortunately, I have the same issue!
I use iOS debug only, my other teammates are luckier and use Android debug.

@Nantris
Copy link

Nantris commented Sep 15, 2022

Continues with RN 69 and Flipper 161. This makes debugging a nightmare.

@Nantris
Copy link

Nantris commented Sep 18, 2022

When this issue occurs it also seems to be capable of corrupting the local application, necessitating a full uninstall and reinstall - but it happens quite frequently.

@Nantris
Copy link

Nantris commented Sep 20, 2022

Persists with Flipper 166.

@Med-Amine-Fredj
Copy link

same issue on expo sdk 46 and flipper 0.166.0

@Nantris
Copy link

Nantris commented Sep 28, 2022

For Expo users, upgrade the following package to the specified version:

"react-native-reanimated": "~2.10.0",

Even though Expo says to use 2.9.x, it causes crashing far in excess of Flipper's normal amount of crashing (which is still a lot unfortunately.)

@Nantris
Copy link

Nantris commented Sep 29, 2022

@Med-Amine-Fredj what's your question?

@tchiteu
Copy link

tchiteu commented Oct 18, 2022

I had the same problem, just updating my flipper client to v0.171.0 and this works fine!

@nguyen315
Copy link

In my case, the old version of Flipper uses RSocket, which unfortunately is not compatible with the WebSocket implementation of Hermes.
For IOS, use_flipper!({ 'Flipper' => '0.149.0' }) in Podfile fix the crash issue for me.

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

7 participants