Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

core(user-timings): add back startTime #5442

Merged
merged 7 commits into from
Jun 11, 2018
Merged

Conversation

patrickhulce
Copy link
Collaborator

Related Issues/PRs
closes #5418

@@ -118,6 +118,7 @@ class UserTimings extends Audit {
const time = item.isMark ? item.startTime : item.duration;
return {
name: item.name,
startTime: item.startTime,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can you assert this in user-timing-test?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@@ -118,6 +118,7 @@ class UserTimings extends Audit {
const time = item.isMark ? item.startTime : item.duration;
return {
name: item.name,
startTime: item.startTime,
timingType: item.isMark ? 'Mark' : 'Measure',
time,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just noticed.. this name seems pretty weak. duration? timeInMs?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

agreed, duration and startTime are better names, and they match the standard names

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

well that name is weak because it's either or and just for display, I added duration separately, but programmatic folks should probably just ignore time

maybe update to timeToDisplay?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's always been a bit odd that we share a column for two diff types of values

how about we add a second column, then we can be really clear with Start time and Duration. wdyt?

Copy link
Member

@paulirish paulirish left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

add additional column? does it mess too much with our types to have undefined/null durations?

@patrickhulce
Copy link
Collaborator Author

add additional column? does it mess too much with our types to have undefined/null durations?

done

Copy link
Member

@paulirish paulirish left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

tests fail but otherwise lgtm

@patrickhulce patrickhulce merged commit 9cc37d4 into master Jun 11, 2018
@patrickhulce patrickhulce deleted the more_user_timing_details branch June 11, 2018 22:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

lighthouse 3 regression in user-timings details
3 participants