Closed brandonweiss closed 8 years ago
When the page is first loaded, the start
and end
times that are passed to the frontend bar look like this:
"start: 1399493087380"
"end: 1399493087910"
When a PJAX/Turbolinks request is made, I logged both the ajaxStart
and ajaxEnd
values, as well as the start
and end
values passed to the frontend bar.
"ajaxStart: 1399493273103421"
"ajaxEnd: 1399493273252544"
"start: 1399493273252544"
"end: 1399493273288"
Both ajaxStart
and ajaxEnd
are longer (more accurate) than start
and end
were previously. They're pulled from event.timeStamp
. ajaxEnd
becomes start
in this instance, and end
is calculated from new Date().getTime()
. So this is why the time is off; subtracting the less accurate end
from the more accurate start
results in a negative, incorrect number. Not totally sure what the fix is yet.
Ah, this is apparently a bug in Firefox regarding the definition of "epoch". Awesome.
It's been resolved upstream, thanks for reporting.
This is what I'm seeing:
The backend time is being correctly calculated, although it's being shoved offscreen because of the incorrect frontend time.