You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Improve priority sorting by using due date as secondary key #527
Currently, when tasks are sorted by priority, tasks with the same priority are not ordered further, which can lead to inaccurate or confusing ordering.
For example, multiple tasks with priority H appear in an arbitrary order instead of being ordered by urgency or due date.
How would you like to see it implemented?
Sort tasks by priority as the primary key (H > M > L).
When two tasks have the same priority, sort them by due date.
Tasks without a due date should appear after tasks with a due date.
Keep the logic local to each sorting implementation to match existing patterns and avoid cross-layer refactors.
Put here any screenshots or videos (optional)
Before:
After:
How can we contact you (optional)
No response
Would you like to work on this issue?
Yes
By submitting this issue, I have confirmed that:
I have starred the repo ⭐ and watched 👀 it on GitHub and followed the contribution guidelines.
Hi! I'd like to work on this issue. I noticed the earlier PR for it was closed when the main-old base branch was deleted, so I'll implement it fresh against current main.
Plan:
Keep the logic local to each sorting implementation, as the issue suggests (comparator.dart, show_tasks.dart, show_tasks_replica.dart, widget.controller.dart).
Priority stays the primary key (H > M > L); ties are broken by due date, with tasks that have no due date placed last.
Use null-safe due date comparison everywhere (the replica view currently compares raw strings) and remove the forced ! unwraps on priority.
Add unit tests for equal-priority and null-due-date cases.
Activity
Neo-matrix-coder commentedon Oct 23, 2026
/assign
Neo-matrix-coder commentedon Oct 23, 2026
Hi! I'd like to work on this issue. I noticed the earlier PR for it was closed when the main-old base branch was deleted, so I'll implement it fresh against current main.
Plan:
!unwraps on priority.Could you please assign this to me?