Firebase Messaging 20.1.0 results in duplicate classes (Dagger) (Ref: 712)

[REQUIRED] Step 2: Describe your environment

  • Android Studio version: 3.5.3
  • Firebase Component: Messaging
  • Component version: 20.1.0

[REQUIRED] Step 3: Describe the problem

After updating our app from Firebase Messaging version 20.0.1 to version 20.1.0 we are now receiving duplicate class errors regarding Dagger. Our app uses Dagger 1.2.5. This appears to be related the resolution of Issue 712.

Errors are as follows:

  • Duplicate class dagger.Lazy found in modules dagger-1.2.5.jar (com.squareup.dagger🗡️1.2.5) and dagger-2.24.jar (com.google.dagger🗡️2.24)
  • Duplicate class dagger.MembersInjector found in modules dagger-1.2.5.jar (com.squareup.dagger🗡️1.2.5) and dagger-2.24.jar (com.google.dagger🗡️2.24)
  • Duplicate class dagger.Module found in modules dagger-1.2.5.jar (com.squareup.dagger🗡️1.2.5) and dagger-2.24.jar (com.google.dagger🗡️2.24)
  • Duplicate class dagger.Provides found in modules dagger-1.2.5.jar (com.squareup.dagger🗡️1.2.5) and dagger-2.24.jar (com.google.dagger🗡️2.24)

Steps to reproduce:

What happened? How can we make the problem occur?

Add Dagger 1.2.5 and Firebase Messaging 20.1.0 dependencies to your app

2 thoughts on “Firebase Messaging 20.1.0 results in duplicate classes (Dagger) (Ref: 712)