-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
🐛 Fatal signal: SIGSEGV when using runAsync
in Frame Processor
#2589
Comments
If you remove |
Yes, if I remove But for me this crash only happens on production mode, on dev mode everything works really fine. |
runAsync
in Frame Processor
@mrousavy I tested it and no, #2591 PR doesn't fix the issue. I have cleared the project using In this test I noticed an interestant thing: If camera preview is stretched when I open the app it doesn't crash but |
Hi, @nonam4 - you say "If I use any reanimated functions the app don't crash but nothing inside runAsync are called." - what does this mean? Could you describe the steps you use to use reanimated functions? |
@chrfalch I mean that this code (without any reanimated method) works fine:
But this (with reanimated methods) doesn't:
Neither this:
If I'm not using reanimated with vision camera (no matter if it's installed on my project) Another thing that makes my app crash is adding
|
@nonam4 What versions of Reanimated / React Native SVG are you using? |
@jonjamz In this issue I'm using reanimated version of example app but in my real app I'm using latest version of all dependencies (I always check for dependencies updates if anything is wrong before opening issues). Here's my whole
|
@mrousavy I made a little progress, at least my app is not crashing anymore... This is my code at this moment. Maybe there's a problem with |
hay @nonam4 i am using your lib react-native-vision-camera-face-detector, but still get error that say "Frame Processor Error: Regular javascript function '' cannot be shared. Try decorating the function with the 'worklet' keyword to allow the javascript function to be used as a worklet., js engine: VisionCamera", i am following example from documentation, can you help me, btw its a great lib this is the code :
|
@robertyulisman I had the same problem. If you are using reanimated in your project, you need to add |
@bglgwyng still not working, my app get crashed |
Sorry for the delay, @nonam4 - but why would you create a reanimated component of the camera? This is AFAIK not something that should be needed (wrap it in a parent animated view if you want to animate it) and might lead to undefined behaviors (as you are seeing):
if you don’t use the above and add react-native-svg - does your app still crash? |
@chrfalch I’m following example app and it have a reanimated camera. About crashes, I found a workaround. I suppose my app was crashing because of |
@chrfalch it is - that's for when you want to animate |
I think this has been fixed in react-native-worklets-core 1.x.x.! 🎉 |
@mrousavy bad news, it's not fixed, I tried all the solutions found here and more, and it doesn't work in react-native-worlets-core 1.3.3 |
What's happening?
Trying to open the app on production mode
react-native run-android --variant=release
makes app crash when opening camera view.I'm using example app, didn't add any new library but I removed some props in
CameraPage.tsx
I don't need (capture photo button, etc...).IMPORTANT:
This crash only happens if the app is fresh installed on the device or if you clean app data and open app.
If you keep reopening app after some crashes (in my case 2 crashes) there's no crash anymore BUT
runAsync
is NOT called. Everything inside frame processor is called exceptrunAsync
.EDIT:
Fatal signal
crash changes, they are not always the same, I tryed reinstalling the app right now and crash code error wasFatal signal 11 (SIGSEGV), code 2, fault addr 0xc87f3f60 in tid 27643 (ionCamera.video)
Some notes in my real app:
If I use any
reanimated
functions the app don't crash but nothing insiderunAsync
are called.If I try to add any
svg
fromreact-native-svg
in my app it crash with a similar error in this issue. Doesn't matter if is reaniamted creating a svg or if I just import and add it to screen, both ways crash with a similar error:Reproduceable Code
Relevant log output
Camera Device
Device
Galaxy J5 Android 8
VisionCamera Version
3.9.0
Can you reproduce this issue in the VisionCamera Example app?
Yes, I can reproduce the same issue in the Example app here
Additional information
The text was updated successfully, but these errors were encountered: