MiniProfiler / rack-mini-profiler

Profiler for your development and production Ruby rack apps.
MIT License
3.7k stars 402 forks source link

speed badge shows double entries for each request #472

Closed joelcahalan closed 1 year ago

joelcahalan commented 3 years ago

I have tested across three browsers and all of them had this behavior on my mac. My colleague's machine does not have this behavior for the same rails app. Any thoughts on how to debug this would be appreciated.

kei-p commented 3 years ago

I've encountered the same thing. I inspected how it work fetch mini_profile results and found that onload function on below code is called twice each fetch result request.

https://github.com/MiniProfiler/rack-mini-profiler/blob/338cdd1a3c6f71a6ade103708a3d613ac9021e70/lib/html/includes.js#L139-L161

However, I do not understand why onload is called twice.

kei-p commented 3 years ago

I have found the cause of this. In my case, I set the Bullet.add_fotter = false and it stopped happening. It was probably caused by a change in xhr's behavior due to bullet_xhr.js that injected by bullet.

kbrock commented 3 years ago

is this resolved? Is there a particular action that can come from this issue?