alexjlockwood / adp-delightful-details

This sample app accompanies a blog post I wrote on icon animations
https://www.androiddesignpatterns.com/2016/11/introduction-to-icon-animation-techniques.html
MIT License
1.07k stars 160 forks source link

IllegalArgumentException: no valueFrom or no valueTo #7

Closed Tomekkk closed 7 years ago

Tomekkk commented 7 years ago

After support library update there is a crash on path morphing animation in Downloading example. FATAL EXCEPTION: main Process: com.alexjlockwood.example.delight, PID: 7692 java.lang.IllegalArgumentException: no valueFrom or no valueTo at android.support.graphics.drawable.AnimatorInflaterCompat.parseAnimatorFromTypeArray(AnimatorInflaterCompat.java:361) at android.support.graphics.drawable.AnimatorInflaterCompat.loadAnimator(AnimatorInflaterCompat.java:815) at android.support.graphics.drawable.AnimatorInflaterCompat.loadObjectAnimator(AnimatorInflaterCompat.java:790) at android.support.graphics.drawable.AnimatorInflaterCompat.createAnimatorFromXml(AnimatorInflaterCompat.java:443) at android.support.graphics.drawable.AnimatorInflaterCompat.createAnimatorFromXml(AnimatorInflaterCompat.java:454) at android.support.graphics.drawable.AnimatorInflaterCompat.createAnimatorFromXml(AnimatorInflaterCompat.java:417) at android.support.graphics.drawable.AnimatorInflaterCompat.loadAnimator(AnimatorInflaterCompat.java:126) at android.support.graphics.drawable.AnimatorInflaterCompat.loadAnimator(AnimatorInflaterCompat.java:113) at android.support.graphics.drawable.AnimatorInflaterCompat.loadAnimator(AnimatorInflaterCompat.java:96) at android.support.graphics.drawable.AnimatedVectorDrawableCompat.inflate(AnimatedVectorDrawableCompat.java:485) at android.support.graphics.drawable.AnimatedVectorDrawableCompat.createFromXmlInner(AnimatedVectorDrawableCompat.java:253) at android.support.graphics.drawable.AnimatedVectorDrawableCompat.create(AnimatedVectorDrawableCompat.java:233) at com.alexjlockwood.example.delight.DownloadingActivity.swapAnimation(DownloadingActivity.java:60) at com.alexjlockwood.example.delight.DownloadingActivity.access$000(DownloadingActivity.java:15) at com.alexjlockwood.example.delight.DownloadingActivity$1.run(DownloadingActivity.java:47) at android.os.Handler.handleCallback(Handler.java:739) at android.os.Handler.dispatchMessage(Handler.java:95) at android.os.Looper.loop(Looper.java:135) at android.app.ActivityThread.main(ActivityThread.java:5289) at java.lang.reflect.Method.invoke(Native Method) at java.lang.reflect.Method.invoke(Method.java:372) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:904) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:699) Environment: Android 5 and 6

eboudrant commented 7 years ago

Same issue for us, exception also seen on Android 5 and 6 (I can't reproduce it). We are using support lib 25.3.1. @Tomekkk which version of support lib have you used to get the crash, I guess it was 25.4.0 ? What device have you used ?

Tomekkk commented 7 years ago

@eboudrant I didn't modify project to get this crash, so the support library was 25.4.0. It seems there are few improvements for VectorDrawables in newest support library (26) and in my project there is no more crash but I'm using different vectors. Check the latest support library release 😉

eboudrant commented 7 years ago

Any idea what device you used, I tried to repro using 5.0.1 with 25.4.0, no luck. Also I cannot use 26, we are not ready to target O.

alexjlockwood commented 7 years ago

Hmm... haven't seen this before. Will take a look tonight!

eboudrant commented 7 years ago

@alexjlockwood just curious, have you got a chance to look into that ? Thanks

alexjlockwood commented 7 years ago

I disabled aapt2 in the gradle.properties file... should be fixed now.

eboudrant commented 7 years ago

Thanks, btw do you have any link to this aapt2 issue ?

On Sat, Oct 28, 2017 at 11:45 AM, Alex Lockwood notifications@github.com wrote:

I disabled aapt2 in the gradle.properties file... should be fixed now.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/alexjlockwood/adp-delightful-details/issues/7#issuecomment-340211722, or mute the thread https://github.com/notifications/unsubscribe-auth/AAvNAa1Si_FmtfEZ5-zjtAcay9GAaZsJks5sw3ZmgaJpZM4OZu-N .

alexjlockwood commented 7 years ago

Hmm... good question. I'd ask Nick Butcher in this thread about that... looks like a bug has been filed internally at Google... not sure if there is one publicly visible though. https://github.com/bodymovin/bodymovin/issues/578

nickbutcher commented 7 years ago

Sorry the tracking bug isn't public. This one looks like the same cause:

https://issuetracker.google.com/issues/67668749

I've just linked this to the other issue so may get duped or updated when resolved.

eboudrant commented 7 years ago

Thanks, I just wanted to know when we could re-activate aapt2 if we need to disable it because of this issue.