profiler icon indicating copy to clipboard operation
profiler copied to clipboard

Chrome profiles are shown with 1/1/1970 datestamp (prominently in tab title)

Open dholbert opened this issue 3 years ago • 4 comments

STR:

  1. Record a profile in Google Chrome.
  2. Export that profile to a JSON file (using the downarrow icon near the top-left of Chrome's profiler UI)
  3. Visit https://profiler.firefox.com/ and upload the Chrome profile there.
  4. Look at the title of the resulting page (as shown on your tab-title, for example)

ACTUAL RESULTS: Title is "Chrome Trace - 1/1/1970"

EXPECTED RESULTS: Clearly the date was not present or not found, so it should be omitted or replaced with "Unknown date" or something like that.

Here's a profile that I just captured and uploaded, as an example: https://share.firefox.dev/3rePWHa

And here's a screenshot of the page title as shown in my tab-strip: image

┆Issue is synchronized with this Jira Task

dholbert avatar Jan 31 '22 20:01 dholbert

I don't think we have the information in the profile, but I guess we could use Date.now() as a good approximation when converting the profile.

julienw avatar Feb 07 '22 17:02 julienw

In this area: https://github.com/firefox-devtools/profiler/blob/4f0c5af6c42365a2296620572e30c886de34be74/src/profile-logic/import/chrome.js#L468-L470 we could set startTime in the meta object.

julienw avatar Feb 07 '22 17:02 julienw

Could be fixed by https://github.com/firefox-devtools/profiler/pull/4797

julienw avatar Oct 07 '24 15:10 julienw

It could if one was willing to put (manually or automatically) the timestamp for time 0 inside the profile filename

kazarmy avatar Oct 08 '24 10:10 kazarmy

This is fixed by #5188.

canova avatar Nov 19 '24 12:11 canova