googlesamples / googlesamples/mlkit

[Bug report] Duplicate class com.google.firebase.iid.FirebaseInstanceIdReceiver found in modules jetified-firebase-iid-20.1.5-runtime and jetified-firebase-messaging-24.0.3-runtime

Open
#887 2 comments 0 reactions 1 assignee Assigned to @zhouyiself View on GitHub
Dominant language
Kotlin
Stars
4.3k
Forks
3.1k
PR merge metrics
No merged PRs in 30d

Description

I encountered a duplicate class error after importing the following dependency:

`implementation 'com.google.mlkit:linkfirebase:17.0.0'`

I am using the following environment:

**Firebase BOM version: 33.5
Firebase Messaging version: 24.0.3**
Purpose of using com.google.mlkit:linkfirebase: I am working on a custom image labeling model using TensorFlow, following the ML Kit guidelines from Google.
After adding com.google.mlkit:linkfirebase, the following error occurred:

_Duplicate class com.google.firebase.iid.FirebaseInstanceIdReceiver found in modules jetified-firebase-iid-20.1.5-runtime (com.google.firebase:firebase-iid:20.1.5) and jetified-firebase-messaging-24.0.3-runtime (com.google.firebase:firebase-messaging:24.0.3)_

**Question:**

I noticed that the last update to the linkfirebase API in the ML Kit release notes was on 01/25/2022. Is there any workaround to resolve this issue immediately? Additionally, if the root cause of this error is related to the outdated com.google.mlkit:linkfirebase library, I would like to suggest updating this library to resolve compatibility issues with the latest versions of Firebase dependencies.

Thank you very much!

**SDK Info:**
- com.google.mlkit:linkfirebase:17.0.0
- com.google.mlkit:image-labeling-custom:17.0.3
- com.google.firebase:firebase-bom:33.5.0
- com.google.firebase:firebase-messaging

**Smartphone:**
n/a

**Development Environment:**
n/a

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.