AAPT2 compile failed: invalid dimen on Android 3.0 Canary 1 on Windows AAPT2 compile failed: invalid dimen on Android 3.0 Canary 1 on Windows windows windows

AAPT2 compile failed: invalid dimen on Android 3.0 Canary 1 on Windows


did you see this https://www.reddit.com/r/androiddev/comments/4u0gw1/support_library_2411_released/

If you are using support libraries on version 24.x (you or even your dependencies), this is incompatible with AAPT2 and you should :

  • disbale aapt2 in your gradle.properties file:android.enableAapt2=false
  • or upgrade google libraries to version 25or 26


@Phan Van Linh, can you please check the line from "values.xml:911" where you are getting the invalid drawable issue & google it exactly?

I had the same issue with one of my project and the problematic line was:

<item name="crop_image_menu_crop" type="drawable"/>


It was from an image library I had used in my project. The issue was that I was using an older version of the library. Once I updated to newer version, the error was gone.

Hopefully, your issue might get fixed like mine.

Happy Hunting!