EvanBacon / expo-native-firebase

🔥 Native Firebase Expo App (iOS, Android) Demo for Firestore, Notifications, Analytics, Storage, Messaging, Database 🚨
211 stars 41 forks source link

Error:(5, 8) error: duplicate class: host.exp.exponent.BuildVariantConstants #4

Closed ethanyuwang closed 6 years ago

ethanyuwang commented 6 years ago

Followed all steps but have this problem:

Information:Gradle tasks [:app:assembleDevDevRemoteKernelProdDebug, :react-native-firebase:assembleDebug]
/Users/ethanwang/Github/reactnative/Glever/android/app/src/devRemoteKernel/java/host/exp/exponent/BuildVariantConstants.java
Error:(5, 8) error: duplicate class: host.exp.exponent.BuildVariantConstants
/Users/ethanwang/Github/reactnative/Glever/android/app/src/dev/java/host/exp/exponent/BuildVariantConstants.java
Error:(5, 8) error: duplicate class: host.exp.exponent.BuildVariantConstants
Error:Execution failed for task ':app:compileDevDevRemoteKernelProdDebugJavaWithJavac'.
> Compilation failed; see the compiler error output for details.
Information:BUILD FAILED in 2s
Information:3 errors
Information:0 warnings
Information:See complete output in console
ethanyuwang commented 6 years ago

temporarily "fixed" it by reducing the number flavors to one:

  flavorDimensions "dev"

  productFlavors {
    // Define separate dev and prod product flavors.
    dev {
      // dev utilizes minSDKVersion = 21 to allow the Android gradle plugin
      // to pre-dex each module and produce an APK that can be tested on
      // Android Lollipop without time consuming dex merging processes.
      dimension "dev"
      minSdkVersion 21
    }
    ...
  }