NoClassDefFoundError - Android 2.3.X -


i have task defined in class. fatal exception "noclassdeffounderror" happening on following line

mycutetask mytask = new mycutetask(equations) 

here code

public class myclass  {      public void run() {         mycutetask mytask = new mycutetask(equations)     }      protected class mycutetask extends  asynctask<string, integer, string> {         ...     } } 

recently, have strange bug reports. android throw exception when instantiate task. have bug android 2.3.x only.

do of got same bug?

edit: here stack trace

java.lang.noclassdeffounderror: com.mathssolver.main.k    @ com.mathssolver.main.logic.updategraph(logic.java:310)    @ com.mathssolver.main.graph.update(graph.java:249)    @ com.mathssolver.main.mathgraphfragment.plotfunction(mathgraphfragment.java:236)    @ com.mathssolver.main.mathgraphfragment.plot(mathgraphfragment.java:158)    @ com.mathssolver.main.mathgraphfragment.showexample(mathgraphfragment.java:141)    @ com.mathssolver.main.mathgraphfragment.onstart(mathgraphfragment.java:109)    @ android.support.v4.app.fragment.performstart(fragment.java:1810)    @ android.support.v4.app.fragmentmanagerimpl.movetostate(fragmentmanager.java:977)    @ android.support.v4.app.fragmentmanagerimpl.performpendingdeferredstart(fragmentmanager.java:842)    @ android.support.v4.app.fragmentmanagerimpl.startpendingdeferredfragments(fragmentmanager.java:1150)    @ android.support.v4.app.fragmentmanagerimpl.execpendingactions(fragmentmanager.java:1506)    @ android.support.v4.app.fragmentmanagerimpl.executependingtransactions(fragmentmanager.java:486)    @ android.support.v4.app.fragmentpageradapter.finishupdate(fragmentpageradapter.java:141)    @ android.support.v4.view.viewpager.populate(viewpager.java:1073)    @ android.support.v4.view.viewpager.populate(viewpager.java:919)    @ android.support.v4.view.viewpager.onmeasure(viewpager.java:1441)    @ android.view.view.measure(view.java:8323)    @ android.widget.relativelayout.measurechildhorizontal(relativelayout.java:581)    @ android.widget.relativelayout.onmeasure(relativelayout.java:365)    @ android.view.view.measure(view.java:8323)    @ android.view.viewgroup.measurechildwithmargins(viewgroup.java:3138)    @ android.widget.framelayout.onmeasure(framelayout.java:250)    @ android.view.view.measure(view.java:8323)    @ android.view.viewgroup.measurechildwithmargins(viewgroup.java:3138)    @ android.support.v7.internal.widget.actionbaroverlaylayout.onmeasure(actionbaroverlaylayout.java:453)    @ android.view.view.measure(view.java:8323)    @ android.view.viewgroup.measurechildwithmargins(viewgroup.java:3138)    @ android.widget.framelayout.onmeasure(framelayout.java:250)    @ android.view.view.measure(view.java:8323)    @ android.view.viewgroup.measurechildwithmargins(viewgroup.java:3138)    @ android.widget.framelayout.onmeasure(framelayout.java:250)    @ android.view.view.measure(view.java:8323)    @ android.view.viewroot.performtraversals(viewroot.java:842)    @ android.view.viewroot.handlemessage(viewroot.java:1862)    @ android.os.handler.dispatchmessage(handler.java:99)    @ android.os.looper.loop(looper.java:130)    @ android.app.activitythread.main(activitythread.java:3806)    @ java.lang.reflect.method.invokenative(method.java)    @ java.lang.reflect.method.invoke(method.java:507)    @ com.android.internal.os.zygoteinit$methodandargscaller.run(zygoteinit.java:839)    @ com.android.internal.os.zygoteinit.main(zygoteinit.java:597)    @ dalvik.system.nativestart.main(nativestart.java) caused by: java.lang.classnotfoundexception: com.mathssolver.main.k in loader dalvik.system.pathclassloader[/data/app/com.shakti.mathssolver-1.apk]    @ dalvik.system.pathclassloader.findclass(pathclassloader.java:240)    @ java.lang.classloader.loadclass(classloader.java:551)    @ java.lang.classloader.loadclass(classloader.java:511)    @ com.mathssolver.main.logic.updategraph(logic.java:310)    @ com.mathssolver.main.graph.update(graph.java:249)    @ com.mathssolver.main.mathgraphfragment.plotfunction(mathgraphfragment.java:236)    @ com.mathssolver.main.mathgraphfragment.plot(mathgraphfragment.java:158)    @ com.mathssolver.main.mathgraphfragment.showexample(mathgraphfragment.java:141)    @ com.mathssolver.main.mathgraphfragment.onstart(mathgraphfragment.java:109)    @ android.support.v4.app.fragment.performstart(fragment.java:1810)    @ android.support.v4.app.fragmentmanagerimpl.movetostate(fragmentmanager.java:977)    @ android.support.v4.app.fragmentmanagerimpl.performpendingdeferredstart(fragmentmanager.java:842)    @ android.support.v4.app.fragmentmanagerimpl.startpendingdeferredfragments(fragmentmanager.java:1150)    @ android.support.v4.app.fragmentmanagerimpl.execpendingactions(fragmentmanager.java:1506)    @ android.support.v4.app.fragmentmanagerimpl.executependingtransactions(fragmentmanager.java:486)    @ android.support.v4.app.fragmentpageradapter.finishupdate(fragmentpageradapter.java:141)    @ android.support.v4.view.viewpager.populate(viewpager.java:1073)    @ android.support.v4.view.viewpager.populate(viewpager.java:919)    @ android.support.v4.view.viewpager.onmeasure(viewpager.java:1441)    @ android.view.view.measure(view.java:8323)    @ android.widget.relativelayout.measurechildhorizontal(relativelayout.java:581)    @ android.widget.relativelayout.onmeasure(relativelayout.java:365)    @ android.view.view.measure(view.java:8323)    @ android.view.viewgroup.measurechildwithmargins(viewgroup.java:3138)    @ android.widget.framelayout.onmeasure(framelayout.java:250)    @ android.view.view.measure(view.java:8323)    @ android.view.viewgroup.measurechildwithmargins(viewgroup.java:3138)    @ android.support.v7.internal.widget.actionbaroverlaylayout.onmeasure(actionbaroverlaylayout.java:453)    @ android.view.view.measure(view.java:8323)    @ android.view.viewgroup.measurechildwithmargins(viewgroup.java:3138)    @ android.widget.framelayout.onmeasure(framelayout.java:250)    @ android.view.view.measure(view.java:8323)    @ android.view.viewgroup.measurechildwithmargins(viewgroup.java:3138)    @ android.widget.framelayout.onmeasure(framelayout.java:250)    @ android.view.view.measure(view.java:8323)    @ android.view.viewroot.performtraversals(viewroot.java:842)    @ android.view.viewroot.handlemessage(viewroot.java:1862)    @ android.os.handler.dispatchmessage(handler.java:99)    @ android.os.looper.loop(looper.java:130)    @ android.app.activitythread.main(activitythread.java:3806)    @ java.lang.reflect.method.invokenative(method.java)    @ java.lang.reflect.method.invoke(method.java:507)    @ com.android.internal.os.zygoteinit$methodandargscaller.run(zygoteinit.java:839)    @ com.android.internal.os.zygoteinit.main(zygoteinit.java:597)    @ dalvik.system.nativestart.main(nativestart.java) 

line @ com.mathssolver.main.logic.updategraph(logic.java:310) is

 mycutetask mytask = new mycutetask(equations) 

its google play services issue. (https://code.google.com/p/android/issues/detail?id=81083)

workaround avoid crash till google fixes it:

add following application#oncreate() method

try {   class.forname("android.os.asynctask"); } catch(throwable ignore) {   // ignored } 

note application#oncreate() , not activity#oncreate()

update: can verify above changes fixed these crashes me.


Comments

Popular posts from this blog

matlab - "Contour not rendered for non-finite ZData" -

delphi - Indy UDP Read Contents of Adata -

javascript - Any ideas when Firefox is likely to implement lengthAdjust and textLength? -