You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 19, 2026. It is now read-only.
Repository navigation
This repository was archived by the owner on Apr 19, 2026. It is now read-only.
Error:(4, 0) Declaring custom 'clean' task when using the standard Gradle lifecycle plugins is not allowed.
Open File
Gradle sync failed: Declaring custom 'clean' task when using the standard Gradle lifecycle plugins is not allowed.
Consult IDE log for more details (Help | Show Log)
/* task clean(type: Delete) {
delete rootProject.buildDir
} */
comment like this..
and then follow the instruction and it will start to download some files & gradle built successfully after sometime.it takes 3-4minute.
Are you still seeing this issue? I have not had any issues with using Gradle and the latest (3.1+) versions of Android Studio. I'll close this soon if there's no further issue.
Activity
YuchengWang commentedon Mar 20, 2017
idea.zip
the below is log
binnykmathew commentedon Mar 21, 2017
I got the same error but was able to successfully build and also deploy after I commented out the following line from the build.gradle file
/* task clean(type: Delete) {
delete rootProject.buildDir
} */
tiagoalexbastos commentedon Mar 26, 2017
thanks @binnykmathew , solved with the comment.
tanishq-rocks commentedon Jun 26, 2018
/* task clean(type: Delete) {
delete rootProject.buildDir
} */
comment like this..
and then follow the instruction and it will start to download some files & gradle built successfully after sometime.it takes 3-4minute.
Fleker commentedon Jul 23, 2018
Are you still seeing this issue? I have not had any issues with using Gradle and the latest (3.1+) versions of Android Studio. I'll close this soon if there's no further issue.