Support multi-column sort in the Dags list table - #72558
Open
Andrushika wants to merge 1 commit into
Open
Conversation
Andrushika
requested review from
bbovenzi,
choo121600,
guan404ming,
pierrejeambrun,
ryanahamilton,
shubhamraj-git and
vatsrahul1001
as code owners
September 5, 2026 10:48
Andrushika
commented
Sep 5, 2026
Comment on lines
+32
to
+39
| const isSameSorting = (sorting: SortingState, defaultSorting: SortingState | undefined) => | ||
| defaultSorting?.length === sorting.length && | ||
| sorting.every((sort, index) => { | ||
| const defaultSort = defaultSorting[index]; | ||
|
|
||
| return defaultSort?.id === sort.id && defaultSort.desc === sort.desc; | ||
| }); | ||
|
|
Contributor
Author
There was a problem hiding this comment.
This keeps the existing behavior on main: when the sort equals the one remembered in localStorage, the sort param is dropped from the URL. I think the query param should always sync with the sort that is actually applied, so a shared link shows the same order. If reviewers agree, I would like to change that in a follow-up PR.
Andrushika
force-pushed
the
multisort-dags-list
branch
from
September 5, 2026 15:01
ebe5bad to
2ff94f3
Compare
Sorting by latest run with a single criterion leaves Dags without runs in reverse alphabetical order, because the backend applies the primary key tiebreak in the same direction as the primary sort. The backend already accepts several order_by values, but the Dags list only sent the first one and the URL serializer dropped every sort but the last.
Andrushika
force-pushed
the
multisort-dags-list
branch
from
September 5, 2026 15:55
2ff94f3 to
f6dec1e
Compare
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.
Why
Sorting the Dags list by latest run puts Dags without any run in reverse alphabetical order. The backend already accepts several
order_byvalues since #53408, but the Dags list only sent the first one.What
Send every sort from the table state as
order_by, and write all of them to the URL. Shift-click on a column header adds a secondary sort.Card view still has a single sort dropdown, so there is no way to set a secondary sort there. But a sort set in table view can still apply after switching to card view. I plan to add a secondary sort control to card view in a follow-up PR.
2026-09-05.6.43.53.mov
closes: #46383
Was generative AI tooling used to co-author this PR?
Generated-by: Claude Code (Fable 5.1) following the guidelines