android-vision
android-vision copied to clipboard
Does not read the QR on Huawei devices
The activity works fine, I even see the camera working good but there is no text scan. My phone is a Huawei P10 Lite (WAS-LX1AC432B198)
Same problem occurred on Huawei MediaPad T3 10(AGS-W09C229B251). Until May 10th, the device could read the QR. But since May 11th, the device hasn't read.
Same problem here. Lots of users had reported this problems occurred on Huawei over the past few days.
Yes,
Same problem here, with the test app and our app which is in production (available in Google Store). HUAWEI FRD-L09 (Android 7.0, API 24) (Honor 8)
+1
Huawei GR5 2017 (Premium) Android Version 7.0
I manage to let it work by...
inform my user (internal user) to download application with WiFi only! Becuase, there is some setting in Huawei can limit background service on other connectivity except WiFi.
But this is just a workaround, plz help us fix this issues.
Not working for me this workaround
Yeah for some device (but still Huawei) what I have done to fix this issue so far from my above comment is
- ask them to check gms service, is there any update https://play.google.com/store/apps/details?id=com.google.android.gms
- if already update, I ask them to clear google play service cache
- open an app and wait for some time (5 min.), I have experienced that at first, it does not operate but wait for a while it does (it's due to a network).
additional but not necessary for above workaround I also, update my AndroidManifest.xml by adding the following one
<meta-data
android:name="com.google.android.gms.vision.DEPENDENCIES"
android:value="barcode" />
The problem of this issue is gotten on all the Huawei with an equal or higher os than 7. Google Play Services has been uploaded to 12.6.85 to solve the problem on Maps (apps like Uber were getting an error) but it seems that the error persist on the MobileVision library. Do anybody knows an email to report the google team?
I'm seeing the same issue, but apparently only on devices with the hardware support level of "Limited" (which unfortunately means a lot of Huawei devices). Not seeing the same issue on an older P8 lite ("Legacy").
Meanwhile all devices updated to the fixing version 12.6.85, however one still needs to clear the app data of the Play Services manually in order for the vision lib to work again.
Same problem on Huawei P10 Lite
Same problem on Huawei P9 Lite and on Huawei P20
@ngallazzi @andreasciarra try to clear the app data of the Play Services (cache is not sufficient) and you should be back to normal.
I solved it adding in the manifest what @sattha said
<meta-data android:name="com.google.android.gms.vision.DEPENDENCIES" android:value="barcode" />
And deleting all data and cache of Google Play Services and Google Play services for Instant Apps.
Hi @bertam, could you do this test? Reboot your Huawei and then, try to scan the barcode again. In my case the error is there again...
You are right @kiketen , I have to delete all the data and cache again in order to make it work.
It's totally crazy what is happening with this bug...we cannot solve it by ourselves and Huawei and Google haven't solved it yet...We are getting errors with 10% of our users and it is something to worry about... We'll continue waiting for a solution
I temporarily solved the problem on my phone (Huawei P10 Lite WAS-LX1AC432B198) following @bertam instructions. I tested for @kiketen the rebooting behaviour and I can confirm that after the rebooting I had to delete all the data and cache again in order to make it work.
I have several crash reports in Firebase Crashlytics for six Huawei DLI-TL20 running Android 7.0, with almost the same stacktrace. With diferent version of Play Service, before uninstalling (clearing cache) - getting exceptions, and after installing (reinstalling) SAME version of Play Service and same app.
But there is no export button in Crashlytics console :(
since may 13 2018 every Play Service update...
public boolean checkBarcodeDetector(Context context) {
BarcodeDetector detector = new BarcodeDetector.Builder(context)
.setBarcodeFormats(Barcode.DATA_MATRIX | Barcode.PDF417)
.build();
return detector != null && detector.isOperational();
}
Fatal Exception: java.lang.RuntimeException Unable to resume activity {scanner.ScannerActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'boolean com.google.android.gms.e.a.b()' on a null object reference android.app.ActivityThread.performResumeActivity (ActivityThread.java:3639) com.android.internal.os.ZygoteInit.main (ZygoteInit.java:832) Caused by java.lang.NullPointerException
Click to expand
> Attempt to invoke virtual method 'boolean com.google.android.gms.e.a.b()' on a null object reference > scanner.ScannerActivity.checkBarcodeDetector (ScannerActivity.java:550) > scanner.ScannerActivity.hasAllNecessaryCapabilities (ScannerActivity.java:509) > scanner.ScannerActivity.resumeCamera (ScannerActivity.java:436) > scanner.ScannerActivity.onResume (ScannerActivity.java:359) > android.app.Instrumentation.callActivityOnResume (Instrumentation.java:1279) > android.app.Activity.performResume (Activity.java:7017) > android.app.ActivityThread.performResumeActivity (ActivityThread.java:3614) > android.app.ActivityThread.handleResumeActivity (ActivityThread.java:3679) > android.app.ActivityThread.handleLaunchActivity (ActivityThread.java:2879) > android.app.ActivityThread.handleRelaunchActivity (ActivityThread.java:4777) > android.app.ActivityThread.-wrap20 (ActivityThread.java) > android.app.ActivityThread$H.handleMessage (ActivityThread.java:1576) > android.os.Handler.dispatchMessage (Handler.java:105) > android.os.Looper.loop (Looper.java:156) > android.app.ActivityThread.main (ActivityThread.java:6595) > java.lang.reflect.Method.invoke (Method.java) > com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run (ZygoteInit.java:942) > com.android.internal.os.ZygoteInit.main (ZygoteInit.java:832) > > Caused by java.lang.NullPointerException > Attempt to invoke virtual method 'boolean com.google.android.gms.e.a.b()' on a null object reference > ScannerActivity.checkBarcodeDetector (ScannerActivity.java:550)Queue java.lang.Object.wait (Object.java) java.lang.Thread.parkFor$ (Thread.java:2142) sun.misc.Unsafe.park (Unsafe.java:325) java.util.concurrent.locks.LockSupport.park (LockSupport.java:161) java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await (AbstractQueuedSynchronizer.java:2035) java.util.concurrent.PriorityBlockingQueue.take (PriorityBlockingQueue.java:519) io.fabric.sdk.android.services.concurrency.DependencyPriorityBlockingQueue.performOperation (DependencyPriorityBlockingQueue.java:197) io.fabric.sdk.android.services.concurrency.DependencyPriorityBlockingQueue.get (DependencyPriorityBlockingQueue.java:236) io.fabric.sdk.android.services.concurrency.DependencyPriorityBlockingQueue.take (DependencyPriorityBlockingQueue.java:65) io.fabric.sdk.android.services.concurrency.DependencyPriorityBlockingQueue.take (DependencyPriorityBlockingQueue.java:46) java.util.concurrent.ThreadPoolExecutor.getTask (ThreadPoolExecutor.java:1058) java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1118) java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:607) java.lang.Thread.run (Thread.java:776)
TubeSockWriter-174 java.lang.Object.wait (Object.java) java.lang.Thread.parkFor$ (Thread.java:2142) sun.misc.Unsafe.park (Unsafe.java:325) java.util.concurrent.locks.LockSupport.park (LockSupport.java:161) java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await (AbstractQueuedSynchronizer.java:2035) java.util.concurrent.LinkedBlockingQueue.take (LinkedBlockingQueue.java:413) bgk.a (:com.google.android.gms.dynamite_dynamitemodulesc@[email protected] (040306-197041431):53) bgl.run (:com.google.android.gms.dynamite_dynamitemodulesc@[email protected] (040306-197041431):5) java.lang.Thread.run (Thread.java:776)
Same issue in HUAWEI GR5 2017 EMUI v5.0
It seems related to #353 . So, no QR reader, no Ocr Detector, no face recognition on Huawei...
Is there another (better) place where to ask for a fix? on Google or Huawei sites?
Hi i wrote here https://issuetracker.google.com/issues/80454351 maybe someone has more information about this problem pls write here anything what can be important or helpfull thx
Hi All,
Is this issue resolved? I am still facing the issue. Is there any work around?
@abdulsattar-sit no it's still open https://issuetracker.google.com/issues/80454351 Google hasn't assigned it until a few hours ago. And it has medium priority
Google rep says the roll out of the fixed v12.8.62 could happen by the end of this month, with the risk of delays https://issuetracker.google.com/issues/80454351
on my Huawei P20 Android 7.0 was problem when I tried to scan QR code with inner Android classes and that was not working. After reading the comments, I cleaned cash in all default apps of the device connected to Google Play and the scanning began to work. Haliluya!
Is there any way to know if this bug occurs programmatically? So I can handle it in the UI?
I don't know how exactly the bug occurred. Maybe, if you can clean the cash in play service apps, you can handle it. However, in moment the bug happening, I tried Zxing library for reading QR codes on the same device, and it worked. воскресенье, 01 июля 2018г., 08:02 +02:00 от ZachBublil [email protected] :
Is there any way to know if this bug occurs programmatically? So I can handle it in the UI? — You are receiving this because you commented. Reply to this email directly, view it on GitHub , or mute the thread .
is there a possible way of making this work without having to clear cache ? i.e. could it work once Google releases an update ? (yes, got the issue as well, Huawei P10, Google Play Services v12.8.74)
Google has finally released an update that solves this bug yet. The app version is 12.8.74. If you have this version of Play Services, the barcode reader should work 🗡
I am still getting this issue in one plus 3T while trying barcode scanner in a sample app.I do have the latest google play services version 12.8.74 in my device.