I found a few more even rarer instances of the "messed up timeline with websockets data" bug after the latest fixes, and figured out that they were caused by states being sent out of sequence.
Rather than fixing whatever in the mock data server is causing states to be sent out of sequence, based on the principle of "correctly render whatever data is thrown at us" I've added x-axis sorting to the timeline and related hooks so that out-of-sequence data is still rendered correctly. Since we don't have control over the introspection server it's good to have resilience. I've checked the performance and this extra sort adds less than 1ms to the time taken to handle incoming states even when out of sequence.
I found a few more even rarer instances of the "messed up timeline with websockets data" bug after the latest fixes, and figured out that they were caused by states being sent out of sequence.
Rather than fixing whatever in the mock data server is causing states to be sent out of sequence, based on the principle of "correctly render whatever data is thrown at us" I've added x-axis sorting to the timeline and related hooks so that out-of-sequence data is still rendered correctly. Since we don't have control over the introspection server it's good to have resilience. I've checked the performance and this extra sort adds less than 1ms to the time taken to handle incoming states even when out of sequence.