android - NoSuchPropertyException in signed build -


i animating map marker via following code:

final property<marker, latlng> property =         property.of(marker.class, latlng.class, "position"); final objectanimator animator =         objectanimator.ofobject(othermarker, property, typeevaluator, tolatlng); 

this works fine in debug build fails following stack trace in signed build:

0    android.util.nosuchpropertyexception: no accessor method or field found property name position 1    @ android.util.reflectiveproperty.<init>(reflectiveproperty.java:71) 2    @ android.util.property.of(property.java:55) 3    @ com.myapp.fragment.mapwrapperfragment.j(mapwrapperfragment.java:1090) 4    @ com.myapp.activitya.l(activitya.java:860) 5    @ com.myapp.fragment.fragmenta$22.onclick(fragmenta.java:377) 6    @ android.view.view.performclick(view.java:4438) 7    @ android.view.view$performclick.run(view.java:18422) 8    @ android.os.handler.handlecallback(handler.java:733) 9    @ android.os.handler.dispatchmessage(handler.java:95) 10   @ android.os.looper.loop(looper.java:136) 11   @ android.app.activitythread.main(activitythread.java:5001) 12   @ java.lang.reflect.method.invokenative(native method) 13   @ java.lang.reflect.method.invoke(method.java:515) 14   @ com.android.internal.os.zygoteinit$methodandargscaller.run(zygoteinit.java:785) 15   @ com.android.internal.os.zygoteinit.main(zygoteinit.java:601) 16   @ dalvik.system.nativestart.main(native method) 

what reason this? not sure if it's relevant, using proguard.

proguard either removing or renaming field, since doesn't know access done via reflection. that's why fails @ runtime.

you should add -keep (or -keepnames) rule prevent this.


Comments

Popular posts from this blog

python - mat is not a numerical tuple : openCV error -

c# - MSAA finds controls UI Automation doesn't -

wordpress - .htaccess: RewriteRule: bad flag delimiters -