I have a class marked with @TargetApi(21)
attribute and that uses, well, API Level 21 classes. I don't invoke the class if the app is running on an older device. However, with Instant Run enabled, I cannot debug my app on say an API Level 18 device, because then the task app:transformClassesWithInstantRunForDebug
fails. Running and debugging the app on API Level 21+ devices is no problem. What would be the solution? How to explain to Android Studio to ignore that file? I guess I've already did that with @TargetApi
attribute...
Asked
Active
Viewed 425 times
0

Aleks N.
- 6,051
- 3
- 42
- 42
-
there are some bugs in instant run function please check http://stackoverflow.com/a/37207831/2826147. – Amit Vaghela Sep 29 '16 at 09:40
-
@AmitVaghela If I don't get an answer (maybe I'm overlooking something), I'll of course file a bug. – Aleks N. Sep 29 '16 at 12:00
-
okay, sir. i thought that it might help you. – Amit Vaghela Sep 29 '16 at 12:01