refactor: centralize task filter parsing #361

Closed
opened 2026-05-11 21:02:05 +00:00 by barrettruth · 0 comments
Owner

Parent: #355

Problem

Task filter construction is duplicated across dashboard data loading, task API listing, and iCal export. Status, date, sort, and default filters are loosely cast in multiple places.

Solution

Introduce a shared task-filter parser/normalizer:

  • parse status lists, date aliases, sort fields, and defaults in one module
  • keep existing behavior unless tests explicitly pin a better validation response
  • route dashboard, task API, and iCal export through the shared parser

Acceptance criteria

  • Dashboard, /api/tasks, and iCal export use the same filter contract.
  • Existing filter behavior is preserved and tested.
  • Invalid or unknown values are handled consistently.
Parent: #355 ## Problem Task filter construction is duplicated across dashboard data loading, task API listing, and iCal export. Status, date, sort, and default filters are loosely cast in multiple places. ## Solution Introduce a shared task-filter parser/normalizer: - parse status lists, date aliases, sort fields, and defaults in one module - keep existing behavior unless tests explicitly pin a better validation response - route dashboard, task API, and iCal export through the shared parser ## Acceptance criteria - Dashboard, `/api/tasks`, and iCal export use the same filter contract. - Existing filter behavior is preserved and tested. - Invalid or unknown values are handled consistently.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
barrettruth/delta#361
No description provided.