Home > OS >  Error: Could not find com.android.tools.build:gradle:3.3.0 in flutter
Error: Could not find com.android.tools.build:gradle:3.3.0 in flutter

Time:01-13

hi my gradle version is 7.3.3 and my flutter version is 2.8.1

this is error when I run the app :

FAILURE: Build failed with an exception.
    
    * What went wrong:
    A problem occurred configuring project ':path_provider_android'
    > Could not resolve all artifacts for configuration ':path_provider_android:classpath'
       > Could not find com.android.tools.build:gradle:3.3.0.
         Searched in the following locations:
           - https://dl.google.com/dl/android/maven2/com/android/tools/build/gradle/3.3.0/gradle-3.3.0.pom
           - https://repo.maven.apache.org/maven2/com/android/tools/build/gradle/3.3.0/gradle-3.3.0.pom
     

CodePudding user response:

To fix this issue go and check google() repo in your project's level build.gradle file

    buildscript {
    repositories {
        jcenter()
        google()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:3.3.0'
    }
}

allprojects {
    repositories {
        jcenter()
        google()
    }
}

CodePudding user response:

Jcenter its suppose to close on 1 Feb. But today i started having problems. On a research i found this Flutter migration jcenter to mavenCentral

Now theres a big problem bc a lot of pubs depend on this change... Now im waiting the community to fix it

  •  Tags:  
  • Related