[dashboard] invalid dashboard displayed as 404 instead of showing validation error #211659
Labels
bug
Fixes for quality problems that affect the customer experience
Team:Presentation
Presentation Team for Dashboard, Input Controls, and Canvas
When loading a dashboard, any
contentManagementService.client.get
error is converted into aSavedObjectNotFound
error. This results in 404 error message when that is not always the case. The dashboard may exist, and instead, the end point failed for another reason, like maybe the content management schema validation failed.https://github.com/elastic/kibana/blob/main/src/platform/plugins/shared/dashboard/public/services/dashboard_content_management_service/lib/load_dashboard_state.ts#L87
Instead, only 404 errors should get converted to
SavedObjectNotFound
. The logic should be cleaned up like suchThe problem is that DashboardRenderer only renders the text of the error as unformatted text. This should probably be clean-up and display something better. Maybe design needs to get involved.
https://github.com/elastic/kibana/blob/main/src/platform/plugins/shared/dashboard/public/dashboard_container/external_api/dashboard_renderer.tsx#L107
The text was updated successfully, but these errors were encountered: