-
-
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
🐛App crashed after scanning a qrcode #2189
Comments
+1 In my case, the app only crashes after the first QR scan. Once I restart the app, it proceeds to scan QR codes without any crash. I just came across this issue yesterday. I'll definitely share any findings under this thread. |
|
@mrousavy please take a look at this |
@apadev666 why? |
@manuelbieh any ideas why its happening? |
@apadev666 this could happen for a number of reasons. Firstly, it could happen if you don't configure your camera properly. Try removing all the props except for the required ones and try adding them one-by-one to see what breaks. |
There is no apparent bug related to the scanner functionality per-se. |
I don't have any prop just standard initialization used from docs |
|
it can crash for the first time but also after for example 10 attempts |
+1 |
I looked up issue 2090 and someone answered that changing react-native-vison-camera to version 3.5.1 works fine. So I tried lowering the version. Fortunately, I scanned the qrcode from afternoon to now, the app will not crash when scanning the qrcode.((I tried upgrading to v3.6.6 and v3.6.8 yesterday, and also tried downgrading to v3.6.0, but there was always a crash) |
@sunnystarh it's possible to update your log with more details before |
can you guys try those steps and lmk if works
this seems to be related to mlkit itself |
@rodgomesc can you tell me please what is the latest version? |
@sunnystarh I can confirm downgrading to |
@yasirlateef @sunnystarh @rodgomesc for me event downgrade is not working(( |
@rodgomesc now Im using 23.44.14 version of google play service |
If it were related to the package, downgrading would make a difference for you as well. |
@yasirlateef it can be after some period, can you please try to scan barcode 10-15 times? |
@rodgomesc I have tried also clean cache method as you mentioned, but the same crash( |
hey @apadev666 please stop spamming this is not a chat, try to write more sentences in same message |
are you sure? you answered this on the same minute that yasirlateef did yoy tried that version before? |
W W0000 00:00:1700572096.722037 12915 abi_method_util.h:33] not supported: TfLiteInterpreterGetTensor: TF Lite in Google Play services has stable ABI version 1.11.0 which is less than the required version 1.13.0.
2023-11-21 17:08:17.626 12211-12211 CameraView com.gingy I Updating CameraSession... here is logcat report @rodgomesc PS sorry), yes I've tried many different versions also but its not working |
@apadev666 You logs indicate no errors thrown from VisionCamera itself. The only exception I can see in your logs is:
It shows that the crash is coming from something related to your JSX/Styles. I would say you're trying to use style properties which are not allowed. It's exactly why downgrading won't do any good for you because this thread isn't relevant to your issue. |
@yasirlateef can it be that I'm using Camera inside bottom sheet? also here is other log that I'm getting Cmdline: com.gingy |
can you guys please test if this change solves the issue for you? @yasirlateef @apadev666
"dependencies": {
"react-native-vision-camera": "github:rodgomesc/react-native-vision-camera#cad3699"
}
|
@rodgomesc do I need to remove node modules and after package json update call yarn install? after this useCameraPermission and other hooks cant be found |
updated my previous post with a step by step Note: even with typescript complaining about not found react-native this is just a typescript thing, please ignore and run the app |
@Hector-Chong fail on build:
|
You should import
|
@Hector-Chong |
Still happening here :/ using same version
|
Hey all - does #2204 fix your issue? |
Please change this locally and test it. |
@mrousavy Hello! I tried this patch, but it didn't solve the problem. But this helped |
Ah - gotcha - @Hector-Chong could you please create a PR instead of just posting random patches/diffs here? Appreciate it, thanks! |
Honestly I am not 100% sure if this is a true fix though, because once the |
No one of those solved to me :/
|
I've added #2213 with more information there. |
This fix seems to work for me |
It works for me too |
Thank you @Hector-Chong |
Have you observed an ANR with your fix? When
We use sentry to log errors. Here is some of our sentry log: |
It is known out there that using Here is some information on Stack Overflow. |
Sadly, I've not experienced either an ANR or another crash within my project. |
I need logs for that. |
Here is our sentry logs.
|
That's a stacktrace, not a log. Do you have native logs in Sentry? |
Yea, this is because for some reason we are deadlocking on the Otherwise I don't have the time to debug this right now, maybe in a few days or weeks. |
Here are some of the
|
Any updates? Have the latest releases fixed this issue? |
+1 |
@MMYurt, nope, still reproducible in v3.7.0. |
@parlet Do you add 'VisionCamera_enableCodeScanner=true' to gradle.properties? I just tried the latest version, 3.7.1, and it worked fine. However, I first uninstalled the preview version of the app, updated the node modules, cleaned the metro cache, and then tried it. |
@Serck96, yes, I did.
I suppose it doesn't hurt, but that's probably not what it is. It's possible that you haven't encountered this problem due to its somewhat limited reproducibility. This issue may also depend on the specific devices used and the exact steps involved. Others have reported reproducing this issue in v3.7.0 as well. By the way, I now see this issue is closed. |
What's happening?
I have a crash after scanning the QR code. I haven't found the reason yet. I have released the relevant code and logs. I hope someone can answer it.
Reproduceable Code
Relevant log output
Camera Device
Device
honor 70
VisionCamera Version
v3.6.4
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: