1

Recently I've had to upgrade gradle versions of my react native projects. Following are the files I currently have. android/gradle/wrapper/gradle-wrapper.properties

distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-6.5-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists

android/build.gradle

 dependencies {
        classpath("com.android.tools.build:gradle:3.5.4")
        // Add the following line:
        classpath 'com.google.gms:google-services:4.3.10'  // Google Services 
    }

I'm now receiving error stating Firebase Messaging component is not present. Upon searching the cause,I found here that gradle:3.5.4 and google-services:4.3.10 are not compatible and I might have to downgrade the gradle version.

However on downgrading gradle to 3.4.x, I get another error stating

> Android resource linking failed
  /home/thecodeninja/Desktop/FindUtsav/app/FindUtsav eject/android/app/build/intermediates/merged_manifests/debug/AndroidManifest.xml:36: AAPT: error: unexpected element <queries> found in <manifest>.

and as it turns out, the reason for this error is that lower versions of gradle dont support <queries> tag [mentioned here].

and so I`m completely stumped - how do I find the right pair of gradle and google-services versions

Suraj Ingle
  • 372
  • 4
  • 18

0 Answers0