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

Customize html report #1631

Closed
krukru opened this issue May 29, 2017 · 10 comments
Closed

Customize html report #1631

krukru opened this issue May 29, 2017 · 10 comments

Comments

@krukru
Copy link
Contributor

krukru commented May 29, 2017

Is it possible to customise the summary, detailed summary and pages page with custom metrics?

I would like to add the gpsi score and some custom metrics to be displayed on the summary page and add new rows to the detailed summary and new columns to the pages page so I can quickly find problematic entries

@soulgalore
Copy link
Member

Hi @krukru we had it in older 3.x versions but in the current version itsn't possible at the moment. By custom metrics, do you mean metrics that you fetched with JS? I think we should automagically add them (we use to do that) at least on some levels. For GPSI we need think about a generic way to handle so we can do it for all plugins.

@krukru
Copy link
Contributor Author

krukru commented May 29, 2017

Hi @soulgalore

Yes, I wanted to add some custom JS metrics and the gpsi score since it's an important metric in our organisation. The custom JS metrics get added to the summary and detailed summary pages, which is great, but I would also need this for gpsi as well. Like you said, this should be true for other plugins, so it's something to put on the bucket list.

Also, neither JS metrics nor gpsi get added to the pages, which could be useful to quickly find the pages with the lowest (custom metric) score. Just a thought :)

@soulgalore
Copy link
Member

cool, yep cool let see, for gpsi we don't do any summary at the moment (so we can push to details/summary page), I was kind of hoping for PRs for that :)

The "pages"-page is hardcoded but let me check the coming days if I can add custom metrics to it, it shouldn't be much work, the problem is more how we can make sure the layout is ok.

@soulgalore
Copy link
Member

Let me push GPSI tonight, the code there is a little messy so I can just fix that.

@krukru
Copy link
Contributor Author

krukru commented May 30, 2017 via email

@krukru
Copy link
Contributor Author

krukru commented Jun 5, 2017

Hello again @soulgalore

First off thank you for the update :)

I think I found a bug in your latest commit, so I will just report it here.

The bug happens if for any reason (my reason was api quota exceeded) gpsi does not return a score.
The expected behaviour would be that the GPSI column would get greyed out and performance score should get displayed as normal, however really the two columns get swapped when there is no gpsi score.
When there is a gpsi score, the column order is fine.

Please see https://ibb.co/ehcEtF
The page actually has a performance score of 73 and no gpsi.

This brings a question, does --browsertime.delay apply also to gpsi (in my experience it does not), since I have a large number of pages that need to be checked and halfway along the list i hit the api quota limit.

@soulgalore
Copy link
Member

Hi @krukru yes, I think we don't look for errors from GPSI. Can you see exactly what we get back when we hit the limit (so we can catch that)? Do we get an error or a result with some kind of message?

Best
Peter

@krukru
Copy link
Contributor Author

krukru commented Jun 7, 2017

Hi @soulgalore

Here is the error message I get, hope it helps. https://gist.github.com/krukru/3a7468546440920c027b05dd73a84c8d

@soulgalore
Copy link
Member

Hey @krukru in the latest 6.0 plugins can generate HTML + plugins can talk to each other and your plugin can send JavaScript to Browsertime to execute. This will not solve everything but you can at least add whatever custom metrics you want.

@krukru
Copy link
Contributor Author

krukru commented Nov 24, 2017

Thank you Peter for all the good work you are putting into this tool :-)

@krukru krukru closed this as completed Nov 24, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants