Reputation: 8674
After upgrading the gradle to com.android.tools.build:gradle:3.3.0-alpha07 today, I am facing one issue with build:
Task :app:transformClassesAndResourcesWithR8ForDebug FAILED
FAILURE: Build failed with an exception.
- What went wrong: Execution failed for task ':app:transformClassesAndResourcesWithR8ForDebug'.
java.lang.NullPointerException (no error message)
I have tried following steps to fix this issue :
Note : Issue exists when I set following values to true :
minifyEnabled true
shrinkResources true
If I make them false, Build succeeds. But still issue persist with them being true. Can anyone help in this?
Upvotes: 1
Views: 1630
Reputation: 3285
This may not be the exact solution but something similar happened with me. However, I had updated my dependencies to AndroidX.
Keeping
minifyEnabled true
shrinkResources true
will require you to also update app's proguard-rules
file. After which only your app will compile. I hope this gives you some pointers in figuring out a solution.
Upvotes: 1