Debugging a production app?

Hi Ionic,

Have a really bizarre problem where details are showing on a screen for me during testing and also in production. However, 1 or 2 users have said that these details are not showing for them but then others it is showing for. The response from the server each time i test it shows that these details are there and are visible and i am yet to do a test that they have not shown.

Is there any possible way for me to be able to see the logs or inspect the users where it doesn’t show to see the logs? This app is live on the play store as well, which i dont think you can inspect using chrome dev tools, if i am correct?

Any help would be appreciated!

Thanks

Do you have some form of error logger like Sentry? If not, you should look into it. Your best bet is to ask the people that are having issues to identify what type of device and os they are on. That way you can create the emulators for that specific device in Android Studio, that way you can test it yourself. Also you cannot test prod apps with dev tools.

1 Like

Thanks, yeah that was my thinking too! at the minute i am just using console.log() and chrome dev tools/ xcode to see logs.

I would also suggest having somebody carefully audit the code for race conditions - situations where you are inadvertently relying on things executing in a particular order.

I wish there was something like Jasik’s Debugger for JavaScript. It had a really useful feature that helped me find many similar bugs when I used to be a MacOS developer. Old-school MacOS had a memory manager that would move stuff around at (fairly) well-defined times, but the vast majority of the time you could get away with making dangerous assumptions about a particular object staying where it was.

The Debugger had a mode where basically any time the Memory Manager could move memory around, it would. It very quickly crashed any app that was making unsafe assumptions.