Google-signin: Android: React-Native Link Configuration Outdated

Created on 1 Oct 2018  Â·  9Comments  Â·  Source: react-native-google-signin/google-signin

Running react-native link results in app\build.gradle having:

compile project(':react-native-google-signin')

instead of the desired:

implementation(project(":react-native-google-signin")){
    exclude group: "com.google.android.gms" // very important
}

I can look into doing a PR later this week perhaps, but quite snowed under right now.

Steps to Reproduce

react-native init
npm i --save react-native-google-signin
react-native link react-native-google-signin

Environment

Please provide the version of your

  • react-native - 0.57.1
  • react-native-google-signin - RC6
  • gradle 4.6
  • gradle plugin 3.2.0
🔦 Help Wanted 💥 Build Issue

All 9 comments

I too was stumped by this. Cannot proceed with adding this package. Hope to get the updated docs soon!

@booleanBoy I agree.

I further got a build error
<project.src>/node_modules/react-native-google-signin/android/src/main/java/co/apptailor/googlesignin/RNGoogleSigninPackage.java:25: error: method does not override or implement a method from a supertype
Refer Remove override of createJSModules #515

Partial environment:
"firebase": "^5.5.4",
"react": "16.6.0-alpha.8af6728",
"react-native": "^0.57.3",
"react-native-google-signin": "^0.10.0",
"react-navigation": "^2.18.0"``

@booleanBoy thanks for filing the issue, can you please expand on why

implementation(project(":react-native-google-signin")){
    exclude group: "com.google.android.gms" // very important
}

is the desired form? Thanks.

compile project(':react-native-google-signin')

compile has been deprecated in gradlew 3.0 @vonovak

https://developer.android.com/studio/build/dependencies?utm_source=android-studio#dependency_configurations

This is not controlled by us, there was a PR recently merged by React-Native which will fix this, for now we have to change it manually until that commit lands in a release.

https://github.com/facebook/react-native/pull/20853

@AndreiCalazans I think this issue is not about compile / implementation but about the

exclude group: "com.google.android.gms" // very important part

Indeed it's about that the exclude group: "com.google.android.gms" // very important part, because that's what the Android manual installation instructions say you should do, but the automatic react-native link process results in compile project(':react-native-google-signin') only

I assumed both of these cannot be correct?

@booleanBoy the exclude group: "com.google.android.gms" is actually not needed (the google dependency version can be specified as seen here ), but we need to improve the docs there a little bit.

Well. That thought stuck me too. That's what the library writer specified
in their integration instruction... I found that that's not necessary at
all.

Please close the issue.
Thanks :)

On Sat 3 Nov, 2018, 5:36 PM Vojtech Novak <[email protected] wrote:

@booleanBoy https://github.com/booleanBoy thanks for filing the issue,
can you please expand on why

implementation(project(":react-native-google-signin")){
exclude group: "com.google.android.gms" // very important
}

is the desired form? Thanks.

—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/react-native-community/react-native-google-signin/issues/537#issuecomment-435582809,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AKi9Ieb2RxRJCATJYn-MzCoQ5JkaqhDrks5urYbcgaJpZM4XBj35
.

Was this page helpful?
0 / 5 - 0 ratings