Posts Tagged debugging

Android – onRestoreInstanceState

Are your users complaining that your app is crashing when it’s restarted after being killed by the operating system or a task manager? Are you still trying to figure out why? You might want to try overriding onRestoreInstanceState, not calling the super, and seeing if the problem goes away.

    protected void onRestoreInstanceState (Bundle savedInstanceState) {

This is a quick way of dealing with the problem and keeping your users happy, while you’re busy trying to figure out the root cause of the problem. You need to do a lot of testing to ensure it doesn’t cause any new problems, especially when switching activities and using the home and back keys.  Good luck!


, , , , , , , ,

Leave a comment

Android App Testing: You’re never really done testing

 I’m pretty good at application testing, but I know that I won’t catch everything.  As a result of literally using my apps on a daily basis (Yellow Pad List and Mew Media Player Pro), I’m always on the lookout for things that need to be fixed or improved upon.

Yellow Pad List is about 99.9% crash proof and there are no logic flaws that I’m aware of. It could use a few more features, but since its popularity isn’t growing, it will remain as is for now – stable! If you use it and have some features you would like to see incorporated into the app, please let me know!

Mew Media Player/Pro has been keeping me busy over the past 11 days. The biggest issue has been intermittent song skip fixes (i.e. song plays for 1-2 seconds and then goes onto the next song) and I think  I finally found the last of three logic flaws, each of which was resolved on a different day. The last one was related to calls to onStop and onResume within the main activity.  The code in those procedures made sense when I wrote it and worked perfectly in pre-release testing, but there were some logic errors as a result of doing a combination of actions which I just didn’t catch.   I have my fingers crossed that the player won’t skip anymore, but I won’t be satisfied until a week goes by without skips.

It’s important to use your apps on a daily basis after you’ve published them, to catch any bugs and logic errors that you didn’t catch during pre-release testing. Don’t just rely on your users to report them to you.  The less problems users encounter with your app, the more likely they are to keep it and tell others about it.

, , , ,

Leave a comment

%d bloggers like this: