-
Notifications
You must be signed in to change notification settings - Fork 375
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Build failure: duplicate entry: com/google/android/gms/auth/api/signin/zzc.class #301
Comments
@ccuilla Correct, this SDK depends on Google Play Services. The OneSignal Android native SDK version 3.6.0 part of this SDK requires a minimum of 10.2.1 but will use up to 11.2.X if it is available on your system. I recommend checking out the following troubleshooting section to resolve the version mismatches. |
Thanks. I'll check out that document. |
@ccuilla did you find the solution. I'm having the same error (also coming from Expo) |
@flieks Yes, we simply back-versioned a couple things. I'll try to find the changes we made. This might be ugly, but it works for us. We actually change from:
to:
|
By the way we specifically do this:
|
@ccuilla awesome. Where do you put that replace-in-file code? In gulp or some post build script? |
Seems to be working when replaced with your code. Thanks alot |
Yeah, sorry we made a npm script like this in our package.json:
Note this would be a PRE-build step. |
perfect, thanks |
thanks a lot @ccuilla I can confirm this solution works fine with Expo SDK 23 ejected! But not sure to understand why it actually works, because @jkasten2 said:
and 9.8.0 is not > 10.2.1 @jkasten2 would you please explain if this solution is good enough? Also worth mentionning that it would be cool to have a clear integration path with this lib and Currently, Expo offers an easy push system that works out of the box as long as they build the app themselves, but if you need to eject, you can't use anymore. So it's likely in the future more Expo users will be looking for alternative push notifications libraries like this one |
@ccuilla I've found another more elegant solution to the same problem In build.gradle add this before
or you can add as dependency:
|
Thanks @slorber , I was stuck on this issue since this morning. |
np @coolprobn btw for those coming from Expo It seems we often get dependency version problems on support libraries too. This thread might help: https://forums.expo.io/t/detached-expo-on-android-sdk-build-tools-and-support-library-versions/5504 |
I also ran into this issue, however, I also wanted to use react-native-background-geolocation, which depends on play-services >=11.2.0 Instead of rolling back the gcm, analytics, and location to 9.8.0, I was able to get all three (onesignal, expo, and background-geolocation to work together by upgrading all of expo's dependencies to 11.2.0:
You can check what dependencies you need to upgrade by: |
You can also add the OneSignal-Gradle-Plugin which will automatically align the versions between these dependencies. Feel free to reply if either of these two solutions do not work. |
@jkasten2 none of them worked for me |
I'm getting this issue while trying to build into an detached Expo React Native app. Googling around, it seems this could be related to a mismatch of Google Play Services versions. Are you guys depending on Google Play Services. If so, what version. And could I potentially back-version that without issues?
The text was updated successfully, but these errors were encountered: