@Chesterfield25

Как исправить дублирование классов?

Очистка кэша с перезагрузкой не помогает.
64218d24243cc905709841.png

Лог ошибки

> Task :app:checkDebugDuplicateClasses FAILED
Execution failed for task ':app:checkDebugDuplicateClasses'.
> A failure occurred while executing com.android.build.gradle.internal.tasks.CheckDuplicatesRunnable
   > Duplicate class com.google.android.gms.internal.measurement.zzhx found in modules jetified-play-services-measurement-base-20.1.2-runtime (com.google.android.gms:play-services-measurement-base:20.1.2) and jetified-play-services-measurement-impl-19.0.0-runtime (com.google.android.gms:play-services-measurement-impl:19.0.0)
     Duplicate class com.google.android.gms.internal.measurement.zzmz found in modules jetified-play-services-measurement-base-20.1.2-runtime (com.google.android.gms:play-services-measurement-base:20.1.2) and jetified-play-services-measurement-impl-19.0.0-runtime (com.google.android.gms:play-services-measurement-impl:19.0.0)
     Duplicate class com.google.android.gms.internal.measurement.zzna found in modules jetified-play-services-measurement-base-20.1.2-runtime (com.google.android.gms:play-services-measurement-base:20.1.2) and jetified-play-services-measurement-impl-19.0.0-runtime (com.google.android.gms:play-services-measurement-impl:19.0.0)
     Duplicate class com.google.android.gms.internal.measurement.zznb found in modules jetified-play-services-measurement-base-20.1.2-runtime (com.google.android.gms:play-services-measurement-base:20.1.2) and jetified-play-services-measurement-impl-19.0.0-runtime (com.google.android.gms:play-services-measurement-impl:19.0.0)
     Duplicate class com.google.android.gms.internal.measurement.zznc found in modules jetified-play-services-measurement-base-20.1.2-runtime (com.google.android.gms:play-services-measurement-base:20.1.2) and jetified-play-services-measurement-impl-19.0.0-runtime (com.google.android.gms:play-services-measurement-impl:19.0.0)
     Duplicate class com.google.android.gms.internal.measurement.zznd found in modules jetified-play-services-measurement-base-20.1.2-runtime (com.google.android.gms:play-services-measurement-base:20.1.2) and jetified-play-services-measurement-impl-19.0.0-runtime (com.google.android.gms:play-services-measurement-impl:19.0.0)
     Duplicate class com.google.android.gms.measurement.internal.zzga found in modules jetified-play-services-measurement-19.0.0-runtime (com.google.android.gms:play-services-measurement:19.0.0) and jetified-play-services-measurement-base-20.1.2-runtime (com.google.android.gms:play-services-measurement-base:20.1.2)
     Duplicate class com.google.android.gms.measurement.internal.zzhe found in modules jetified-play-services-measurement-base-20.1.2-runtime (com.google.android.gms:play-services-measurement-base:20.1.2) and jetified-play-services-measurement-impl-19.0.0-runtime (com.google.android.gms:play-services-measurement-impl:19.0.0)
     Duplicate class com.google.android.gms.measurement.internal.zzhf found in modules jetified-play-services-measurement-base-20.1.2-runtime (com.google.android.gms:play-services-measurement-base:20.1.2) and jetified-play-services-measurement-impl-19.0.0-runtime (com.google.android.gms:play-services-measurement-impl:19.0.0)
     Duplicate class com.google.android.gms.measurement.internal.zzhg found in modules jetified-play-services-measurement-base-20.1.2-runtime (com.google.android.gms:play-services-measurement-base:20.1.2) and jetified-play-services-measurement-impl-19.0.0-runtime (com.google.android.gms:play-services-measurement-impl:19.0.0)
     Duplicate class com.google.android.gms.measurement.internal.zzhh found in modules jetified-play-services-measurement-base-20.1.2-runtime (com.google.android.gms:play-services-measurement-base:20.1.2) and jetified-play-services-measurement-impl-19.0.0-runtime (com.google.android.gms:play-services-measurement-impl:19.0.0)
     Duplicate class com.google.android.gms.measurement.internal.zzhi found in modules jetified-play-services-measurement-base-20.1.2-runtime (com.google.android.gms:play-services-measurement-base:20.1.2) and jetified-play-services-measurement-impl-19.0.0-runtime (com.google.android.gms:play-services-measurement-impl:19.0.0)
     Duplicate class com.google.android.gms.measurement.internal.zzhj found in modules jetified-play-services-measurement-base-20.1.2-runtime (com.google.android.gms:play-services-measurement-base:20.1.2) and jetified-play-services-measurement-impl-19.0.0-runtime (com.google.android.gms:play-services-measurement-impl:19.0.0)
     Duplicate class com.google.android.gms.measurement.internal.zzio found in modules jetified-play-services-measurement-base-20.1.2-runtime (com.google.android.gms:play-services-measurement-base:20.1.2) and jetified-play-services-measurement-impl-19.0.0-runtime (com.google.android.gms:play-services-measurement-impl:19.0.0)
     Duplicate class com.google.android.gms.measurement.internal.zzit found in modules jetified-play-services-measurement-base-20.1.2-runtime (com.google.android.gms:play-services-measurement-base:20.1.2) and jetified-play-services-measurement-impl-19.0.0-runtime (com.google.android.gms:play-services-measurement-impl:19.0.0)
  • Вопрос задан
  • 1041 просмотр
Пригласить эксперта
Ответы на вопрос 1
i229194964
@i229194964
Веб разработчик
Попробуйте добавить следующую строку в блок зависимостей.
implementation('com.example.library:library:1.0.0') {
    exclude group: 'com.google.android.gms', module: 'play-services-measurement-base'
}
Ответ написан
Ваш ответ на вопрос

Войдите, чтобы написать ответ

Похожие вопросы