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

Pivot table becomes broken if a breakout clause is added without visualizing the question #42697

Closed
ranquild opened this issue May 15, 2024 · 0 comments · Fixed by #42698
Closed
Assignees
Labels
.Frontend Priority:P2 Average run of the mill bug Type:Bug Product defects Visualization/Tables Raw, summarized, and pivoted tables
Milestone

Comments

@ranquild
Copy link
Contributor

ranquild commented May 15, 2024

Describe the bug

When a saved question was visualized as a pivot table and its column widths were changed, then adding another breakout clause without visualizing the question will break it without the ability to recover.

To Reproduce

  • New -> Question -> Select Orders
  • Summarize by “Count”, “Sum of (Total)“, Breakout by “User.State”, “Orders.Created At”
  • Visualize
  • Change the viz type to “Pivot table”
  • Change the title (left) column width via the resize handle in the column header
  • Save the question now
  • Open the notebook editor
  • Add another breakout “Product.Category”
  • Save the question now without visualizing
  • Visualize now
Screenshot 2024-05-15 at 14 04 43

Expected behavior

The table should render without errors

Logs

FE logs:

querying.js:203 Error: Invalid metadata returned for cell 1:
        x:262, y:0, width:NaN, height:30
    at t.cellCount (calculateSizeAndPositionData.js:17:13)
    at t.value (calculateSizeAndPositionData.js:35:1)
    at t.value (CollectionView.js:315:27)
    at ij (react-dom.production.min.js:182:192)
    at iI (react-dom.production.min.js:181:224)
    at l (react-dom.production.min.js:263:490)
    at aH (react-dom.production.min.js:246:265)
    at react-dom.production.min.js:246:194
    at aW (react-dom.production.min.js:246:199)
    at react-dom.production.min.js:123:115

Information about your Metabase installation

0.49

Severity

Breaks questions without being able to recover from the UI.

Additional context

No response

@ranquild ranquild added Type:Bug Product defects Priority:P2 Average run of the mill bug .Frontend Visualization/Tables Raw, summarized, and pivoted tables labels May 15, 2024
@ranquild ranquild self-assigned this May 15, 2024
@ranquild ranquild changed the title If leftHeaderWidths pivot viz setting goes out of sync with data the table will crash Pivot table becomes broken if a breakout clause is added without visualizing the question May 15, 2024
@ranquild ranquild added this to the 0.49.12 milestone May 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
.Frontend Priority:P2 Average run of the mill bug Type:Bug Product defects Visualization/Tables Raw, summarized, and pivoted tables
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant