From 33127ff382fcb59df9ee45abe88e51736df93078 Mon Sep 17 00:00:00 2001 From: Daniel Beardsley Date: Thu, 20 Nov 2025 10:35:43 -0800 Subject: [PATCH] Sorting: Let's move new pulls to the top Previously, with older pulls on top, newer pulls would get less attention until *they too* were old. Yes, there are likely some process changes so that we have less old pulls sitting around. But at the moment, it's rather unhelpful to have most new things be relegated to the end of the list. --- frontend/src/pulldasher/sort.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/frontend/src/pulldasher/sort.ts b/frontend/src/pulldasher/sort.ts index 9846a91c..388b01e1 100644 --- a/frontend/src/pulldasher/sort.ts +++ b/frontend/src/pulldasher/sort.ts @@ -9,7 +9,9 @@ export function defaultCompare(a: Pull, b: Pull): number { // Pulls I have to CR/QA above those I don't compareBool(a.hasOutdatedSig(getUser()), b.hasOutdatedSig(getUser())) || // Pulls I haven't touched vs those I have already CRed - compareBool(!a.hasCurrentSig(getUser()), !b.hasCurrentSig(getUser())) + compareBool(!a.hasCurrentSig(getUser()), !b.hasCurrentSig(getUser())) || + // younger pulls above older pulls so new things get review sooner + b.created_at.localeCompare(a.created_at) ); } @@ -25,8 +27,8 @@ export function QACompare(a: Pull, b: Pull): number { compareBool(!a.getLabel("QAing"), !b.getLabel("QAing")) || // Pulls with CR completed above those that need more compareBool(a.isCrDone(), b.isCrDone()) || - // Older pulls before younger pulls - a.created_at.localeCompare(b.created_at) + // younger pulls before older pulls + b.created_at.localeCompare(a.created_at) ); }