-
Notifications
You must be signed in to change notification settings - Fork 13.9k
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(Dashboard): Sync/Async Dashboard Screenshot Generation #30755
Conversation
4c123c5
to
48c681d
Compare
48c681d
to
c9bab36
Compare
Moving this to draft as we might change the approach here, bring back the previous frontend-generated screenshots while having the feature flag to enable Selenium generated screenshots optionally. |
c9bab36
to
fe5017c
Compare
Thanks for the updated version of the PR @geido. Do you think we need |
This is to be consistent with the thumbnails endpoint that are also behind feature flag. In general, I think it is good to be intentional about enabling these endpoints as they expose performance-heavy functionality. |
fe5017c
to
e9816f7
Compare
/testenv up |
@geido Ephemeral environment spinning up at http://35.90.38.171:8080. Credentials are |
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.
Thank you so much for the fix @geido!
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.
LGTM!
Can we have a link to the PR that caused this regression? Just to make it easier to discover and understand how we can avoid these types of things in the future.. |
e620ac7
to
4b79ed0
Compare
Ok, I think the exception for the rgbcolor license resolved CI. @villebro we need an owner approval 🙏🏼 |
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.
Approving license override
Description updated |
Ephemeral environment shutdown and build artifacts deleted. |
…t Cache (#30755) Co-authored-by: Michael S. Molina <[email protected]> Co-authored-by: Michael S. Molina <[email protected]> (cherry picked from commit 3e29777)
SUMMARY
PR #29187 introduced a new endpoint for generating dashboard screenshots and PR #29272 made this endpoint mandatory for the frontend. However, Celery should be an optional dependency in Superset and the endpoint is dependent on Celery to work. This PR makes Celery optional for generating dashboard screenshots by:
Reintroducing the previous download screenshot functionality:
This update enables dashboards to be downloaded directly from the browser, without using the dedicated API endpoint. This approach has known CORS limitations but will work for most cases where Celery isn't configured.
Adding two new feature flags:
ENABLE_DASHBOARD_SCREENSHOT_ENDPOINTS
:Controls whether the API endpoint that caches and retrieves dashboard screenshots via a webdriver is enabled, allowing this functionality to be decoupled from the UI. This flag is set to
False
by default.ENABLE_DASHBOARD_DOWNLOAD_WEBDRIVER_SCREENSHOT
:Controls whether the UI’s download functionality uses webdriver-based screenshot generation. This flag is also
False
by default and it is dependent onENABLE_DASHBOARD_SCREENSHOT_ENDPOINTS
.Fixes #30645
TESTING INSTRUCTIONS
ADDITIONAL INFORMATION
ENABLE_DASHBOARD_SCREENSHOT_ENDPOINTS
andENABLE_DASHBOARD_DOWNLOAD_WEBDRIVER_SCREENSHOT