today I updated my Android Studio to 2.2.. I'm not sure this is because of update but I got this error when I run the app
Information:Gradle tasks [:app:clean, :app:generateDebugSources, :app:mockableAndroidJar, :app:prepareDebugUnitTestDependencies, :app:generateDebugAndroidTestSources, :app:assembleDebug]
Error:Execution failed for task ':app:transformClassesWithJavaResourcesVerifierForDebug'.
> org.gradle.api.internal.changedetection.rules.DescriptiveChange cannot be cast to org.gradle.api.tasks.incremental.InputFileDetails
ay be corrupt (this sometimes occurs after a network connection timeout.)
<a href="syncProject">Re-download dependencies and sync project (requires network)</a></li><li>The state of a Gradle build process (daemon) may be corrupt. Stopping all Gradle daemons may solve this problem.
<a href="stopGradleDaemons">Stop Gradle build processes (requires restart)</a></li><li>Your project may be using a third-party plugin which is not compatible with the other plugins in the project or the version of Gradle requested by the project.</li></ul>In the case of corrupt Gradle processes, you can also try closing the IDE and then killing all Java processes.
Information:BUILD FAILED
Information:Total time: 7.336 secs
Information:1 error
Information:0 warnings
Information:See complete output in console
I was trying to clean and rebuild app but there was nothing affect
You can resolve gradle by going C:\Users\(user name path)\. gradle and delete this . gradle file build again and make sure you are connected to internet.
In some cases when your Gradle files are deleted or corrupted you will not be able to download new Gradle files in android studio. In this case, we have to delete the Gradle files which are present already and then again sync your project to download our Gradle files again.
Delete .gradle folder then clean and run... maybe it'll help for you. Thanks.
Close Android Studio, if it's opened
Go to the project workspace (Eg: C:\wheverever\it\is\TheProjectName)
Delete .gradle folder
Open Android Studio. Clean and build your project.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With