Hold back button issue

Hello everyone, I'm developing a watchface for the enduro 3.

I chose to render some elements, the simplest ones, through the layout.xml file and then add a graph that is drawn with the dc.fillRectangle function. The watch is set so that, holding down the BACK button, the watchface is shown.

Everithing works fine except when I hold BACK button, the watchface is shown but I have a problem whereby the displays do not update all the data together: - the time has a glitch whereby the previous minute is shown first (11:15) and then redraw to right time (11:16) - the graph remains black for a second and then is drawn I thought that the graph function was too complex but replacing the graph with a simple text using dc.drawText I have the same problem. This is my onUpdate method:

pastecode.io/.../grg5cacd
Where am I going wrong?
Thank's!