21 November 2012

Android development crusade part 11: Bug fixing and 2000 downloads :).

GREAT NEWS:
  • 2000 downloads!
  • Release v.1.6.1 is out :).
I am shocked.
2000 downloads where my expectation was 100-250 downloads until end of the year.It is

My plan was to release v1.6 on 11 November,but as I finished ,so i decided to release quicker and see is my major changes cause any major disasters.Answer is ... No,but i decided to  release bug fixes release with fix few bugs and issues  that i was detected by me or was reported by User.

I had 3 reports from users. First 2 problems  appear just after i published v1.6 but crashes that was reported  based on v1.5.2  and they was not fixed in v1.6 (which was a big bug fix release and these bugs didn't occurred), so ... yeah,great.
  1.  java.lang.NullPointerException in Telephony Info
  2.  IllegalArgumentException: in Network Quick Test 
  3.  ANR keyDispatchingTimedOut in my  accelerometer sensor test. 



1)
v1.5.2
Nov 4, 2012 2:13:37 PM

java.lang.NullPointerException
at dms.pastor.diagnostictools.activities.tools.info.TelephonyInfo$1.onCellLocationChanged(TelephonyInfo.java:357)
at android.telephony.PhoneStateListener$2.handleMessage(PhoneStateListener.java:316)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:130)
at android.app.ActivityThread.main(ActivityThread.java:3683)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:507)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597)
at dalvik.system.NativeStart.main(Native Method)

Well. I miss one null check and .... this is  what happen. :)Yes , my favorite  NullPointerException crashes my app again. Grr... .
I fixed a problem.
As i go through code i discover that it was only partly implement, so make some improvement and add more information to display, fixes more issues that i found and tried to make more stable.

Unfortunately ...Telephony info display too many information so i need split into 2-3 tabs,but it needs wait until i will start implement tabs from ICS .
(new tabs will be implement in v2.x series)

2)

v1.5.2
Nov 4, 2012 9:07:50 PM

java.lang.IllegalArgumentException: View not attached to window manager
at android.view.WindowManagerImpl.findViewLocked(WindowManagerImpl.java:381)
at android.view.WindowManagerImpl.removeView(WindowManagerImpl.java:226)
at android.view.Window$LocalWindowManager.removeView(Window.java:432)
at android.app.Dialog.dismissDialog(Dialog.java:278)
at android.app.Dialog.access$000(Dialog.java:71)
at android.app.Dialog$1.run(Dialog.java:111)
at android.app.Dialog.dismiss(Dialog.java:268)
at dms.pastor.diagnostictools.activities.tools.NetworkQuickTest$4.handleMessage(NetworkQuickTest.java:336)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:130)
at android.app.ActivityThread.main(ActivityThread.java:3691)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:507)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:907)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:665)
at dalvik.system.NativeStart.main(Native Method)

This was a funny problem with Thread issue.
In rare cases activity finished quicker than dialog successfully dismisses.I believe that is not only a case why program can crash during dismissing
What i have done is  add pd = null and try/catch block that seems to solve problem (part of my solution based on solution from this source http://stackoverflow.com/a/5102572

try {
  if (pd != null && pd.isShowing()) {      pd.dismiss();
      pd = null;
  }
(...)
  } catch (IllegalArgumentException iae) {
  Log.i(TAG,"activity died ,before progress dialog dismisses");
}

 
3)
v1.5.2
on  Nov 8, 2012 11:46:38 AM
ANR keyDispatchingTimedOut in my  accelerometer sensor test.

Report shows only that problem occure in

main" prio=5 tid=1 RUNNABLE
| group="main" sCount=1 dsCount=0 s=Y obj=0x40028ae0 self=0xcd58
| sysTid=3571 nice=0 sched=0/0 cgrp=default handle=-1345021904
| schedstat=( 34744934055 55085083021 23022 )
at android.text.TextUtils.obtain(TextUtils.java:~1366)
at android.text.BoringLayout.isBoring(BoringLayout.java:239)
at android.widget.TextView.makeNewLayout(TextView.java:4930)
at android.widget.TextView.onMeasure(TextView.java:5258)
at android.view.View.measure(View.java:8172)
at android.widget.TableRow.getColumnsWidths(TableRow.java:308)
at android.widget.TableLayout.findLargestCells(TableLayout.java:497)
at android.widget.TableLayout.measureVertical(TableLayout.java:462)
at android.widget.TableLayout.onMeasure(TableLayout.java:428)
at android.view.View.measure(View.java:8172)
at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:3140)
at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:1012)
at android.widget.LinearLayout.measureVertical(LinearLayout.java:381)
at android.widget.LinearLayout.onMeasure(LinearLayout.java:304)
at android.view.View.measure(View.java:8172)
at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:3140)
at android.widget.LinearLayout.measureChildBeforeLayout(LinearLayout.java:1012)
at android.widget.LinearLayout.measureVertical(LinearLayout.java:381)
at android.widget.LinearLayout.onMeasure(LinearLayout.java:304)
at android.view.View.measure(View.java:8172)
at android.widget.ScrollView.measureChildWithMargins(ScrollView.java:989)
at android.widget.FrameLayout.onMeasure(FrameLayout.java:245)
at android.widget.ScrollView.onMeasure(ScrollView.java:286)
at android.view.View.measure(View.java:8172)
at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:3140)
at android.widget.FrameLayout.onMeasure(FrameLayout.java:245)
at android.view.View.measure(View.java:8172)
at android.view.ViewGroup.measureChildWithMargins(ViewGroup.java:3140)
at android.widget.FrameLayout.onMeasure(FrameLayout.java:245)
at android.view.View.measure(View.java:8172)
at android.view.ViewRoot.performTraversals(ViewRoot.java:1003)
at android.view.ViewRoot.handleMessage(ViewRoot.java:1744)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:143)
at android.app.ActivityThread.main(ActivityThread.java:4914)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:521)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:858)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
at dalvik.system.NativeStart.main(Native Method)

It doesn't tell me is  current values x,y,z  cause problem or vendor information caused problem.
I tested this sensor on my slowest device and this problem didn't appear.
I discover that ANR appeares on dodgy unbranded devices and i think in some cases.
It is impossible to handle


Somebody left even message:
"not responding"

Well, that's was very helpful information ,is it?
HOWEVER.I appreciate that somebody actually send report and add message.


Plans.

 * I found in few places that since Jelly Bean.(SDK16) programs will not be able to read the logs (OS,other programs),so feature "log" is cancelled (well , i was half done with this feature ... so sad)
Source: http://www.youtube.com/watch?v=WDDgoxvQsrQ :(

 *Next release v1.8 will be last this year and it will add last 2 main feature that i planned for first generation of my app.Wifi and GPS

No comments:

Post a Comment