cloudflare / speedtest

Component to perform network speed tests against Cloudflare's edge network
https://speed.cloudflare.com
MIT License
459 stars 34 forks source link

Test requests don't stop after test completion if tab is not visible, bug? #44

Open eugeniumegherea opened 3 weeks ago

eugeniumegherea commented 3 weeks ago

Initially I thought there's a bug in our application and somehow we were leaking timers, but I was able to reproduce this issue on live cloudflare speed test.

Steps to reproduce:

https://github.com/user-attachments/assets/86f74691-b9f7-485e-8f4a-4e62c692a299

I suspect it has to do something with the performance api and the fact that chrome will aggressively slow down any internal timers if the page is not visible.

Here is the call stack from network: image which corresponds to this line: image