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

X-ray dashboards crash on first opening #18028

Closed
kulyk opened this issue Sep 23, 2021 · 3 comments · Fixed by #18045
Closed

X-ray dashboards crash on first opening #18028

kulyk opened this issue Sep 23, 2021 · 3 comments · Fixed by #18045
Assignees
Labels
.Frontend Priority:P1 Security holes w/o exploit, crashing, setup/upgrade, login, broken common features, correctness Querying/Parameters & Variables Filter widgets, field filters, variables etc. Querying/X-rays .Regression Bugs that were previously fixed and/or bugs unintentionally shipped with new features. Reporting/Dashboards .Reproduced Issues reproduced in test (usually Cypress) Type:Bug Product defects
Milestone

Comments

@kulyk
Copy link
Member

kulyk commented Sep 23, 2021

Describe the bug
The first time you open an automatic dashboard (suggested while x-raying a database table), it crashes and you see a blank page.

Logs

Uncaught TypeError: Cannot read properties of undefined (reading 'some')
    at Dashboard.js:253
    at Array.some (<anonymous>)
    at hasMapping (Dashboard.js:252)
    at isDashboardParameterWithoutMapping (Dashboard.js:267)
    at ParameterValueWidget.render (ParameterValueWidget.jsx:166)

To Reproduce
Steps to reproduce the behavior:

  1. Go to /browse/1-sample-dataset
  2. Hover the Orders table and click the yellow x-ray button
  3. You're navigated to a dashboard based on Orders. Click the "Save this" button in the top right without any edits
  4. After the dashboard is saved, you should see a toast message in the bottom left. Click the "See it" link
  5. FE crashes and you see a blank page

Workaround: refresh the page

Expected behavior
You should see the dashboard without a need to refresh

Screenshots

Screen.Recording.2021-09-23.at.17.45.08.mov

Information about your Metabase Installation:

Metabase v0.41.0-SNAPSHOT

@kulyk kulyk added Type:Bug Product defects .Needs Triage labels Sep 23, 2021
@kulyk
Copy link
Member Author

kulyk commented Sep 23, 2021

Hey @daltojohnso, from the browser logs I suppose it's caused by #17956. Can you please take a look?

@kulyk kulyk added .Regression Bugs that were previously fixed and/or bugs unintentionally shipped with new features. Querying/Parameters & Variables Filter widgets, field filters, variables etc. Querying/X-rays Reporting/Dashboards .Frontend labels Sep 23, 2021
@flamber flamber added Priority:P1 Security holes w/o exploit, crashing, setup/upgrade, login, broken common features, correctness and removed .Needs Triage labels Sep 23, 2021
@rlotun
Copy link
Contributor

rlotun commented Sep 23, 2021

I'm surprised we don't have an e2e test for this since it's an easy repro - it's probably an opportunity to add one. cc/ @nemanjaglumac

@nemanjaglumac
Copy link
Member

@rlotun we do have a few different repros around x-rays but we missed this particular scenario of saving an x-ray and then immediately navigating to. I'll add it in a moment. Thanks for bringing it to my attention.

nemanjaglumac added a commit that referenced this issue Sep 23, 2021
@nemanjaglumac nemanjaglumac added the .Reproduced Issues reproduced in test (usually Cypress) label Sep 23, 2021
@flamber flamber added this to the 0.41 milestone Sep 24, 2021
This was referenced Feb 17, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
.Frontend Priority:P1 Security holes w/o exploit, crashing, setup/upgrade, login, broken common features, correctness Querying/Parameters & Variables Filter widgets, field filters, variables etc. Querying/X-rays .Regression Bugs that were previously fixed and/or bugs unintentionally shipped with new features. Reporting/Dashboards .Reproduced Issues reproduced in test (usually Cypress) Type:Bug Product defects
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants