fix(slack): Drop stale aggregateSort in explore unfurl when field is unknown#114334
Merged
DominikB2014 merged 3 commits intomasterfrom Apr 29, 2026
Merged
Conversation
…unknown When an Explore traces URL contains an aggregateSort that references a function not in the active aggregateField yAxes/groupBys (a stale sort left over from a different visualize), the events-timeseries call sorts top events by an aggregate it never selected and returns no data, so the Slack unfurl renders no chart. Mirror the frontend's validateAggregateSort: validate every entry of the URL sort against the parsed yAxes and groupBys, and discard the sort when any entry is unknown so the unfurl falls back to the default `-yAxes[0]` top-events sort. Co-Authored-By: Claude <noreply@anthropic.com>
Co-Authored-By: Claude <noreply@anthropic.com>
Logs use `logsSortBys` to sort the log table on columns like `timestamp`, not aggregate functions. The new validation only applies to `aggregateSort` (spans, metrics). Co-Authored-By: Claude <noreply@anthropic.com>
edwardgou-sentry
approved these changes
Apr 29, 2026
3 tasks
cleptric
pushed a commit
that referenced
this pull request
May 5, 2026
…unknown (#114334) Fix Slack unfurls of Explore traces URLs that carry an `aggregateSort` referencing a function that isn't in the active `aggregateField` yAxes/groupBys (a stale sort left over from an earlier `visualize` selection). Mirror the frontend's validateAggregateSort Refs #114188 --------- Co-authored-by: Claude <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fix Slack unfurls of Explore traces URLs that carry an
aggregateSortreferencing a function that isn't in the activeaggregateFieldyAxes/groupBys (a stale sort left over from an earliervisualizeselection).Mirror the frontend's validateAggregateSort
Refs #114188