-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
Fix timelion data-render-complete attribute on resize #29320
Fix timelion data-render-complete attribute on resize #29320
Conversation
Adding a watch to the renderComplete promise to fix missing rendering of chart when the resize observer detect a change in size. Removed the existing resize observer.
It's need on the timelion app to resize since that app doesn't use visualize loader
Pinging @elastic/kibana-app |
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.
Marco demonstrated the failure and we looked at the code together. LGTM. Let's hope it's really finally solving all those Timelion testing flakyness.
💚 Build Succeeded |
jenkins, test this (checking for flakyness) |
💚 Build Succeeded |
jenkins, test this (checking for flakyness) |
Thanks for tackling this @markov00! Any idea why it started failing so consistently all of a sudden? |
💚 Build Succeeded |
@stacey-gammon I think this bug was here since for a lot of time. I'm not sure but I think that we have introduced some slight changes on the styles of components, dashboard etc that introduced the problem of rerendering or resizing. Unfortunately I don't know more than that |
* Fix timelion missing renderer on resize Adding a watch to the renderComplete promise to fix missing rendering of chart when the resize observer detect a change in size. Removed the existing resize observer. * Revert removing observe resize It's need on the timelion app to resize since that app doesn't use visualize loader * Change double watch to watchgroup * Reenable skipped dashboard test
* Fix timelion missing renderer on resize Adding a watch to the renderComplete promise to fix missing rendering of chart when the resize observer detect a change in size. Removed the existing resize observer. * Revert removing observe resize It's need on the timelion app to resize since that app doesn't use visualize loader * Change double watch to watchgroup * Reenable skipped dashboard test
Fix #28818
Fix #22561
Fix #24292
There is a special case, when trying to resize a bit the visualization in a dashboard, as shown in the screenshot, that trigger a new render cycle from the
visualize-chart
loader, but doesn't complete a full rendering on the chart because the data doesn't change, thus thedata-render-complete
is never switched to true.On #28818, I'm imagine that minor resize triggers when adding a visualization to the dashboard encounter the described bug, thus wrongly missing the render cycle avoiding set the
data-render-complete
attribute to false.Extra: we have an extra resize-observer that trigger a check on the size every 500ms. We cannot get rid of the extra resize-observer because it's used directly from the timelion app itself.