EddyVerbruggen / nativescript-plugin-firebase

:fire: NativeScript plugin for Firebase
https://firebase.google.com
MIT License
1.01k stars 448 forks source link

Plugin with id 'com.google.gms.google-services' not found. #1882

Open Whip opened 2 years ago

Whip commented 2 years ago

My issue is identical to #278 but that was 5 years ago so maybe its different. I did try the things mentioned in that thread but no dice. Here's my case.

I have an app that was last updated last year. I decided to do an yearly maintenance update. I updated Android SDK, XCode, NS CLI, NS Core, theme and plugins. Then ran

ns build android

and got this error

Script '/Users/Whip/Documents/ProjectName/node_modules/@nativescript/firebase/platforms/android/include.gradle' line: 96
A problem occurred evaluating script.
Plugin with id 'com.google.gms.google-services' not found.

Command ./gradlew failed with exit code 1

Here are my dependencies

"dependencies": {
    "@nativescript-community/ui-collectionview": "^4.0.49",
    "@nativescript-community/ui-material-cardview": "^7.0.5",
    "@nativescript-community/ui-material-textfield": "^7.0.5",
    "@nativescript-community/ui-material-textview": "^7.0.5",
    "@nativescript/core": "^8.2.3",
    "@nativescript/firebase": "^11.1.3",
    "@nativescript/theme": "^3.0.2",
    "@nstudio/nativescript-checkbox": "^2.0.5",
    "@nstudio/nativescript-loading-indicator": "^4.1.2",
    "@triniwiz/nativescript-image-cache-it": "^7.0.14",
    "@triniwiz/nativescript-image-zoom": "^4.1.1",
    "@triniwiz/nativescript-toasty": "^4.1.3",
    "@triniwiz/nativescript-youtubeplayer": "^4.1.4",
    "nativescript-exit": "1.0.1",
    "nativescript-gif": "^5.0.0",
    "nativescript-material-icons": "^1.0.3",
    "nativescript-permissions": "^1.3.12",
    "nativescript-phone": "^3.0.3",
    "nativescript-ui-autocomplete": "^8.0.1",
    "nativescript-ui-sidedrawer": "^10.0.2"
  },
  "devDependencies": {
    "@nativescript/android": "~8.2.2",
    "@nativescript/ios": "~8.2.3",
    "@nativescript/webpack": "^5.0.5-rc.0"
  }

Can you help me with this?

weareframework commented 2 years ago

Same issue here

jeanpaulattard commented 2 years ago

I had that very same issue. I ended up downgrading to @nativescript/core to version 8.2.0 to continue working. Not sure what the problem with this version is

Whip commented 2 years ago

You think the problem is with core and not this plugin?

jeanpaulattard commented 2 years ago

I'm not sure to be quite honest. Didn't give it much investigation after finding the fix for it.

Whip commented 2 years ago

Its sad to see this plugin is not being maintained right now. There are over 500 open issues and last update was almost 2 years ago. @EddyVerbruggen can you confirm if you're still working on this?

mika-ella commented 2 years ago

hey @Whip are you able to find solution for this? I am also facing this issue earlier this May.

Whip commented 2 years ago

No. I believe the plugin needs to be updated. @EddyVerbruggen could tell. I hope he hasn't abandoned the project.

gyansoft786 commented 2 years ago

Same issue here. After upgrading to {N} 8.2.2. It was working file with NS 8.0. Looks like this plugin no longer maintained. @EddyVerbruggen would you please confirm if this plugin is no longer in development.

gyansoft786 commented 2 years ago

looks like things has been changed. We are using outdated plugin. Have a look at this https://github.com/NativeScript/firebase It works for me fine.

jwrascoe commented 2 years ago

the correct {NS} way to fix this is by adding a buildscript.gradle file to your App_Resources/Android directory repositories { google() mavenCentral() } dependencies { classpath 'com.google.gms:google-services:4.3.12' }

machadoastur commented 1 year ago

jwrascoe Could you tell me where to put that file? I can't find that code to include firebase in an Android Studio Firebase project

jwrascoe commented 1 year ago

@machadoastur It goes in your App_Resources/Android directory where your Angular code is, not in the platform generated code... the NS builder looks at that file and then creates the correct files in the platform area

machadoastur commented 1 year ago

Muchas gracias.

El jue, 2 mar 2023 a las 13:12, James Rascoe @.***>) escribió:

@machadoastur https://github.com/machadoastur It goes in your App_Resources/Android directory where your Angular code is, not in the platform generated code... the NS builder looks at that file and then creates the correct files in the platform area

— Reply to this email directly, view it on GitHub https://github.com/EddyVerbruggen/nativescript-plugin-firebase/issues/1882#issuecomment-1451771436, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABD4PKAPRR53ODKWERAOZF3W2CFDRANCNFSM5VJ2X6ZA . You are receiving this because you were mentioned.Message ID: @.*** .com>