0

I've implemented into my app a barcode detection. It works on all devices i've tryed, but today i've noticed that it doesn't work on an Android 4.3 device. Involved piece of code is

 barcodeDetector = new BarcodeDetector.Builder(getContext()).setBarcodeFormats(Barcode.QR_CODE).build();
 if (!barcodeDetector.isOperational()) {
    //TODO something gone wrong
 } else {
    //init SurfaceView and callbacks
 }

and isOperational on that device return false. This is error log:

 W/DynamiteModule: Local module descriptor class for com.google.android.gms.vision.dynamite not found.
Failed to retrieve remote module version.
com.myapp W/GooglePlayServicesUtil: Google Play services out of date.  Requires 10260000 but found 4452036
com.myapp I/DynamiteModule: Considering local module com.google.android.gms.vision.dynamite:0 and remote module com.google.android.gms.vision.dynamite:0
com.myapp E/ActivityThread: Failed to find provider info for com.google.android.gms.chimera
com.myapp E/BarcodeNativeHandle: Error creating remote native handle
com.google.android.gms.dynamite.DynamiteModule$zza: No acceptable module found. Local version is 0 and remote version is 0.

how can i handle this error correctly for make barcode detection works?

giozh
  • 9,868
  • 30
  • 102
  • 183

1 Answers1

0

I believe you should update google play services on your emulator/phone.

Look at this post for more information

  • Thank you. That solution seems to be for emulators, but i have this problem on a real device, so i need to implement a solution that works when user with my application face this problem. – giozh Jul 25 '18 at 09:21
  • Prompt the user to update google play services - https://stackoverflow.com/a/43648662/1581432 – user1581432 Jul 25 '18 at 19:19