Failed resolution of: Lcom/google/android/gms/internal/zzdcc;
See original GitHub issueHere is my function :
private void initQRReader() {
try {
if (qrEader != null && qrEader.isCameraRunning()) {
qrEader.releaseAndCleanup();
}
qrEader = new QREader.Builder(context, binding.cameraView, new QRDataListener() {
@Override
public void onDetected(final String data) {
//My work
}
}).facing(QREader.BACK_CAM)
.enableAutofocus(true)
.height(binding.cameraView.getHeight())
.width(binding.cameraView.getWidth())
.build();
} catch (Exception e) {
e.printStackTrace();
toast("Sorry scanner is not supported on this device.");
}
}
And also followed onResume and onPause methods to make this thing work. Please help me.
Facing this issue. Suddenly it started with version 2.1.2 now its even not working with 2.1.1
01-03 10:22:22.227 6808-6808/com.Invoice.maker E/AndroidRuntime: FATAL EXCEPTION: main Process: com.Invoice.maker, PID: 6808 java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/android/gms/internal/zzdcc; at com.google.android.gms.vision.barcode.BarcodeDetector$Builder.<init>(Unknown Source:5) at github.nisrulz.qreader.BarcodeDetectorHolder.getBarcodeDetector(BarcodeDetectorHolder.java:38) at github.nisrulz.qreader.QREader.<init>(QREader.java:104) at github.nisrulz.qreader.QREader.<init>(QREader.java:40) at github.nisrulz.qreader.QREader$Builder.build(QREader.java:357) at com.invoiceapp.Main.CodeScannerActivity.initQRReader(CodeScannerActivity.java:109) at com.invoiceapp.Main.CodeScannerActivity.access$000(CodeScannerActivity.java:22) at com.invoiceapp.Main.CodeScannerActivity$1.onGranted(CodeScannerActivity.java:40) at com.invoiceapp.Main.BaseActivity$27.onPermissionsGranted(BaseActivity.java:3636) at com.kishan.askpermission.AskPermissionImp.requestAppPermissions(AskPermissionImp.java:71) at com.kishan.askpermission.ShadowFragment.onCreate(ShadowFragment.java:41) at android.app.Fragment.performCreate(Fragment.java:2489) at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:1237) at android.app.FragmentManagerImpl.addAddedFragments(FragmentManager.java:2407) at android.app.FragmentManagerImpl.executeOpsTogether(FragmentManager.java:2186) at android.app.FragmentManagerImpl.removeRedundantOperationsAndExecute(FragmentManager.java:2142) at android.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:2043) at android.app.FragmentManagerImpl.dispatchMoveToState(FragmentManager.java:3032) at android.app.FragmentManagerImpl.dispatchActivityCreated(FragmentManager.java:2979) at android.app.FragmentController.dispatchActivityCreated(FragmentController.java:178) at android.app.Activity.performCreate(Activity.java:7005) at android.app.Activity.performCreate(Activity.java:6990) at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1214) at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2731) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2856) at android.app.ActivityThread.-wrap11(Unknown Source:0) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1589) at android.os.Handler.dispatchMessage(Handler.java:106) at android.os.Looper.loop(Looper.java:164) at android.app.ActivityThread.main(ActivityThread.java:6494) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807) Caused by: java.lang.ClassNotFoundException: com.google.android.gms.internal.zzdcc at java.lang.VMClassLoader.findLoadedClass(Native Method) at java.lang.ClassLoader.findLoadedClass(ClassLoader.java:738) at java.lang.ClassLoader.loadClass(ClassLoader.java:363) at java.lang.ClassLoader.loadClass(ClassLoader.java:312) at com.google.android.gms.vision.barcode.BarcodeDetector$Builder.<init>(Unknown Source:5) at github.nisrulz.qreader.BarcodeDetectorHolder.getBarcodeDetector(BarcodeDetectorHolder.java:38) at github.nisrulz.qreader.QREader.<init>(QREader.java:104) at github.nisrulz.qreader.QREader.<init>(QREader.java:40) at github.nisrulz.qreader.QREader$Builder.build(QREader.java:357) at com.invoiceapp.Main.CodeScannerActivity.initQRReader(CodeScannerActivity.java:109) at com.invoiceapp.Main.CodeScannerActivity.access$000(CodeScannerActivity.java:22) at com.invoiceapp.Main.CodeScannerActivity$1.onGranted(CodeScannerActivity.java:40) at com.invoiceapp.Main.BaseActivity$27.onPermissionsGranted(BaseActivity.java:3636) at com.kishan.askpermission.AskPermissionImp.requestAppPermissions(AskPermissionImp.java:71) at com.kishan.askpermission.ShadowFragment.onCreate(ShadowFragment.java:41) at android.app.Fragment.performCreate(Fragment.java:2489) at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:1237) at android.app.FragmentManagerImpl.addAddedFragments(FragmentManager.java:2407) at android.app.FragmentManagerImpl.executeOpsTogether(FragmentManager.java:2186) at android.app.FragmentManagerImpl.removeRedundantOperationsAndExecute(FragmentManager.java:2142) at android.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:2043) at android.app.FragmentManagerImpl.dispatchMoveToState(FragmentManager.java:3032) at android.app.FragmentManagerImpl.dispatchActivityCreated(FragmentManager.java:2979) at android.app.FragmentController.dispatchActivityCreated(FragmentController.java:178) at android.app.Activity.performCreate(Activity.java:7005) at android.app.Activity.performCreate(Activity.java:6990) at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1214) at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2731) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2856) at android.app.ActivityThread.-wrap11(Unknown Source:0) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1589) at android.os.Handler.dispatchMessage(Handler.java:106) at android.os.Looper.loop(Looper.java:164) at android.app.ActivityThread.main(ActivityThread.java:6494) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807) Caused by: java.lang.NoClassDefFoundError: Failed resolution of: Lcom/google/android/gms/internal/zzbck; at com.google.android.gms.vision.barcode.BarcodeDetector$Builder.<init>(Unknown Source:5) at github.nisrulz.qreader.BarcodeDetectorHolder.getBarcodeDetector(BarcodeDetectorHolder.java:38) at github.nisrulz.qreader.QREader.<init>(QREader.java:104) at github.nisrulz.qreader.QREader.<init>(QREader.java:40) at github.nisrulz.qreader.QREader$Builder.build(QREader.java:357) at com.invoiceapp.Main.CodeScannerActivity.initQRReader(CodeScannerActivity.java:109) at com.invoiceapp.Main.CodeScannerActivity.access$000(CodeScannerActivity.java:22) at com.invoiceapp.Main.CodeScannerActivity$1.onGranted(CodeScannerActivity.java:40) at com.invoiceapp.Main.BaseActivity$27.onPermissionsGranted(BaseActivity.java:3636) at com.kishan.askpermission.AskPermissionImp.requestAppPermissions(AskPermissionImp.java:71) at com.kishan.askpermission.ShadowFragment.onCreate(ShadowFragment.java:41) at android.app.Fragment.performCreate(Fragment.java:2489) at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:1237) at android.app.FragmentManagerImpl.addAddedFragments(FragmentManager.java:2407) at android.app.FragmentManagerImpl.executeOpsTogether(FragmentManager.java:2186) at android.app.FragmentManagerImpl.removeRedundantOperationsAndExecute(FragmentManager.java:2142) at android.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:2043) at android.app.FragmentManagerImpl.dispatchMoveToState(FragmentManager.java:3032) at android.app.FragmentManagerImpl.dispatchActivityCreated(FragmentManager.java:2979) at android.app.FragmentController.dispatchActivityCreated(FragmentController.java:178) at android.app.Activity.performCreate(Activity.java:7005) at android.app.Activity.performCreate(Activity.java:6990) at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1214) at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2731) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2856) at android.app.ActivityThread.-wrap11(Unknown Source:0) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1589) at android.os.Handler.dispatchMessage(Handler.java:106) at android.os.Looper.loop(Looper.java:164) at android.app.ActivityThread.main(ActivityThread.java:6494) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807) Caused by: java.lang.ClassNotFoundException: Didn’t find class “com.google.android.gms.internal.zzbck” on path: DexPathList[[zip file “/data/app/com.Invoice.maker-g0I69RbPTxHTnyU9ounT5A==/base.apk”],nativeLibraryDirectories=[/data/app/com.Invoice.maker-g0I69RbPTxHTnyU9ounT5A==/lib/x86, /data/app/com.Invoice.maker-g0I69RbPTxHTnyU9ounT5A==/base.apk!/lib/x86, /system/lib, /vendor/lib]] at dalvik.system.BaseDexClassLoader.findClass(BaseDexClassLoader.java:125) at java.lang.ClassLoader.loadClass(ClassLoader.java:379) at java.lang.ClassLoader.loadClass(ClassLoader.java:312) at com.google.android.gms.vision.barcode.BarcodeDetector$Builder.<init>(Unknown Source:5) at github.nisrulz.qreader.BarcodeDetectorHolder.getBarcodeDetector(BarcodeDetectorHolder.java:38) at github.nisrulz.qreader.QREader.<init>(QREader.java:104) at github.nisrulz.qreader.QREader.<init>(QREader.java:40) at github.nisrulz.qreader.QREader$Builder.build(QREader.java:357) at com.invoiceapp.Main.CodeScannerActivity.initQRReader(CodeScannerActivity.java:109) at com.invoiceapp.Main.CodeScannerActivity.access$000(CodeScannerActivity.java:22) at com.invoiceapp.Main.CodeScannerActivity$1.onGranted(CodeScannerActivity.java:40) at com.invoiceapp.Main.BaseActivity$27.onPermissionsGranted(BaseActivity.java:3636) at com.kishan.askpermission.AskPermissionImp.requestAppPermissions(AskPermissionImp.java:71) at com.kishan.askpermission.ShadowFragment.onCreate(ShadowFragment.java:41) at android.app.Fragment.performCreate(Fragment.java:2489) at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:1237) at android.app.FragmentManagerImpl.addAddedFragments(FragmentManager.java:2407) at android.app.FragmentManagerImpl.executeOpsTogether(FragmentManager.java:2186) at android.app.FragmentManagerImpl.removeRedundantOperationsAndExecute(FragmentManager.java:2142) at android.app.FragmentManagerImpl.execPendingActions(FragmentManager.java:2043) at android.app.FragmentManagerImpl.dispatchMoveToState(FragmentManager.java:3032) at android.app.FragmentManagerImpl.dispatchActivityCreated(FragmentManager.java:2979) at android.app.FragmentController.dispatchActivityCreated(FragmentController.java:178) at android.app.Activity.performCreate(Activity.java:7005) at android.app.Activity.performCreate(Activity.java:6990) at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1214) at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2731) at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2856) at android.app.ActivityThread.-wrap11(Unknown Source:0) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1589) at android.os.Handler.dispatchMessage(Handler.java:106) at android.os.Looper.loop(Looper.java:164) at android.app.ActivityThread.main(ActivityThread.java:6494) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807)
Issue Analytics
- State:
- Created 6 years ago
- Reactions:3
- Comments:15 (4 by maintainers)
Top GitHub Comments
I meet the same issue and resolved it by adding “com.google.android.gms:play-services-vision” implementation ‘com.google.android.gms:play-services-vision:15.0.2’
I solved it adding: implementation ‘com.google.android.gms:play-services-vision:20.1.3’