backlog-md/backlog/completed/task-001.md

1.6 KiB

id: task-001 title: Fix aggregator drag & drop line ending bug status: Done assignee: [@claude] created_date: '2025-12-05 12:21' labels: [dev-ops, bug-fix] priority: high dependencies: []

Description

Fixed the aggregator web UI drag & drop functionality that was failing to update task status. The issue was that the updateTaskField, addUpdatedDate, and updateTaskDescription functions only handled Unix line endings (\n), while the markdown parser correctly handled both Windows (\r\n) and Unix line endings.

When task files had Windows line endings (CRLF), the frontmatter regex would fail to match, causing the update to silently fail (returning unchanged content). The PATCH request would return success, but the actual file wasn't modified, so the WebSocket broadcast would revert the UI back to the old status.

Plan

  1. Investigate drag & drop functionality in aggregator web UI
  2. Identify root cause: line ending mismatch between parser and update functions
  3. Update updateTaskField to handle both CRLF and LF line endings
  4. Update addUpdatedDate with same fix
  5. Update updateTaskDescription with same fix
  6. Test the fix with both line ending types
  7. Push changes to remote

Acceptance Criteria

  • Drag & drop works with Unix (LF) line endings
  • Drag & drop works with Windows (CRLF) line endings
  • Original line ending style is preserved when writing back

Notes

Files modified: src/aggregator/index.ts

The fix detects the original line ending style and preserves it when writing back to maintain file consistency.