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

[XY Axis] Fix bug on percentiles and percentiles ranks #88576

Merged
merged 11 commits into from
Jan 25, 2021

Conversation

stratoula
Copy link
Contributor

@stratoula stratoula commented Jan 18, 2021

Summary

Closes #88424. This PR fixes the bug on xy plugin with the percentiles and percentiles ranks. The renderAllSeries function returned null for these two aggregations and as a result, the chart wasn't rendered with the No data message. I have enhanced the function to also work with percentiles.

Screenshot 2021-01-18 at 1 22 20 PM

Checklist

@stratoula
Copy link
Contributor Author

@elasticmachine merge upstream

@stratoula stratoula requested a review from nickofthyme January 18, 2021 11:44
@stratoula stratoula added v8.0.0 release_note:skip Skip the PR/issue when compiling release notes v7.12.0 Feature:XYAxis XY-Axis charts (bar, area, line) labels Jan 18, 2021

const splitSeriesAccessors = useMemo(
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is irrelevant with the bug but it is an improvement to avoid unnecessary renders so I have included it here.

Copy link
Contributor

@nickofthyme nickofthyme left a comment

Choose a reason for hiding this comment

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

LGTM, changes fix issue. Tested locally on chrome.

@stratoula
Copy link
Contributor Author

@elasticmachine merge upstream

@stratoula stratoula marked this pull request as ready for review January 20, 2021 06:41
@stratoula stratoula requested a review from a team January 20, 2021 06:41
@stratoula stratoula added the Team:Visualizations Visualization editors, elastic-charts and infrastructure label Jan 20, 2021
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-app (Team:KibanaApp)

@stratoula
Copy link
Contributor Author

@elasticmachine merge upstream

@stratoula stratoula requested a review from mbondyra January 21, 2021 07:11
@stratoula
Copy link
Contributor Author

@elasticmachine merge upstream

@stratoula
Copy link
Contributor Author

@elasticmachine merge upstream

@stratoula
Copy link
Contributor Author

@elasticmachine merge upstream

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
visTypeXy 157.4KB 157.8KB +389.0B

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

Copy link
Contributor

@dej611 dej611 left a comment

Choose a reason for hiding this comment

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

Code LTGM 👍 . Also tested locally and it works as expected (compared legacy and this fix and they are the same chart)

@stratoula stratoula merged commit 2ff5235 into elastic:master Jan 25, 2021
stratoula added a commit to stratoula/kibana that referenced this pull request Jan 25, 2021
* [XY Axis] Fix bug on percentiles and percentiles ranks

* Add unit tests to renderAllSeries

* make it simpler

* Minor change on test

* Fix license headers

Co-authored-by: Kibana Machine <[email protected]>
stratoula added a commit that referenced this pull request Jan 25, 2021
* [XY Axis] Fix bug on percentiles and percentiles ranks

* Add unit tests to renderAllSeries

* make it simpler

* Minor change on test

* Fix license headers

Co-authored-by: Kibana Machine <[email protected]>

Co-authored-by: Kibana Machine <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:XYAxis XY-Axis charts (bar, area, line) release_note:skip Skip the PR/issue when compiling release notes Team:Visualizations Visualization editors, elastic-charts and infrastructure v7.12.0 v8.0.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Visualize] Percentiles are not displayed for new charts library
5 participants