Commit Graph

16 Commits

Author SHA1 Message Date
Ralph Khreish
c2d6c18a96 feat(cli): implement loop command (#1571)
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-11 01:47:52 +01:00
Eyal Toledano
38c2c08af1 feat(cli): add --watch flag to list command for real-time updates (#1526)
Co-authored-by: Ralph Khreish <35776126+Crunchyman-ralph@users.noreply.github.com>
Fixes #1526 PR review comments from CodeRabbit and changeset-bot
2025-12-18 20:11:40 +01:00
Ralph Khreish
0e908be43a fix: improve branch naming logic for workflow commands (#1491) 2025-12-07 19:04:40 +01:00
Ralph Khreish
88d356817e fix: auth refresh issue (#1450) 2025-11-26 23:34:57 +01:00
Ralph Khreish
28fcc27411 feat: improve ham connection (#1451) 2025-11-26 23:20:44 +01:00
Ralph Khreish
2316e94b28 feat: reintroduce task-master generate command for task file generation (#1446) 2025-11-25 18:32:50 +01:00
Ralph Khreish
522d9af580 Ralph/chore/fix.coderabbit.issues (#1432) 2025-11-21 12:40:46 +01:00
Ralph Khreish
e66150e91c chore: add integration tests to new cli and mcp (#1430) 2025-11-20 19:36:17 +01:00
Ben Coombs
da8ed6aa11 fix: Treat cancelled tasks as complete in statistics and dependencies (#1393)
* fix: treat cancelled tasks as complete in statistics and dependencies

Fixes #1392

## Changes

- Add TERMINAL_COMPLETE_STATUSES constant including 'done', 'completed', 'cancelled'
- Update calculateTaskStatistics() to include cancelled tasks in completion %
- Update calculateSubtaskStatistics() to include cancelled subtasks in completion %
- Update calculateDependencyStatistics() to treat cancelled tasks as satisfied dependencies
- Update findNextTask() to treat cancelled tasks as complete for dependency resolution

## Impact

- Dashboard now correctly shows 100% for projects with only done/cancelled tasks
- Tasks depending on cancelled tasks are no longer permanently blocked
- Dependency metrics accurately reflect project state

## Tests

- Added comprehensive test suite with RED-GREEN-REFACTOR approach
- 9 tests covering completion %, subtask %, and dependency resolution
- All tests pass after fixes applied

* style: apply biome formatting

* style: apply biome formatting to all files

* fix: display fraction should show all terminal complete tasks, not just done

Previously the completion percentage correctly counted cancelled tasks
as complete (e.g., 100% for 14 done + 1 cancelled), but the fraction
display used stats.done which only counted 'done' status, showing
"100% 14/15" instead of "100% 15/15".

Added completedCount field to TaskStatistics interface to track all
terminal complete tasks (done + completed + cancelled) and updated
display to use this field for accurate fraction representation.

Updates:
- TaskStatistics interface now includes completedCount field
- calculateTaskStatistics() sets completedCount for display
- calculateSubtaskStatistics() sets completedCount for display
- Display lines now use completedCount instead of done count
- Added completedCount assertions to all relevant tests

Related to #1392

* refactor: centralize terminal status logic in @tm/core

Following code review feedback, extracted TERMINAL_COMPLETE_STATUSES
and isTaskComplete() to @tm/core as single source of truth. This
prevents duplication and potential drift between CLI and MCP layers.

Changes:
- Added TERMINAL_COMPLETE_STATUSES constant to @tm/core constants
- Added isTaskComplete() helper function to @tm/core constants
- Updated dashboard.component.ts to import from tm-core via CLI util
- Updated list.command.ts to import from tm-core via CLI util
- Updated task-loader.service.ts to use shared isTaskComplete()
- Created CLI convenience re-export in utils/task-status.ts

Architecture:
- Business logic now lives in @tm/core (proper layer)
- CLI provides convenience re-exports for ergonomics
- MCP already delegates to @tm/core (no changes needed)

Addresses review comments from @Crunchyman-ralph on PR #1393

* fix: remove unused TaskStatus import in task-loader.service

TypeScript error: TaskStatus was imported but no longer used after
refactoring to use isTaskComplete() helper.

* fix: correct subtask display and progress bar for cancelled tasks

Fixed two display bugs identified by cursor bot:

1. Subtask completion display now shows completedCount instead of done
   - Before: "Completed: 3/4" (only counted done tasks)
   - After: "Completed: 4/4" (counts done + cancelled as terminal complete)

2. Progress bar no longer double-counts cancelled tasks
   - Before: Green section (completionPercentage) + gray cancelled section
   - After: Green section includes cancelled (as terminal complete status)
   - Removed separate cancelled section from progress bar
   - Updated section numbers in comments (2-6 instead of 2-7)

These changes ensure visual consistency with the fix that treats cancelled
tasks as terminal complete for percentage calculations and dependency resolution.

Fixes cursor bot comments on PR #1393

* style: run biome formatter

* fix: keep cancelled tasks visually distinct in progress bar

Per reviewer feedback from Crunchyman-ralph, cancelled tasks should remain
visible as a separate gray section in the progress bar for better visibility,
even though they count as complete for the percentage calculation.

Changes:
- Green section shows 'done' tasks only
- Gray section shows 'cancelled' tasks (visually distinct but terminal complete)
- completionPercentage still includes both done and cancelled (correct)
- This prevents double-counting while maintaining visual clarity

Addresses: https://github.com/eyaltoledano/claude-task-master/pull/1393#issuecomment-3517115852

* fix: add done property to StatusBreakdown interface

TypeScript error: StatusBreakdown interface was missing 'done' property
required by the progress bar visualization code.

* fix: Populate done field in calculateStatusBreakdown for progress bar

The calculateStatusBreakdown() function was missing the calculation for the
'done' field, causing statusBreakdown.done to always be undefined. This meant
the green section of the progress bar never rendered, making completed tasks
invisible in the visual representation.

Addresses cursor bot feedback on PR #1393.

---------

Co-authored-by: Ben Coombs <bjcoombs@users.noreply.github.com>
2025-11-13 11:03:12 +01:00
Ralph Khreish
63134a222c feat: add tm tags command to remote (#1386)
Co-authored-by: Claude <noreply@anthropic.com>
2025-11-12 20:08:27 +01:00
Ralph Khreish
921e9a6b32 feat: add expand-task remote (#1384) 2025-11-07 18:06:23 +01:00
Ralph Khreish
0c639bd1db fix: return actual subtask instead of parent task for subtask IDs (#1358)
Co-authored-by: Ralph Khreish <Crunchyman-ralph@users.noreply.github.com>
Co-authored-by: claude[bot] <209825114+claude[bot]@users.noreply.github.com>
Fixes #1355
2025-10-30 22:21:04 +01:00
Ralph Khreish
d63a40c6dd fix: improve auth refresh (#1340) 2025-10-28 13:33:17 +01:00
Ralph Khreish
25addf919f feat: connect get-task and get-tasks to remote (#1346) 2025-10-27 15:23:27 +01:00
Ralph Khreish
486ed40215 feat: update task remote (#1345) 2025-10-25 19:25:17 +02:00
Ralph Khreish
03b7ef9a0e chore: refactor tm-core to host more of our "core" commands (#1331) 2025-10-21 21:16:15 +02:00