Files
kandev/apps/backend/internal/analytics/repository/sqlite
João Salavisa 88f69df702 fix: include archived tasks in completed tasks over time chart (#668)
* fix: include archived tasks in completed tasks over time chart

Archived tasks without a session completed_at were excluded from the
Completed Tasks Over Time chart. Use COALESCE(session.completed_at,
task.archived_at) as the completion date so archived tasks fall back
to their archive timestamp.

* fix: address review feedback - isolate completion paths in test

- Remove archived_at from task-regular so it only counts via session
  completed_at (CodeRabbit nitpick)
- Add task-last-step-no-dates to verify COALESCE IS NOT NULL filter
  excludes tasks with neither date (Claude suggestion)

---------

Co-authored-by: Kandev Agent <agent@kandev.dev>
2026-04-21 01:36:04 +01:00
..