Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

No cached version of com.android.tools.build:aapt2:4.0.0-alpha09-6051327 available for offline mode. android 4.0 canary 9

Task failed with an exception.

  • What went wrong: Cannot isolate parameters com.android.build.gradle.internal.dependency.AarResourcesCompilerTransform$Parameters_Decorated@2e602d09 of artifact transform AarResourcesCompilerTransform

    Could not isolate value com.android.build.gradle.internal.dependency.AarResourcesCompilerTransform$Parameters_Decorated@2e602d09 of type AarResourcesCompilerTransform.Parameters Could not resolve all files for configuration ':app:_internal_aapt2_binary'. Could not resolve com.android.tools.build:aapt2:4.0.0-alpha09-6051327. Required by: project :app No cached version of com.android.tools.build:aapt2:4.0.0-alpha09-6051327 available for offline mode. No cached version of com.android.tools.build:aapt2:4.0.0-alpha09-6051327 available for offline mode.

like image 344
SuPeR StAr Avatar asked Jan 23 '20 09:01

SuPeR StAr


1 Answers

This is as a result of Gradle trying to use some network resources but since you have offline mode enabled, it uses only the artifacts that it has cached locally. In AS Canary 9, with your computer connected to the internet, try disabling the Gradle offline mode using the button shown below, after which you can clean and rebuild the project.

enter image description here

like image 110
Mayokun Avatar answered Sep 24 '22 21:09

Mayokun