Home > Back-end >  Unable to sync gradle files - Android Studio
Unable to sync gradle files - Android Studio

Time:06-13

Can anyone please give me solution as I have download fresh Bumblebee Android studio and trying to create a sample project but it is unable to sync grade files and showing following error- enter image description here

I have following gradle versions of wrapper.properties and plugin:

wrapper.properties

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

app.gradle file:

plugins {
    id 'com.android.application' version '7.1.2' apply false
    id 'com.android.library' version '7.1.2' apply false
}

task clean(type: Delete) {
    delete rootProject.buildDir
}

CodePudding user response:

  1. Close Android Studio if it is being opened.
  2. Delete cache in these folders:

C:\Users\xxxxx\.gradle\caches

C:\Users\xxxxx\.android\build-cache

C:\Users\xxxxx\.android\cache

CodePudding user response:

androidstudio -> file -> invalidate caches and restart.

  • Related