-
Notifications
You must be signed in to change notification settings - Fork 22
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
Add option to partition results table by measurements #198
base: main
Are you sure you want to change the base?
Conversation
@aomarks I can't seem to get the Travis tests to re-run (it looks like a Safari flake in an unrelated test?) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, just a comment about the name.
CHANGELOG.md
Outdated
@@ -7,6 +7,9 @@ project adheres to [Semantic Versioning](http://semver.org/). | |||
|
|||
<!-- ## Unreleased --> | |||
|
|||
- Add `collate` option for collating results tables by measurement (when |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about partition: "measurement"
?
I also thought about names compare
and group-by
, but I'm leaning towards partition
because it seems to best describe "the thing you want to do to the table after you see that it's too big".
Also I'm thinking the value should be measurement
instead of true
so that we have more room to expand with more partitioning options in the future.
WDYT?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, that's nice. So conceptually we could add something like partition: "browser"
to partition the results table based on browser? And next level, make it an array to partition on multiple dimensions, i.e. browser and measurement?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sounds good. Was out yesterday but will try and get an update up soon.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've addressed the feedback. All instances of collate: true
have been replaced by partition: "measurement"
.
I also added documentation to the README for the new option.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Love this! 🎉
CHANGELOG.md
Outdated
@@ -7,6 +7,9 @@ project adheres to [Semantic Versioning](http://semver.org/). | |||
|
|||
<!-- ## Unreleased --> | |||
|
|||
- Add `collate` option for collating results tables by measurement (when |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, that's nice. So conceptually we could add something like partition: "browser"
to partition the results table based on browser? And next level, make it an array to partition on multiple dimensions, i.e. browser and measurement?
@@ -13,6 +13,7 @@ | |||
"scripts": { | |||
"prepare": "if [ -f './tsconfig.json' ]; then npm run build; fi;", | |||
"build": "rimraf lib/ client/lib/ && mkdir lib && npm run generate-json-schema && tsc && tsc -p client/ && npm run lint", | |||
"build:watch": "tsc --watch", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good call!
src/format.ts
Outdated
@@ -104,6 +105,23 @@ export function automaticResultTable(results: ResultStats[]): AutomaticResults { | |||
return {fixed: fixedTable, unfixed: unfixedTable}; | |||
} | |||
|
|||
export function collatedResultTables(results: ResultStatsWithDifferences[]) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would there be any value in skipping the difference computation for dimensions that are partitioned? Though I guess that is larger breaking change that impacts more parts of the code.... Perhaps something to explore later?
Love this! It is a huge improvement for readability of the results 🙌 |
Still interested in having this. What are the open tasks to get this in? |
Hi there, are there any plans to get this merged? Very useful and would like to use it in our benchmark set up |
@aomarks 🥇 |
I've found an edge case for small results tables that can't be partitioned. E.g.
This has been partitioned from:
My expectation would be that there would still be a benchmark name. On further investigation, this seems to be working as intended for small tables. However when partitioning a table into 3 small tables, the result becomes confusing due to a lack of benchmark name field. |
Fixes #197
collate: false
partition: undefined
:collate: true
partition: "measurement"
: