Skip to content

fix: pivot table sort state lost on refresh#9117

Merged
djbarnwal merged 1 commit intomainfrom
fix/pivot-sort-state
Mar 25, 2026
Merged

fix: pivot table sort state lost on refresh#9117
djbarnwal merged 1 commit intomainfrom
fix/pivot-sort-state

Conversation

@djbarnwal
Copy link
Copy Markdown
Member

@djbarnwal djbarnwal commented Mar 25, 2026

Due to an earlier regression, the pivot sort state was getting lost on refresh

  • Pivot sort by time dimensions (e.g., timestamp_rill_TIME_GRAIN_HOUR) and minimized accessors (e.g., c0v2m0) were silently dropped during URL deserialization on page refresh
  • Serialization now correctly maps _rill_ format sort IDs to URL-friendly time.{grain} format
  • Deserialization reconstructs the full {timeDimension}_rill_{grain} format using metricsView.timeDimension, and no longer drops unrecognized sort IDs (like minimized accessors)
  • Updated AD_BIDS_SORT_PIVOT_BY_TIME_DAY_ASC test mutation to use the realistic _rill_ format that TanStack Table actually generates

https://rilldata.slack.com/archives/C02T907FEUB/p1773768057523809

Checklist:

  • Covered by tests
  • Ran it and it works as intended
  • Reviewed the diff before requesting a review
  • Checked for unhandled edge cases
  • Linked the issues it closes
  • Checked if the docs need to be updated. If so, create a separate Linear DOCS issue
  • Intend to cherry-pick into the release branch
  • I'm proud of this work!

@djbarnwal djbarnwal requested a review from AdityaHegde March 25, 2026 09:22
@djbarnwal djbarnwal merged commit 97db216 into main Mar 25, 2026
25 of 28 checks passed
@djbarnwal djbarnwal deleted the fix/pivot-sort-state branch March 25, 2026 14:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants