Recently, I have developed a rather complex widget application for showing cryptocurrency graphs.
It works fine, however, I am receiving a lot of comments and complaints about the widget sporadically freezing. I have been trying to tackle this problem for a while now but cannot find a solution to this. There is no action I am aware of that causes this behavior and therefore, the problem is NOT deterministically reproducible. My guess is that there is an error in the tizen memory management as the log dumps show absolutely no action when the error has occurred — there is not even a single sign or message of the app being active at all.
A more detailed description of the error: if you turn the bezel to see the widget a listener is called which updates it. This works fine 95% of the time. Sometimes, however, if you have not opened the widget for some time, the widget will be unresponsive and you will have to turn the bezel to get to the next widget and then go back to my widget. This causes the widget to work again. On very rare occasions the widget will freeze completely and you will have to remove and add it again.
Concerning my code: due to my desperation I have wrapped EVERY method in try-catch blocks logging any errors (still — no signs of log-messages in the dumps). Other than that, the code is not too complex, and I am willing to privately share with anyone interested. I mentioned it is rather complex and the reason for this is that I have to create ~100 divs just to draw graphs as the tizen OS infers many constraints on widget applications. This might be a root cause for the problem.
I am very grateful for any kind of advice! If I won't find a solution to this I will need to suspend the application as I do not want to sell a buggy application.
Thanks a lot!
Widget being unresponsive / freezing