• After 15+ years, we've made a big change: Android Forums is now Early Bird Club. Learn more here.

Apps Tracing a bug..

Wormslayer

Newbie
Hi,

Is there a program that can record the workings of an app as its being used, so that when a bug occurs you can see the code responsible?

I have a gps track recording app that I recently had some work done to. ( I am not a coder )
Previous to the new work, when the app was tracking, it laid down a single evenly spaced dot. However, since the new work it now sometimes lays double or even treble clusters of dots... My hired coder said that it is hard to reproduce the bug and doesn't seem too bothered about fixing it. The trouble is that I accepted the work done and paid for it, as all looked OK, but the bug is intermittent, and I hadn't seen it at that point . It looks like I will have to hire a new coder to fix the bug if possible, but I would still like to know the answer to my original question :- Is there a program that can record the workings of an app as its being used, so that when a bug occurs you can see the code responsible?

Cheers,

Mark.

Screenshot_2015-03-13-21-05-54.png
 
Hey Wormslayer, here are your options as I see them (this all assumes that you have access to the source):

1. A simple debugging technique would be to insert display statements, or

Log.v (<program name>, <message>);

statements in your app in key places to pin-down where the issue might be. You could then view the logcat (several ways to do this) to observe your app's behavior. This is kind of a hit and miss thing that would be difficult to track down an intermittent bug, though.

2. You could also run your app while attached to laptop that is running your app in your IDE (Eclipse or Android Studio, etc.) and use the debugging / breakpoint facilities inherent to the programming environment to watch what paths your app is following.

I also think that GPS coding samples the measurements, so I think it might be likely that the sampling and recording/average might be "off", resulting in the multiple dots you're seeing (just a blind guess, though). It might also be interesting to see if what you're seeing is happening across many devices or just one or two.

Anyway, you'll likely have to engage the services of another coder to find and fix your issue.

Cheers and best of luck!
 
Thank you for taking the time for such a comprehensive reply. :specsdroid:
I will pass on your thoughts to the next coder. My sincere gratitude Scary..

I have the Galaxy S2 & S4, and the bug appears on both.

On the bright side.. the original coder said he had been under a lot of pressure recently and he hasn't had the time, but promised take a look at it tomorrow :)

Cheers Scary.

All the best.
 
Back
Top Bottom