explore: document sortable-dataset contract, drop dead discover entry - #1524
Merged
Conversation
There is no machine-readable canonical source for which datasets accept a sort param: the OpenAPI spec (@sentry/api listOrganizationEvents) models sort as a flat query param and has no dataset-capability endpoint, and its dataset enum does not include discover. Since discover is not a valid --dataset value (see DATASET_ALIASES), the discover entry in SORTABLE_DATASETS was unreachable; remove it and record the findings as a documented contract instead. Fixes #1523
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Contributor
Author
|
CI green (4s), self-review clean. Ready for review. |
BYK
approved these changes
Sep 2, 2026
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.
Follow-up to #1520. Investigates whether a canonical, machine-readable source exists for "which datasets accept a sort on grouped aggregates" and records the finding.
Result: no such source exists today. The OpenAPI spec (
@sentry/apilistOrganizationEvents) modelssortas a flat query param whose only documented constraint is "must be in thefieldlist" — it does not encode per-dataset sort capability, and there is no dataset-capability introspection endpoint. The spec'sdatasetenum (errors | logs | profile_functions | spans | tracemetrics | uptime_results) does not even includediscover.Given that, the hand-curated
SORTABLE_DATASETSset stays, but:discoverentry is removed — it was unreachable, sincediscoveris not a valid--datasetvalue (seeDATASET_ALIASES).Testing
vitest run test/commands/explore.test.ts(40 passed) andtest/lib/api/explore.test.ts(18 passed); biome clean on the changed file.Refs #1523