A problem occurred evaluating project ‘:expo-firebase-core’

I created an expo project and added firebase google auth.
I am getting the following error when I try to the command

npm run build

A problem occurred evaluating project ‘:expo-firebase-core’.

Could not set unknown property ‘classifier’ for task ‘:expo-firebase-core:androidSourcesJar’ of type org.gradle.api.tasks.bundling.Jar.

I have following packages

"@react-native-async-storage/async-storage": "1.18.2",
"@rneui/base": "^4.0.0-rc.7",
"@rneui/themed": "^4.0.0-rc.8",
"expo": "~49.0.7",
"expo-application": "~5.3.0",
"expo-auth-session": "~5.0.2",
"expo-build-properties": "~0.8.3",
"expo-constants": "~14.4.2",
"expo-crypto": "~12.4.1",
"expo-dev-client": "~2.4.8",
"expo-firebase-core": "^6.0.0",
"expo-firebase-recaptcha": "^2.3.1",
"expo-linking": "~5.0.2",
"expo-router": "2.0.0",
"expo-splash-screen": "~0.20.5",
"expo-status-bar": "~1.6.0",
"firebase": "^10.2.0",
"react": "18.2.0",
"react-native": "0.72.4",
"react-native-gesture-handler": "~2.12.0",
"react-native-safe-area-context": "4.6.3",
"react-native-screens": "~3.22.0",
"react-native-webview": "13.2.2"

And my build.gradle is

// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
    ext {
        buildToolsVersion = findProperty('android.buildToolsVersion') ?: '33.0.0'
        minSdkVersion = Integer.parseInt(findProperty('android.minSdkVersion') ?: '21')
        compileSdkVersion = Integer.parseInt(findProperty('android.compileSdkVersion') ?: '33')
        targetSdkVersion = Integer.parseInt(findProperty('android.targetSdkVersion') ?: '33')
        kotlinVersion = findProperty('android.kotlinVersion') ?: '1.8.10'
        frescoVersion = findProperty('expo.frescoVersion') ?: '2.5.0'

        // We use NDK 23 which has both M1 support and is the side-by-side NDK version from AGP.
        ndkVersion = "23.1.7779620"
    }
    repositories {
        google()
        mavenCentral()
    }
    dependencies {
        classpath('com.android.tools.build:gradle:7.4.2')
        classpath('com.facebook.react:react-native-gradle-plugin')
    }
}

allprojects {
    repositories {
        maven {
            // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
            url(new File(['node', '--print', "require.resolve('react-native/package.json')"].execute(null, rootDir).text.trim(), '../android'))
        }
        maven {
            // Android JSC is installed from npm
            url(new File(['node', '--print', "require.resolve('jsc-android/package.json')"].execute(null, rootDir).text.trim(), '../dist'))
        }

        google()
        mavenCentral()
        maven { url 'https://www.jitpack.io' }
    }
}

Any fix suggestions are welcome.

Leave a Comment