-
Notifications
You must be signed in to change notification settings - Fork 2.4k
feat(list): Add --ready and --blocking filters to identify parallelizable tasks #1533
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
feat(list): Add --ready and --blocking filters to identify parallelizable tasks #1533
Conversation
🦋 Changeset detectedLatest commit: f837091 The changes in this PR will be included in the next version bump. Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Note Other AI code review bot(s) detectedCodeRabbit has detected other AI code review bot(s) in this pull request and will avoid duplicating their findings in the review comments. This may lead to a less comprehensive review. 📝 WalkthroughWalkthroughAdds Changes
Sequence Diagram(s)sequenceDiagram
autonumber
participant CLI as CLI (list command)
participant TaskStore as Task Store / tm.core
participant TagMgr as Tag Management
participant Renderer as UI Renderer
CLI->>TaskStore: fetch tasks (single tag or all-tags)
Note right of TaskStore `#eef2ff`: returns tasks with id, deps, status
TaskStore-->>CLI: tasks[]
CLI->>CLI: buildBlocksMap(tasks) → inverse-deps (blocks)
CLI->>CLI: enrich tasks with blocks[] (and tagName if all-tags)
CLI->>CLI: apply filters (--ready / --blocking / status)
alt when per-tag ready counts requested
CLI->>TagMgr: request tag stats (showTaskCounts / ready)
TagMgr-->>CLI: tags[] with readyTasks
end
CLI->>Renderer: render list (JSON/text/compact) including blocks & tag column as requested
Renderer-->>CLI: output/display
Estimated code review effort🎯 4 (Complex) | ⏱️ ~45 minutes Possibly related issues
Possibly related PRs
Suggested reviewers
Pre-merge checks and finishing touches✅ Passed checks (3 passed)
✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 2
🧹 Nitpick comments (2)
apps/cli/tests/unit/commands/list.command.spec.ts (1)
8-10: Consider extracting the shared constant to reduce duplication.
TERMINAL_COMPLETE_STATUSESis defined here and repeated in mocks at lines 31 and 41. Consider defining it once and reusing it across all mock definitions.🔎 Suggested refactor:
// Terminal complete statuses const TERMINAL_COMPLETE_STATUSES = ['done', 'cancelled'] as const; +const isTaskCompleteMock = (status: string) => + TERMINAL_COMPLETE_STATUSES.includes(status as any); // Mock dependencies vi.mock('@tm/core', () => ({ createTmCore: vi.fn(), // ... TERMINAL_COMPLETE_STATUSES: ['done', 'cancelled'], - isTaskComplete: (status: string) => - TERMINAL_COMPLETE_STATUSES.includes(status as any) + isTaskComplete: isTaskCompleteMock })); vi.mock('../../../src/utils/task-status.js', () => ({ - TERMINAL_COMPLETE_STATUSES: ['done', 'cancelled'], - isTaskComplete: (status: string) => - ['done', 'cancelled'].includes(status) + TERMINAL_COMPLETE_STATUSES, + isTaskComplete: isTaskCompleteMock }));apps/cli/src/ui/display/tables.ts (1)
96-110: Consider using a more explicit column width mapping.The
colIndexcounter approach works but is order-dependent and could break if columns are reordered. A more explicit approach using named widths might be clearer.🔎 Example approach:
// Instead of index-based approach: const widthConfig = { dependencies: showDependencies ? calculateDepsWidth() : 0, blocks: showBlocks ? calculateBlocksWidth() : 0, complexity: showComplexity ? calculateComplexityWidth() : 0, }; if (showDependencies) { headers.push(chalk.blue.bold('Dependencies')); colWidths.push(widthConfig.dependencies); } // ... etc
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
package-lock.jsonis excluded by!**/package-lock.json
📒 Files selected for processing (4)
.changeset/list-blocks-ready-filter.md(1 hunks)apps/cli/src/commands/list.command.ts(4 hunks)apps/cli/src/ui/display/tables.ts(4 hunks)apps/cli/tests/unit/commands/list.command.spec.ts(3 hunks)
🧰 Additional context used
📓 Path-based instructions (7)
**/*.ts
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
TypeScript test files must achieve minimum code coverage thresholds: 80% lines/functions and 70% branches globally, 90% for utilities, and 85% for middleware; new features must meet or exceed these thresholds
Files:
apps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsapps/cli/src/commands/list.command.ts
**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
**/*.{js,ts}: Import and use specific getters from config-manager.js (e.g., getMainProvider(), getLogLevel(), getMainMaxTokens()) to access configuration values needed for application logic
Use isApiKeySet(providerName, session) from config-manager.js to check if a provider's key is available before potentially attempting an AI call
Do not add direct console.log calls outside the logging utility - use the central log function instead
Ensure silent mode is disabled in a finally block to prevent it from staying enabled
Do not access the global silentMode variable directly - use the exported silent mode control functions instead
Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Use ContextGatherer class from utils/contextGatherer.js for AI-powered commands that need project context, supporting tasks, files, custom text, and project tree context
Use FuzzyTaskSearch class from utils/fuzzyTaskSearch.js for automatic task relevance detection with configurable search parameters
Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Do not replace explicit user task selections with fuzzy results - fuzzy search should supplement, not replace user selections
Use readJSON and writeJSON utilities for all JSON file operations instead of raw fs.readFileSync or fs.writeFileSync
Include error handling for JSON file operations and validate JSON structure after reading
Use path.join() for cross-platform path construction and path.resolve() for absolute paths, validating paths before file operations
Support both .env files and MCP session environment for environment variable resolution with fallbacks for missing values
Prefer updating the core function to accept an outputFormat parameter and check outputFormat === 'json' before displaying UI elements
Files:
apps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsapps/cli/src/commands/list.command.ts
**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Import modules with
.jsextension even in TypeScript source files for ESM compatibility
Files:
apps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsapps/cli/src/commands/list.command.ts
apps/cli/src/**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
CLI (@tm/cli) should be a thin presentation layer that calls tm-core methods and displays results; handle only CLI-specific concerns like argument parsing, output formatting, and user prompts
Files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
**/*.spec.ts
📄 CodeRabbit inference engine (CLAUDE.md)
Place package and app test files in
packages/<package-name>/src/<module>/<file>.spec.tsorapps/<app-name>/src/<module>/<file>.spec.tsalongside source files
Files:
apps/cli/tests/unit/commands/list.command.spec.ts
**/*.{spec,test}.ts
📄 CodeRabbit inference engine (CLAUDE.md)
**/*.{spec,test}.ts: Always use.tsfor TypeScript tests, never.js
NEVER use async/await in test functions unless testing actual asynchronous operations; use synchronous top-level imports instead of dynamicawait import()
Files:
apps/cli/tests/unit/commands/list.command.spec.ts
apps/cli/**/*.{spec,test}.ts
📄 CodeRabbit inference engine (CLAUDE.md)
In unit tests for apps/cli, mock tm-core responses but use real Commander/chalk/inquirer/other npm packages to test display logic
Files:
apps/cli/tests/unit/commands/list.command.spec.ts
🧠 Learnings (52)
📓 Common learnings
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to new_features.mdc for guidelines on integrating new features into the Task Master CLI with tagged system considerations
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/AGENTS.md:0-0
Timestamp: 2025-12-11T14:45:14.973Z
Learning: Use task status values: 'pending', 'in-progress', 'done', 'deferred', 'cancelled', or 'blocked'
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Applied to files:
.changeset/list-blocks-ready-filter.mdapps/cli/tests/unit/commands/list.command.spec.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:00:32.617Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to new_features.mdc for guidelines on integrating new features into the Task Master CLI with tagged system considerations
Applied to files:
.changeset/list-blocks-ready-filter.md
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Applied to files:
.changeset/list-blocks-ready-filter.mdapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Applied to files:
.changeset/list-blocks-ready-filter.mdapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:00:23.032Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/git_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:23.032Z
Learning: Leverage Task Master's tagged task lists system for multi-context development: branch-specific tasks, merge conflict prevention through task isolation, context switching between development contexts, and parallel development by different team members.
Applied to files:
.changeset/list-blocks-ready-filter.md
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Implement reusable task finding utilities that support both task and subtask lookups and add context to subtask results
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Include all required task properties (id, title, description, status, dependencies, priority, details, testStrategy, subtasks) in each task object without adding extra properties outside the standard schema
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use consistent properties for subtasks (id, title, description, status, dependencies, details) without duplicating parent task properties, maintaining simple numeric IDs unique within the parent task
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Use cli-table3 for rendering tables with colored headers (cyan and bold), appropriate column widths for readability, and use helper functions like getStatusWithColor, formatDependenciesWithStatus, and truncate for content cells
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/ui.js : ui.js should handle CLI output formatting including tables, colors, boxes, spinners, and display tasks, reports, progress, suggestions, and migration notices
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Generate appropriate numbers of subtasks based on task complexity analysis, using recommended subtask counts from complexity analysis when available instead of always using default counts
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Calculate and display task completion statistics for the current tag context including total tasks, completed tasks, completion percentage, and subtask completion counts using visual progress indicators
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs, using numeric IDs for direct task references and string IDs with dot notation (e.g., '1.2') for subtask references
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Use visual indicators to show dependency status (✅/⏱️) and format dependency lists consistently when visualizing dependencies
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Format dependency lists consistently for visualization
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently when adding dependencies
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Use visual indicators to show dependency status (✅/⏱️)
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Follow the standard display pattern for UI functions: use documented JSDoc comments describing the function's purpose, parameters, and display a task object with consistent formatting using boxen and chalk
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Support both task and subtask dependencies in cycle detection
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : When testing CLI commands built with Commander.js: test command action handlers directly rather than mocking the entire Commander chain; create simplified test-specific implementations of command handlers; explicitly handle all options including defaults and shorthand flags; include null/undefined checks for optional parameters; use fixtures for consistent sample data.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to apps/cli/**/*.{spec,test}.ts : In unit tests for apps/cli, mock tm-core responses but use real Commander/chalk/inquirer/other npm packages to test display logic
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : For task file operations in tests: use test-specific file paths (e.g., 'test-tasks.json'); mock `readJSON` and `writeJSON` to avoid real file system interactions; verify file operations use correct paths; use different paths for each test; verify modifications on in-memory task objects passed to `writeJSON`.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : When testing UI functions: mock console output and verify correct formatting; test conditional output logic; use `toContain()` or `toMatch()` rather than exact `toBe()` for strings with emojis or formatting; create separate tests for different behavior modes; test structure of formatted output rather than exact string matching.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to packages/tm-core/**/*.{spec,test}.ts : In unit tests for tm/core, mock only external I/O (Supabase, APIs, filesystem) and use real internal services
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:00:32.617Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to tests.mdc for guidelines on implementing and maintaining tests for Task Master CLI
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to **/*.test.ts : Unit tests must follow the describe/it pattern, use beforeEach for mock setup with jest.clearAllMocks(), include specific assertions with expect(), and test both success and error scenarios including edge cases
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to **/tests/integration/**/*.{spec,test}.ts : In integration tests, use real tm-core and mock only external boundaries (APIs, DB, filesystem)
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to tests/teardown.ts : Global teardown file must be created to handle cleanup after all tests complete and prevent worker process leaks
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to tests/setup.ts : Create global test setup file that configures jest.setTimeout(10000), clears all mocks after each test with jest.clearAllMocks(), and initializes global test configuration
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to apps/mcp/**/*.{spec,test}.ts : In unit tests for apps/mcp, mock tm-core responses but use real MCP framework to test response formatting
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Use established mocking patterns from auth.test.ts as templates: mock bcrypt with proper TypeScript typing, mock Prisma client with transaction support, and always clear mocks between tests
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to **/*.integration.test.ts : Integration tests must use supertest for API endpoint testing, verify database state changes after operations, clean test data before each test, and include full request/response validation with expected HTTP status codes
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : Mock file system operations using `mock-fs` library. Mock API calls by providing jest.fn() implementations that return expected structures. Mock environment variables in test setup.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : Make async operations synchronous in tests. Mock async functions to return synchronous values when possible. Don't use real async/await or Promise resolution that might fail unpredictably.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: The tasks.json file should use a tagged task lists structure with multiple named task lists as top-level keys (e.g., {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}}), supporting backward compatibility through silent migration from legacy {"tasks": [...]} format
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Ensure silent mode is disabled in a finally block to prevent it from staying enabled
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to **/*.js : For functions that need to handle both a passed silentMode parameter and check global state, check both the function parameter and global state: const isSilent = options.silentMode || (typeof options.silentMode === 'undefined' && isSilentMode())
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:47.030Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-11-24T17:58:47.030Z
Learning: Applies to scripts/modules/commands.js : Follow the add-subtask command structure with proper options: --parent (required), --task-id, --title, --description, --details, --dependencies, --status, and --generate, with comprehensive parameter validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Follow the provided structure for adding subtasks, including required options and detailed error handling.
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : For AI-powered commands that benefit from project context, use the ContextGatherer utility for multi-source context extraction, support task IDs, file paths, custom context, and project tree, implement fuzzy search for automatic task discovery, and display detailed token breakdown for transparency.
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Provide clear error messages for unknown options, show available options when an unknown option is used, include command-specific help displays for common errors, and do not allow unknown options with .allowUnknownOption().
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Select tasks based on dependencies (all marked 'done'), priority level, and ID order
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Display progress indicators using both numeric and visual representations, such as showing completed tasks count, total tasks, completion percentage, and progress bars together
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Don't include task manipulations within UI functions; avoid creating circular dependencies with other modules
Applied to files:
apps/cli/src/commands/list.command.ts
🧬 Code graph analysis (2)
apps/cli/src/ui/display/tables.ts (1)
packages/tm-core/src/common/types/index.ts (1)
Subtask(165-169)
apps/cli/src/commands/list.command.ts (3)
packages/tm-core/src/common/types/index.ts (1)
Task(131-159)packages/tm-core/src/common/constants/index.ts (1)
isTaskComplete(68-70)apps/cli/src/utils/task-status.ts (1)
isTaskComplete(9-9)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: Cursor Bugbot
🔇 Additional comments (15)
.changeset/list-blocks-ready-filter.md (1)
1-11: LGTM!The changeset accurately documents the new features:
--readyand--blockingfilters, their combined usage, the new "Blocks" column, and JSON output support. Minor version bump is appropriate for these additive features.apps/cli/tests/unit/commands/list.command.spec.ts (4)
208-287: Good test coverage for the--readyfilter.Tests correctly verify that:
- Tasks with satisfied dependencies are included
- Tasks with unsatisfied dependencies are excluded
- Completed tasks (done/cancelled) are excluded from results
Consider adding a test case for tasks with
deferredorreviewstatus to confirm they're included when dependencies are satisfied.
289-329: LGTM!The
--blockingfilter test correctly validates that only tasks appearing in other tasks' dependency lists are included in the output.
331-372: LGTM!Excellent test for the combined
--ready --blockingfilter. The test scenario clearly demonstrates the AND semantics: only task 2 is both ready (dependency on done task 1 is satisfied) and blocking (tasks 3 and 4 depend on it).
374-423: LGTM!Comprehensive test for the
blocksfield output. Correctly validates the inverse dependency mapping including the case where task 4 is blocked by both tasks 2 and 3.apps/cli/src/commands/list.command.ts (5)
47-48: LGTM!The new
readyandblockingoptions are correctly typed as optional booleans in theListCommandOptionsinterface.
97-104: LGTM!The CLI options are well-documented with clear descriptions of their functionality.
250-271: LGTM!The
buildBlocksMapcorrectly inverts the dependency graph. The implementation handles:
- Consistent string conversion for task IDs
- Empty dependency arrays
- Dependencies referencing tasks not in the current list (external dependencies)
305-307: LGTM!Simple and correct implementation of the blocking filter.
423-430: LGTM!The
showBlocks: trueoption enables the new Blocks column in the task table display. This aligns with the PR objective to show blocking information for parallel team assignment.apps/cli/src/ui/display/tables.ts (5)
19-22: LGTM!The
TaskWithBlockstype correctly extends bothTaskandSubtaskwith an optionalblocksfield, allowing the table to handle both task types uniformly.
45-87: LGTM!The dynamic column width calculation correctly handles all combinations of optional columns (Dependencies, Blocks, Complexity). The percentages sum to approximately 100% with acceptable rounding due to
Math.floor.
139-149: LGTM!The blocks rendering uses yellow highlighting to draw attention to tasks that block others, which is appropriate for the parallel team assignment use case. The fallback to a gray dash maintains visual consistency with the dependencies column.
182-185: LGTM!Subtasks correctly display a dash for blocks since the blocking relationship is computed only for top-level tasks. The comment documents this intentional behavior.
128-137: LGTM!Changed empty dependencies display from 'None' to '-' for visual consistency with the new Blocks column.
| private filterReadyTasks(tasks: (Task & { blocks: string[] })[]): (Task & { blocks: string[] })[] { | ||
| // Build set of completed task IDs | ||
| const completedIds = new Set<string>(); | ||
| tasks.forEach((t) => { | ||
| if (isTaskComplete(t.status)) { | ||
| completedIds.add(String(t.id)); | ||
| } | ||
| }); | ||
|
|
||
| return tasks.filter((task) => { | ||
| // Must be pending or in-progress (not completed) | ||
| if (isTaskComplete(task.status)) { | ||
| return false; | ||
| } | ||
|
|
||
| // Must have all dependencies satisfied | ||
| if (!task.dependencies || task.dependencies.length === 0) { | ||
| return true; | ||
| } | ||
|
|
||
| return task.dependencies.every((depId) => | ||
| completedIds.has(String(depId)) | ||
| ); | ||
| }); | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧩 Analysis chain
🏁 Script executed:
# Find the list command file and examine the filterReadyTasks method
find apps/cli -name "list.command.ts" -type fRepository: eyaltoledano/claude-task-master
Length of output: 112
🏁 Script executed:
# Search for the Task type definition and the blocks property
rg -n "blocks.*string" apps/cli/ --type ts
# Look for where filterReadyTasks is called
rg -n "filterReadyTasks" apps/cli/ --type ts
# Check for how tasks with subtask dependencies are handled
rg -n "dependencies.*\." apps/ --type ts --max-count=5Repository: eyaltoledano/claude-task-master
Length of output: 6552
🏁 Script executed:
#!/bin/bash
# Examine the Task type and filterReadyTasks implementation
echo "=== Finding list.command.ts ==="
find apps -name "list.command.ts" -type f
echo ""
echo "=== Searching for Task type definition ==="
rg -n "interface Task|type Task" apps/ --type ts -A 10 | head -40
echo ""
echo "=== Looking at filterReadyTasks calls ==="
rg -n "filterReadyTasks" apps/ --type ts -B 2 -A 2
echo ""
echo "=== Checking blocks property usage ==="
rg -n "blocks" apps/cli/src/commands/list.command.ts --type ts -B 2 -A 2
echo ""
echo "=== Looking for subtask dependency patterns ==="
rg -n "\d+\.\d+" apps/cli/src/commands/list.command.ts --type ts | head -20Repository: eyaltoledano/claude-task-master
Length of output: 5889
🏁 Script executed:
cat apps/cli/src/commands/list.command.ts | grep -A 30 "filterReadyTasks"Repository: eyaltoledano/claude-task-master
Length of output: 1841
🏁 Script executed:
git ls-files apps/cli/src/commands/ | head -20Repository: eyaltoledano/claude-task-master
Length of output: 965
🏁 Script executed:
# Find where blocks are assigned to understand the data flow
rg -n "blocks\s*[:=]" apps/ --type ts -B 2 -A 2 | head -60Repository: eyaltoledano/claude-task-master
Length of output: 1325
🏁 Script executed:
# Check if dependencies ever include dot notation in the actual data flow
rg -n "dependencies" apps/cli/src/commands/list.command.ts --type ts -B 3 -A 3Repository: eyaltoledano/claude-task-master
Length of output: 3514
Handle subtask ID dependencies in the ready filter.
The filterReadyTasks function incorrectly filters out tasks with subtask dependencies. When a task depends on '1.1' (a subtask), the completedIds set built from top-level tasks only won't contain that subtask ID, causing the filter to always return false. Update the function to flatten subtask completion status from parent tasks or resolve subtask references when building the completed IDs set.
🤖 Prompt for AI Agents
In apps/cli/src/commands/list.command.ts around lines 276-300, the completedIds
set only includes top-level task IDs so dependencies that reference subtasks
like "1.1" are never marked completed; update the completedIds construction to
also include subtask IDs (flatten child/subtask IDs) when a completed parent
task has blocks or nested IDs, and adjust the dependency check to compare
dependency strings verbatim against that flattened set (i.e., add each task.id
and any task.blocks[] entries to completedIds so dependencies such as "1.1" will
be found).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR is being reviewed by Cursor Bugbot
Details
Your team is on the Bugbot Free tier. On this plan, Bugbot will review limited PRs each billing cycle for each member of your team.
To receive Bugbot reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial.
39dacd3 to
d41fa0e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (2)
apps/cli/src/ui/display/tables.ts (2)
19-28: Consider consolidating theTaskWithBlockstype definition.The type
TaskWithBlocksis defined here as(Task | Subtask) & { blocks?: string[] }with optionalblocks, butapps/cli/src/commands/list.command.tsline 53 defines it asTask & { blocks: string[] }with requiredblocksand noSubtasksupport. Having two different types with the same name in different files can lead to confusion and type safety issues.Consider moving this to a shared types file (e.g.,
packages/tm-core/src/common/types/index.ts) and using a single definition across both files.
182-185: Clarify subtask blocks handling.The type
TaskWithBlocksallows subtasks to have ablocksfield, but the rendering code always displays '-' for subtasks with the comment "don't typically have blocks." If subtasks truly never have blocks, consider either:
- Checking if
subtask.blocksexists and rendering it (to match the type), or- Refining the type to exclude blocks for subtasks (e.g., using a discriminated union).
The current implementation creates a mismatch between what the type allows and what the code actually handles.
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
apps/cli/src/commands/list.command.ts(5 hunks)apps/cli/src/ui/display/tables.ts(4 hunks)apps/cli/tests/unit/commands/list.command.spec.ts(3 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
- apps/cli/src/commands/list.command.ts
🧰 Additional context used
📓 Path-based instructions (7)
**/*.ts
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
TypeScript test files must achieve minimum code coverage thresholds: 80% lines/functions and 70% branches globally, 90% for utilities, and 85% for middleware; new features must meet or exceed these thresholds
Files:
apps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
**/*.{js,ts}: Import and use specific getters from config-manager.js (e.g., getMainProvider(), getLogLevel(), getMainMaxTokens()) to access configuration values needed for application logic
Use isApiKeySet(providerName, session) from config-manager.js to check if a provider's key is available before potentially attempting an AI call
Do not add direct console.log calls outside the logging utility - use the central log function instead
Ensure silent mode is disabled in a finally block to prevent it from staying enabled
Do not access the global silentMode variable directly - use the exported silent mode control functions instead
Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Use ContextGatherer class from utils/contextGatherer.js for AI-powered commands that need project context, supporting tasks, files, custom text, and project tree context
Use FuzzyTaskSearch class from utils/fuzzyTaskSearch.js for automatic task relevance detection with configurable search parameters
Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Do not replace explicit user task selections with fuzzy results - fuzzy search should supplement, not replace user selections
Use readJSON and writeJSON utilities for all JSON file operations instead of raw fs.readFileSync or fs.writeFileSync
Include error handling for JSON file operations and validate JSON structure after reading
Use path.join() for cross-platform path construction and path.resolve() for absolute paths, validating paths before file operations
Support both .env files and MCP session environment for environment variable resolution with fallbacks for missing values
Prefer updating the core function to accept an outputFormat parameter and check outputFormat === 'json' before displaying UI elements
Files:
apps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Import modules with
.jsextension even in TypeScript source files for ESM compatibility
Files:
apps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
apps/cli/src/**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
CLI (@tm/cli) should be a thin presentation layer that calls tm-core methods and displays results; handle only CLI-specific concerns like argument parsing, output formatting, and user prompts
Files:
apps/cli/src/ui/display/tables.ts
**/*.spec.ts
📄 CodeRabbit inference engine (CLAUDE.md)
Place package and app test files in
packages/<package-name>/src/<module>/<file>.spec.tsorapps/<app-name>/src/<module>/<file>.spec.tsalongside source files
Files:
apps/cli/tests/unit/commands/list.command.spec.ts
**/*.{spec,test}.ts
📄 CodeRabbit inference engine (CLAUDE.md)
**/*.{spec,test}.ts: Always use.tsfor TypeScript tests, never.js
NEVER use async/await in test functions unless testing actual asynchronous operations; use synchronous top-level imports instead of dynamicawait import()
Files:
apps/cli/tests/unit/commands/list.command.spec.ts
apps/cli/**/*.{spec,test}.ts
📄 CodeRabbit inference engine (CLAUDE.md)
In unit tests for apps/cli, mock tm-core responses but use real Commander/chalk/inquirer/other npm packages to test display logic
Files:
apps/cli/tests/unit/commands/list.command.spec.ts
🧠 Learnings (39)
📓 Common learnings
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/git_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:23.032Z
Learning: Pull Request descriptions must include: Task Overview, Subtasks Completed (checklist), Implementation Details, Testing approach, Breaking Changes (if any), and Related Tasks.
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Use cli-table3 for rendering tables with colored headers (cyan and bold), appropriate column widths for readability, and use helper functions like getStatusWithColor, formatDependenciesWithStatus, and truncate for content cells
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Implement reusable task finding utilities that support both task and subtask lookups and add context to subtask results
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/ui.js : ui.js should handle CLI output formatting including tables, colors, boxes, spinners, and display tasks, reports, progress, suggestions, and migration notices
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use consistent properties for subtasks (id, title, description, status, dependencies, details) without duplicating parent task properties, maintaining simple numeric IDs unique within the parent task
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Include all required task properties (id, title, description, status, dependencies, priority, details, testStrategy, subtasks) in each task object without adding extra properties outside the standard schema
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Generate appropriate numbers of subtasks based on task complexity analysis, using recommended subtask counts from complexity analysis when available instead of always using default counts
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Calculate and display task completion statistics for the current tag context including total tasks, completed tasks, completion percentage, and subtask completion counts using visual progress indicators
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs, using numeric IDs for direct task references and string IDs with dot notation (e.g., '1.2') for subtask references
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Use visual indicators to show dependency status (✅/⏱️) and format dependency lists consistently when visualizing dependencies
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Format dependency lists consistently for visualization
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently when adding dependencies
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Use visual indicators to show dependency status (✅/⏱️)
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Follow the standard display pattern for UI functions: use documented JSDoc comments describing the function's purpose, parameters, and display a task object with consistent formatting using boxen and chalk
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Support both task and subtask dependencies in cycle detection
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : When testing CLI commands built with Commander.js: test command action handlers directly rather than mocking the entire Commander chain; create simplified test-specific implementations of command handlers; explicitly handle all options including defaults and shorthand flags; include null/undefined checks for optional parameters; use fixtures for consistent sample data.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to apps/cli/**/*.{spec,test}.ts : In unit tests for apps/cli, mock tm-core responses but use real Commander/chalk/inquirer/other npm packages to test display logic
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : For task file operations in tests: use test-specific file paths (e.g., 'test-tasks.json'); mock `readJSON` and `writeJSON` to avoid real file system interactions; verify file operations use correct paths; use different paths for each test; verify modifications on in-memory task objects passed to `writeJSON`.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to packages/tm-core/**/*.{spec,test}.ts : In unit tests for tm/core, mock only external I/O (Supabase, APIs, filesystem) and use real internal services
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : When testing UI functions: mock console output and verify correct formatting; test conditional output logic; use `toContain()` or `toMatch()` rather than exact `toBe()` for strings with emojis or formatting; create separate tests for different behavior modes; test structure of formatted output rather than exact string matching.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to **/tests/integration/**/*.{spec,test}.ts : In integration tests, use real tm-core and mock only external boundaries (APIs, DB, filesystem)
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to **/*.test.ts : Unit tests must follow the describe/it pattern, use beforeEach for mock setup with jest.clearAllMocks(), include specific assertions with expect(), and test both success and error scenarios including edge cases
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to tests/teardown.ts : Global teardown file must be created to handle cleanup after all tests complete and prevent worker process leaks
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to tests/setup.ts : Create global test setup file that configures jest.setTimeout(10000), clears all mocks after each test with jest.clearAllMocks(), and initializes global test configuration
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to apps/mcp/**/*.{spec,test}.ts : In unit tests for apps/mcp, mock tm-core responses but use real MCP framework to test response formatting
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Use established mocking patterns from auth.test.ts as templates: mock bcrypt with proper TypeScript typing, mock Prisma client with transaction support, and always clear mocks between tests
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to **/*.integration.test.ts : Integration tests must use supertest for API endpoint testing, verify database state changes after operations, clean test data before each test, and include full request/response validation with expected HTTP status codes
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : Mock file system operations using `mock-fs` library. Mock API calls by providing jest.fn() implementations that return expected structures. Mock environment variables in test setup.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : Make async operations synchronous in tests. Mock async functions to return synchronous values when possible. Don't use real async/await or Promise resolution that might fail unpredictably.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
🧬 Code graph analysis (2)
apps/cli/src/ui/display/tables.ts (2)
apps/cli/src/commands/list.command.ts (1)
TaskWithBlocks(54-54)packages/tm-core/src/common/types/index.ts (1)
Subtask(165-169)
apps/cli/tests/unit/commands/list.command.spec.ts (1)
apps/cli/src/commands/list.command.ts (1)
ListTasksCommand(71-621)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: Cursor Bugbot
🔇 Additional comments (7)
apps/cli/src/ui/display/tables.ts (2)
46-89: LGTM: Dynamic column width calculation.The logic correctly calculates column widths based on the number of optional columns (0-3), and the percentage allocations ensure all columns fit within the terminal width while maintaining readability.
141-149: LGTM: Blocks column rendering for tasks.The implementation correctly displays the
blocksfield with appropriate color coding (yellow for blocks vs. cyan for dependencies) and consistent empty-value handling with '-'.apps/cli/tests/unit/commands/list.command.spec.ts (5)
8-43: LGTM: Consistent terminal status mocking.The mock setup correctly defines
TERMINAL_COMPLETE_STATUSESandisTaskCompleteconsistently across both the@tm/coreandtask-statusutility mocks, ensuring tests accurately reflect the new filtering behavior.
207-286: LGTM: Comprehensive --ready filter testing.The tests correctly verify that:
- Only tasks with satisfied dependencies are included
- Complete tasks (done/cancelled) are excluded from ready results
The test data and assertions accurately validate the filtering logic.
288-328: LGTM: --blocking filter validation.The test correctly verifies that the
--blockingfilter identifies tasks that are dependencies of other tasks, using an appropriate dependency chain to validate the filtering logic.
330-371: LGTM: Combined filter validation with AND semantics.The test correctly verifies that combining
--readyand--blockingreturns only tasks that satisfy both conditions (high-impact tasks), using a well-designed dependency chain to validate the intersection logic.
373-427: LGTM: Blocks field calculation validation.The test thoroughly verifies that the
blocksfield correctly represents inverse dependencies, checking both tasks that block others and tasks that block nothing. The assertions appropriately usearrayContainingfor unordered comparisons and exact equality for ordered results.
|
@bjcoombs Not sure this is something we'd need into considering we're solving for team play with Hamster. It might make sense to add it to metadata since it would react to what's on Hamster As an example, task lists living on Hamster can be pulled into Hamster, stay up to date in real-time, and are built for collaboration. In this case, we'd want to ensure tasks assigned to specific team members within Hamster are reflected in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (2)
apps/cli/src/ui/display/tables.ts (2)
47-90: Consider a more scalable approach to column width calculation.The current implementation uses four hardcoded branches based on the count of optional columns. While correct, this approach becomes harder to maintain as new optional columns are added. Consider a more algorithmic approach that calculates widths based on the number of visible columns dynamically.
💡 Example refactoring approach
// Define base and optional column weight allocations const baseColumns = [ { name: 'ID', weight: 0.1 }, { name: 'Title', weight: 0.5 }, { name: 'Status', weight: 0.2 }, { name: 'Priority', weight: 0.2 } ]; const optionalColumns = [ { name: 'Dependencies', weight: 0.15, show: showDependencies }, { name: 'Blocks', weight: 0.15, show: showBlocks }, { name: 'Complexity', weight: 0.1, show: showComplexity } ]; // Calculate widths dynamically const activeColumns = [...baseColumns]; optionalColumns.forEach(col => { if (col.show) activeColumns.push(col); }); // Normalize weights and calculate widths const totalWeight = activeColumns.reduce((sum, col) => sum + col.weight, 0); const colWidths = activeColumns.map(col => Math.floor(tableWidth * (col.weight / totalWeight)) );
189-192: Clarify subtask blocking behavior.The implementation always displays
-for subtask blocks, even though theTaskWithBlockstype includesSubtaskand allows theblocksfield. If subtasks can never block other tasks in your domain model, consider:
- Documenting this constraint more explicitly in comments or type constraints
- Filtering out subtasks from the blocking relationship computation at a higher level
If subtasks can sometimes block other tasks, the current implementation would silently hide that information.
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
apps/cli/src/ui/display/tables.ts(4 hunks)
🧰 Additional context used
📓 Path-based instructions (4)
**/*.ts
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
TypeScript test files must achieve minimum code coverage thresholds: 80% lines/functions and 70% branches globally, 90% for utilities, and 85% for middleware; new features must meet or exceed these thresholds
Files:
apps/cli/src/ui/display/tables.ts
**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
**/*.{js,ts}: Import and use specific getters from config-manager.js (e.g., getMainProvider(), getLogLevel(), getMainMaxTokens()) to access configuration values needed for application logic
Use isApiKeySet(providerName, session) from config-manager.js to check if a provider's key is available before potentially attempting an AI call
Do not add direct console.log calls outside the logging utility - use the central log function instead
Ensure silent mode is disabled in a finally block to prevent it from staying enabled
Do not access the global silentMode variable directly - use the exported silent mode control functions instead
Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Use ContextGatherer class from utils/contextGatherer.js for AI-powered commands that need project context, supporting tasks, files, custom text, and project tree context
Use FuzzyTaskSearch class from utils/fuzzyTaskSearch.js for automatic task relevance detection with configurable search parameters
Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Do not replace explicit user task selections with fuzzy results - fuzzy search should supplement, not replace user selections
Use readJSON and writeJSON utilities for all JSON file operations instead of raw fs.readFileSync or fs.writeFileSync
Include error handling for JSON file operations and validate JSON structure after reading
Use path.join() for cross-platform path construction and path.resolve() for absolute paths, validating paths before file operations
Support both .env files and MCP session environment for environment variable resolution with fallbacks for missing values
Prefer updating the core function to accept an outputFormat parameter and check outputFormat === 'json' before displaying UI elements
Files:
apps/cli/src/ui/display/tables.ts
**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Import modules with
.jsextension even in TypeScript source files for ESM compatibility
Files:
apps/cli/src/ui/display/tables.ts
apps/cli/src/**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
CLI (@tm/cli) should be a thin presentation layer that calls tm-core methods and displays results; handle only CLI-specific concerns like argument parsing, output formatting, and user prompts
Files:
apps/cli/src/ui/display/tables.ts
🧠 Learnings (22)
📓 Common learnings
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/git_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:23.032Z
Learning: Leverage Task Master's tagged task lists system for multi-context development: branch-specific tasks, merge conflict prevention through task isolation, context switching between development contexts, and parallel development by different team members.
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : When testing CLI commands built with Commander.js: test command action handlers directly rather than mocking the entire Commander chain; create simplified test-specific implementations of command handlers; explicitly handle all options including defaults and shorthand flags; include null/undefined checks for optional parameters; use fixtures for consistent sample data.
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Use cli-table3 for rendering tables with colored headers (cyan and bold), appropriate column widths for readability, and use helper functions like getStatusWithColor, formatDependenciesWithStatus, and truncate for content cells
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/ui.js : ui.js should handle CLI output formatting including tables, colors, boxes, spinners, and display tasks, reports, progress, suggestions, and migration notices
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Implement reusable task finding utilities that support both task and subtask lookups and add context to subtask results
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Include all required task properties (id, title, description, status, dependencies, priority, details, testStrategy, subtasks) in each task object without adding extra properties outside the standard schema
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use consistent properties for subtasks (id, title, description, status, dependencies, details) without duplicating parent task properties, maintaining simple numeric IDs unique within the parent task
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Calculate and display task completion statistics for the current tag context including total tasks, completed tasks, completion percentage, and subtask completion counts using visual progress indicators
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Generate appropriate numbers of subtasks based on task complexity analysis, using recommended subtask counts from complexity analysis when available instead of always using default counts
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Follow the standard display pattern for UI functions: use documented JSDoc comments describing the function's purpose, parameters, and display a task object with consistent formatting using boxen and chalk
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Use visual indicators to show dependency status (✅/⏱️) and format dependency lists consistently when visualizing dependencies
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Format dependency lists consistently for visualization
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs, using numeric IDs for direct task references and string IDs with dot notation (e.g., '1.2') for subtask references
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently when adding dependencies
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Use visual indicators to show dependency status (✅/⏱️)
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Support both task and subtask dependencies in cycle detection
Applied to files:
apps/cli/src/ui/display/tables.ts
🧬 Code graph analysis (1)
apps/cli/src/ui/display/tables.ts (2)
apps/cli/src/commands/list.command.ts (1)
TaskWithBlocks(54-54)packages/tm-core/src/common/types/index.ts (1)
Subtask(165-169)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
- GitHub Check: Test
- GitHub Check: Cursor Bugbot
🔇 Additional comments (2)
apps/cli/src/ui/display/tables.ts (2)
142-156: LGTM! Blocks rendering logic is well-designed.The color scheme effectively communicates blocking status:
- Yellow for incomplete tasks that are actively blocking other tasks
- Gray for completed tasks (no longer blocking)
- Gray dash for tasks with no dependents
This provides clear visual feedback to help teams identify critical path tasks and assignment priorities.
131-140: LGTM! Consistent empty value handling.The change from 'None' to '-' for empty dependencies improves consistency across the table columns (Dependencies, Blocks) and follows standard table conventions for "not applicable" values.
apps/cli/src/ui/display/tables.ts
Outdated
| /** | ||
| * Task with blocks field (inverse of dependencies) | ||
| */ | ||
| export type TaskWithBlocks = (Task | Subtask) & { blocks?: string[] }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consolidate duplicate type definitions.
The TaskWithBlocks type is defined in both this file and apps/cli/src/commands/list.command.ts:53, but with different signatures:
- This file:
(Task | Subtask) & { blocks?: string[] }(optional blocks, supports subtasks) - list.command.ts:
Task & { blocks: string[] }(required blocks, Task only)
This duplication creates a maintenance burden and potential type inconsistencies. Consider moving the type definition to a shared location (e.g., a types file) and ensuring both files import from the same source. Based on usage in this file, the more flexible definition (Task | Subtask) & { blocks?: string[] } appears correct since the rendering logic handles both tasks and subtasks.
🔎 Suggested approach
- Move the type definition to a shared types file (e.g.,
apps/cli/src/types/task-types.ts) - Use the more flexible definition:
export type TaskWithBlocks = (Task | Subtask) & { blocks?: string[] }; - Update both files to import from the shared location
- Verify that list.command.ts properly initializes the
blocksarray before passing tasks to this function
🤖 Prompt for AI Agents
In apps/cli/src/ui/display/tables.ts around lines 20 to 23 the TaskWithBlocks
type is duplicated with a conflicting variant in
apps/cli/src/commands/list.command.ts; extract the authoritative type into a
shared file (e.g., apps/cli/src/types/task-types.ts) as export type
TaskWithBlocks = (Task | Subtask) & { blocks?: string[] }; then update both
files to import TaskWithBlocks from that shared path and remove the local
definitions; finally, ensure list.command.ts either initializes a blocks array
before passing tasks or narrows/guards where it expects a required blocks field
so usages conform to the new optional-blocks type.
| tag: options.tag, | ||
| filter, | ||
| includeSubtasks: options.withSubtasks | ||
| }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Bug: Tag filter applied when ready/blocking needs all tasks
The comment at lines 213-214 explicitly states "we need ALL tasks to correctly compute which dependencies are satisfied," and the code correctly skips the status filter when --ready or --blocking is used. However, the tag filter (options.tag) is still passed to tmCore.tasks.list() at line 225. This means if a task depends on a task with a different tag, that dependency won't be in completedIds, causing the task to incorrectly appear as "not ready" even when its cross-tag dependency is complete.
|
@eyaltoledano Thanks for the feedback! I've updated the PR title and description to clarify the use case. This isn't really about team collaboration - it's for single-developer parallel execution. My workflow is running 3-4 Claude Code sessions simultaneously in separate git worktrees. Right now I use The filters help answer: "I have 4 Claude sessions ready to go - which 4 independent tasks can I assign right now?" That said, I can see how this could also complement Hamster for team scenarios - the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
♻️ Duplicate comments (2)
apps/cli/src/commands/list.command.ts (2)
213-228: Tag filter may still cause incomplete dependency resolution for cross-tag dependencies.The code correctly defers status filtering when
--readyor--blockingis used (lines 218-221). However, thetagfilter is still passed totmCore.tasks.list()at line 225. If a task depends on a task with a different tag, that dependency won't appear incompletedIds, causing the task to incorrectly appear as "not ready."Consider whether cross-tag dependencies are a supported use case. If so, you may need to fetch all tasks when
needsAllTasksis true and apply tag filtering after ready/blocking computation.
299-305: Subtask dependencies are not included incompletedIds.The
completedIdsset only includes top-level task IDs, but dependencies can reference subtasks (e.g.,"1.1"). Compare withfindNextTask(lines 500-506) which correctly adds subtask IDs using${t.id}.${st.id}. Tasks depending on completed subtasks will incorrectly be marked as not ready.🔎 Suggested fix:
const completedIds = new Set<string>(); tasks.forEach((t) => { if (isTaskComplete(t.status)) { completedIds.add(String(t.id)); } + // Also add completed subtask IDs + if (t.subtasks) { + t.subtasks.forEach((st) => { + if (isTaskComplete(st.status)) { + completedIds.add(`${t.id}.${st.id}`); + } + }); + } });
🧹 Nitpick comments (4)
apps/cli/src/ui/display/tables.ts (2)
47-91: Consider simplifying column width calculation.The branching logic is correct but complex. A more maintainable approach could calculate widths dynamically based on column configuration rather than hardcoding arrays for each combination.
🔎 Alternative approach:
// Define base widths for required columns const baseWidths = { id: 0.08, title: 0.35, status: 0.14, priority: 0.11 }; // Remaining width distributed among optional columns const optionalWidth = 1 - Object.values(baseWidths).reduce((a, b) => a + b, 0); const perOptionalCol = optionalCols > 0 ? optionalWidth / optionalCols : 0;
143-157: Minor: Redundant type cast.At line 145,
taskis already of typeTaskTableItem(from the function signature at line 30), so the cast is unnecessary.🔎 Simplified code:
if (showBlocks) { // Show tasks that depend on this one - const taskWithBlocks = task as TaskTableItem; - if (!taskWithBlocks.blocks || taskWithBlocks.blocks.length === 0) { + if (!task.blocks || task.blocks.length === 0) { row.push(chalk.gray('-')); } else { // Gray out blocks for completed tasks (no longer blocking) - const blocksText = taskWithBlocks.blocks.join(', '); + const blocksText = task.blocks.join(', '); row.push( isTaskComplete(task.status) ? chalk.gray(blocksText) : chalk.yellow(blocksText) ); } }apps/cli/tests/unit/commands/list.command.spec.ts (2)
8-10: Potential mock redundancy in@tm/core.The
TERMINAL_COMPLETE_STATUSESandisTaskCompleteare exported from the@tm/coremock (lines 33-35), but the actual code importsisTaskCompletefrom../utils/task-status.js. The correct mock is at lines 42-45. The exports in the@tm/coremock are unused and could be removed for clarity.Also applies to: 33-35
209-473: Consider adding test for subtask dependency resolution.Given the known issue with subtask dependencies not being handled in
filterReadyTasks, consider adding a test case that exposes this behavior. This would help prevent regressions when the fix is implemented.🔎 Example test case:
it('should handle subtask dependencies in ready filter', async () => { const command = new ListTasksCommand(); const mockTasks = [ { id: '1', title: 'Task 1', status: 'in-progress', dependencies: [], subtasks: [{ id: '1', title: 'Subtask 1.1', status: 'done' }] }, { id: '2', title: 'Task 2', status: 'pending', dependencies: ['1.1'] // Depends on completed subtask } ]; (command as any).tmCore = { tasks: { list: vi.fn().mockResolvedValue({ tasks: mockTasks, total: 2, filtered: 2, storageType: 'json' }), getStorageType: vi.fn().mockReturnValue('json') }, config: { getActiveTag: vi.fn().mockReturnValue('master') } }; await (command as any).executeCommand({ ready: true, json: true }); const output = consoleLogSpy.mock.calls[0][0]; const parsed = JSON.parse(output); // Task 2 should be ready (subtask 1.1 is done) expect(parsed.tasks.map((t: any) => t.id)).toContain('2'); });
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
apps/cli/src/commands/list.command.ts(5 hunks)apps/cli/src/ui/display/tables.ts(4 hunks)apps/cli/tests/unit/commands/list.command.spec.ts(3 hunks)
🧰 Additional context used
📓 Path-based instructions (7)
**/*.ts
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
TypeScript test files must achieve minimum code coverage thresholds: 80% lines/functions and 70% branches globally, 90% for utilities, and 85% for middleware; new features must meet or exceed these thresholds
Files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
**/*.{js,ts}: Import and use specific getters from config-manager.js (e.g., getMainProvider(), getLogLevel(), getMainMaxTokens()) to access configuration values needed for application logic
Use isApiKeySet(providerName, session) from config-manager.js to check if a provider's key is available before potentially attempting an AI call
Do not add direct console.log calls outside the logging utility - use the central log function instead
Ensure silent mode is disabled in a finally block to prevent it from staying enabled
Do not access the global silentMode variable directly - use the exported silent mode control functions instead
Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Use ContextGatherer class from utils/contextGatherer.js for AI-powered commands that need project context, supporting tasks, files, custom text, and project tree context
Use FuzzyTaskSearch class from utils/fuzzyTaskSearch.js for automatic task relevance detection with configurable search parameters
Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Do not replace explicit user task selections with fuzzy results - fuzzy search should supplement, not replace user selections
Use readJSON and writeJSON utilities for all JSON file operations instead of raw fs.readFileSync or fs.writeFileSync
Include error handling for JSON file operations and validate JSON structure after reading
Use path.join() for cross-platform path construction and path.resolve() for absolute paths, validating paths before file operations
Support both .env files and MCP session environment for environment variable resolution with fallbacks for missing values
Prefer updating the core function to accept an outputFormat parameter and check outputFormat === 'json' before displaying UI elements
Files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Import modules with
.jsextension even in TypeScript source files for ESM compatibility
Files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
apps/cli/src/**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
CLI (@tm/cli) should be a thin presentation layer that calls tm-core methods and displays results; handle only CLI-specific concerns like argument parsing, output formatting, and user prompts
Files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
**/*.spec.ts
📄 CodeRabbit inference engine (CLAUDE.md)
Place package and app test files in
packages/<package-name>/src/<module>/<file>.spec.tsorapps/<app-name>/src/<module>/<file>.spec.tsalongside source files
Files:
apps/cli/tests/unit/commands/list.command.spec.ts
**/*.{spec,test}.ts
📄 CodeRabbit inference engine (CLAUDE.md)
**/*.{spec,test}.ts: Always use.tsfor TypeScript tests, never.js
NEVER use async/await in test functions unless testing actual asynchronous operations; use synchronous top-level imports instead of dynamicawait import()
Files:
apps/cli/tests/unit/commands/list.command.spec.ts
apps/cli/**/*.{spec,test}.ts
📄 CodeRabbit inference engine (CLAUDE.md)
In unit tests for apps/cli, mock tm-core responses but use real Commander/chalk/inquirer/other npm packages to test display logic
Files:
apps/cli/tests/unit/commands/list.command.spec.ts
🧠 Learnings (62)
📓 Common learnings
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/git_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:23.032Z
Learning: Leverage Task Master's tagged task lists system for multi-context development: branch-specific tasks, merge conflict prevention through task isolation, context switching between development contexts, and parallel development by different team members.
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : When testing CLI commands built with Commander.js: test command action handlers directly rather than mocking the entire Commander chain; create simplified test-specific implementations of command handlers; explicitly handle all options including defaults and shorthand flags; include null/undefined checks for optional parameters; use fixtures for consistent sample data.
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Use cli-table3 for rendering tables with colored headers (cyan and bold), appropriate column widths for readability, and use helper functions like getStatusWithColor, formatDependenciesWithStatus, and truncate for content cells
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Implement reusable task finding utilities that support both task and subtask lookups and add context to subtask results
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/ui.js : ui.js should handle CLI output formatting including tables, colors, boxes, spinners, and display tasks, reports, progress, suggestions, and migration notices
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use consistent properties for subtasks (id, title, description, status, dependencies, details) without duplicating parent task properties, maintaining simple numeric IDs unique within the parent task
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Include all required task properties (id, title, description, status, dependencies, priority, details, testStrategy, subtasks) in each task object without adding extra properties outside the standard schema
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: The tasks.json file should use a tagged task lists structure with multiple named task lists as top-level keys (e.g., {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}}), supporting backward compatibility through silent migration from legacy {"tasks": [...]} format
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-09-03T12:16:15.866Z
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 1178
File: packages/tm-core/package.json:13-64
Timestamp: 2025-09-03T12:16:15.866Z
Learning: For internal packages in the claude-task-master project, Crunchyman-ralph prefers pointing package.json "types" entries to src .ts files rather than dist .d.ts files for better developer experience (DX), as the packages are not being exported as SDKs.
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-09-26T19:05:47.555Z
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 1252
File: packages/ai-sdk-provider-grok-cli/package.json:11-13
Timestamp: 2025-09-26T19:05:47.555Z
Learning: In the eyaltoledano/claude-task-master repository, internal tm/ packages use a specific export pattern where the "exports" field points to TypeScript source files (./src/index.ts) while "main" points to compiled output (./dist/index.js) and "types" points to source files (./src/index.ts). This pattern is used consistently across internal packages like tm/core and tm/ai-sdk-provider-grok-cli because they are consumed directly during build-time bundling with tsdown rather than being published as separate packages.
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Calculate and display task completion statistics for the current tag context including total tasks, completed tasks, completion percentage, and subtask completion counts using visual progress indicators
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Follow the standard display pattern for UI functions: use documented JSDoc comments describing the function's purpose, parameters, and display a task object with consistent formatting using boxen and chalk
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Generate appropriate numbers of subtasks based on task complexity analysis, using recommended subtask counts from complexity analysis when available instead of always using default counts
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Use visual indicators to show dependency status (✅/⏱️) and format dependency lists consistently when visualizing dependencies
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Format dependency lists consistently for visualization
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs, using numeric IDs for direct task references and string IDs with dot notation (e.g., '1.2') for subtask references
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Support both task and subtask dependencies in cycle detection
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/task-manager.js : task-manager.js should handle reading/writing tasks.json with tagged task lists support, implement CRUD operations, delegate AI interactions to ai-services-unified.js layer, and access non-AI configuration via config-manager.js getters
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent and convert between formats appropriately when needed, avoiding circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Do not create circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Use string IDs with dot notation (e.g., "1.2") for subtask references
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Remove references to non-existent tasks during validation
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks and self-references during cleanup, tracking and reporting changes made during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Detect circular dependencies using DFS and validate task references before operations
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Respect dependency chains and task priorities when selecting work
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Core task functions must accept a context parameter with `{ projectRoot, tag }` properties
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:47.030Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-11-24T17:58:47.030Z
Learning: Applies to scripts/modules/commands.js : Follow the add-subtask command structure with proper options: --parent (required), --task-id, --title, --description, --details, --dependencies, --status, and --generate, with comprehensive parameter validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : For AI-powered commands that benefit from project context, use the ContextGatherer utility for multi-source context extraction, support task IDs, file paths, custom context, and project tree, implement fuzzy search for automatic task discovery, and display detailed token breakdown for transparency.
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:00.056Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/context_gathering.mdc:0-0
Timestamp: 2025-11-24T17:59:00.056Z
Learning: Applies to scripts/**/*.js : Implement a three-step initialization pattern for context-aware commands: (1) validate and parse parameters, (2) initialize context gatherer and find project root, (3) auto-discover relevant tasks using fuzzy search if task IDs not specified
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Follow the provided structure for adding subtasks, including required options and detailed error handling.
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Select tasks based on dependencies (all marked 'done'), priority level, and ID order
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Display progress indicators using both numeric and visual representations, such as showing completed tasks count, total tasks, completion percentage, and progress bars together
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Don't include task manipulations within UI functions; avoid creating circular dependencies with other modules
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : When testing CLI commands built with Commander.js: test command action handlers directly rather than mocking the entire Commander chain; create simplified test-specific implementations of command handlers; explicitly handle all options including defaults and shorthand flags; include null/undefined checks for optional parameters; use fixtures for consistent sample data.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to apps/cli/**/*.{spec,test}.ts : In unit tests for apps/cli, mock tm-core responses but use real Commander/chalk/inquirer/other npm packages to test display logic
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : For task file operations in tests: use test-specific file paths (e.g., 'test-tasks.json'); mock `readJSON` and `writeJSON` to avoid real file system interactions; verify file operations use correct paths; use different paths for each test; verify modifications on in-memory task objects passed to `writeJSON`.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to packages/tm-core/**/*.{spec,test}.ts : In unit tests for tm/core, mock only external I/O (Supabase, APIs, filesystem) and use real internal services
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : When testing UI functions: mock console output and verify correct formatting; test conditional output logic; use `toContain()` or `toMatch()` rather than exact `toBe()` for strings with emojis or formatting; create separate tests for different behavior modes; test structure of formatted output rather than exact string matching.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to **/tests/integration/**/*.{spec,test}.ts : In integration tests, use real tm-core and mock only external boundaries (APIs, DB, filesystem)
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to **/*.test.ts : Unit tests must follow the describe/it pattern, use beforeEach for mock setup with jest.clearAllMocks(), include specific assertions with expect(), and test both success and error scenarios including edge cases
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to tests/teardown.ts : Global teardown file must be created to handle cleanup after all tests complete and prevent worker process leaks
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to tests/setup.ts : Create global test setup file that configures jest.setTimeout(10000), clears all mocks after each test with jest.clearAllMocks(), and initializes global test configuration
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to apps/mcp/**/*.{spec,test}.ts : In unit tests for apps/mcp, mock tm-core responses but use real MCP framework to test response formatting
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Use established mocking patterns from auth.test.ts as templates: mock bcrypt with proper TypeScript typing, mock Prisma client with transaction support, and always clear mocks between tests
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to **/*.integration.test.ts : Integration tests must use supertest for API endpoint testing, verify database state changes after operations, clean test data before each test, and include full request/response validation with expected HTTP status codes
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-12-11T14:45:14.973Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/AGENTS.md:0-0
Timestamp: 2025-12-11T14:45:14.973Z
Learning: Use task status values: 'pending', 'in-progress', 'done', 'deferred', 'cancelled', or 'blocked'
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : Mock file system operations using `mock-fs` library. Mock API calls by providing jest.fn() implementations that return expected structures. Mock environment variables in test setup.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
🧬 Code graph analysis (2)
apps/cli/src/commands/list.command.ts (2)
packages/tm-core/src/common/types/index.ts (2)
Task(131-159)TaskStatus(20-28)packages/tm-core/src/common/constants/index.ts (1)
isTaskComplete(68-70)
apps/cli/tests/unit/commands/list.command.spec.ts (1)
apps/cli/src/commands/list.command.ts (1)
ListTasksCommand(71-628)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
- GitHub Check: Test
- GitHub Check: Cursor Bugbot
🔇 Additional comments (9)
apps/cli/src/commands/list.command.ts (4)
47-54: LGTM: New options and type definition are well-structured.The
readyandblockingoptions are cleanly added to the interface, andTaskWithBlocksprovides a clear type for enriched tasks with inverse dependency information.
262-286: LGTM:buildBlocksMapcorrectly computes inverse dependencies.The method properly initializes all task IDs and iterates through dependencies to build the blocks map.
324-329: LGTM: Simple and effective blocking filter.The filter correctly selects tasks that have a non-empty
blocksarray.
446-451: LGTM: Blocks column enabled in task table.The
showBlocks: trueoption properly enables the new Blocks column in the table display.apps/cli/src/ui/display/tables.ts (2)
20-24: LGTM:TaskTableItemtype correctly handles both tasks and subtasks.The type allows optional
blocksfield since subtasks don't have blocks, while enriched top-level tasks will have the field populated. This design appropriately separates concerns fromTaskWithBlocksin the command file.
190-193: LGTM: Subtasks correctly show dash for blocks.Since subtasks don't participate in the blocking relationship at this level, showing a dash is appropriate.
apps/cli/tests/unit/commands/list.command.spec.ts (3)
209-331: LGTM: Comprehensive test coverage for--readyfilter.The tests cover:
- Tasks with satisfied dependencies
- Exclusion of done/cancelled tasks
- Exclusion of deferred and blocked tasks
- Proper inclusion of pending, in-progress, and review statuses
334-417: LGTM: Good test coverage for blocking and combined filters.The tests correctly verify:
--blockingreturns only tasks that block others--ready --blockingreturns the intersection (high-impact tasks)
419-473: LGTM: Thorough validation ofblocksfield computation.The test verifies the inverse dependency mapping for all tasks, including tasks that block multiple others and tasks that block nothing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (3)
scripts/modules/task-manager/tag-management.js (1)
622-639: Consider extracting ready task calculation into a shared utility function.The ready task filtering logic is duplicated from the list command implementation (which adds
--readyflag). To improve maintainability and ensure consistent behavior across commands, consider extracting this into a shared utility function.Suggested refactor
Create a new utility function in
scripts/modules/utils.jsor a dedicated file:/** * Filter tasks that are ready to work on (actionable status + dependencies satisfied) * @param {Array} tasks - Array of tasks to filter * @returns {Array} Filtered array of ready tasks */ export function filterReadyTasks(tasks) { const completedIds = new Set( tasks .filter( (t) => t.status === 'done' || t.status === 'completed' || t.status === 'cancelled' ) .map((t) => String(t.id)) ); const actionableStatuses = ['pending', 'in-progress', 'review']; return tasks.filter((t) => { if (!actionableStatuses.includes(t.status)) return false; if (!t.dependencies || t.dependencies.length === 0) return true; return t.dependencies.every((depId) => completedIds.has(String(depId))); }); }Then use it in this file:
- // Calculate ready tasks (actionable status + dependencies satisfied) - const completedIds = new Set( - tasks - .filter( - (t) => - t.status === 'done' || - t.status === 'completed' || - t.status === 'cancelled' - ) - .map((t) => String(t.id)) - ); - const actionableStatuses = ['pending', 'in-progress', 'review']; - const readyTasks = tasks.filter((t) => { - if (!actionableStatuses.includes(t.status)) return false; - if (!t.dependencies || t.dependencies.length === 0) return true; - return t.dependencies.every((depId) => completedIds.has(String(depId))); - }); + const readyTasks = filterReadyTasks(tasks);tests/unit/task-manager/tag-management.test.js (2)
150-172: Verify cancelled dependency handling.The test correctly validates that tasks with satisfied dependencies (completed) are counted as ready. However, according to the PR description, dependencies can be satisfied by either "completed or cancelled" status. Consider adding a test case to verify that a task depending on a cancelled task is also counted as ready.
🔎 Add test case for cancelled dependencies
+ it('should count tasks with cancelled dependencies as ready', async () => { + const data = { + master: { + tasks: [ + { id: 1, title: 'Task 1', status: 'cancelled', dependencies: [] }, + { id: 2, title: 'Task 2', status: 'pending', dependencies: [1] }, // cancelled dep should be satisfied + { id: 3, title: 'Task 3', status: 'cancelled', dependencies: [] } // cancelled tasks themselves are not ready + ], + metadata: { created: new Date().toISOString() } + } + }; + fs.writeFileSync(TASKS_PATH, JSON.stringify(data, null, 2)); + + const result = await listTags( + TASKS_PATH, + { showTaskCounts: true }, + { projectRoot: TEMP_DIR }, + 'json' + ); + + const masterTag = result.tags.find((t) => t.name === 'master'); + expect(masterTag.readyTasks).toBe(1); // only task 2 is ready (pending with cancelled dep) + });
126-199: Consider mocking file operations for true unit tests.The tests use real file system operations with temporary directories. While this approach works and is consistent with existing tests in this file, the coding guidelines suggest mocking
readJSONandwriteJSONutilities to create faster, more isolated unit tests. The current approach is more integration-style testing.This is not critical since the tests are properly isolated with cleanup, but mocking would:
- Speed up test execution
- Remove file system dependencies
- Follow the unit testing guidelines more closely
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
.changeset/list-blocks-ready-filter.md(1 hunks)scripts/modules/task-manager/tag-management.js(4 hunks)tests/unit/task-manager/tag-management.test.js(1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
- .changeset/list-blocks-ready-filter.md
🧰 Additional context used
📓 Path-based instructions (14)
**/*.js
📄 CodeRabbit inference engine (.cursor/rules/architecture.mdc)
**/*.js: Always use isSilentMode() function to check current silent mode status instead of directly accessing the global silentMode variable or global.silentMode
Use try/finally block pattern when wrapping core function calls with enableSilentMode/disableSilentMode to ensure silent mode is always restored, even if errors occur
For functions that need to handle both a passed silentMode parameter and check global state, check both the function parameter and global state: const isSilent = options.silentMode || (typeof options.silentMode === 'undefined' && isSilentMode())
Functions should accept their dependencies as parameters rather than using globals to promote testability and explicit dependency injection
Define callbacks as separate functions for easier testing rather than inline functions
Files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
tests/unit/**/*.js
📄 CodeRabbit inference engine (.cursor/rules/architecture.mdc)
Unit tests should be located in tests/unit/ and reflect the module structure with one test file per module
Files:
tests/unit/task-manager/tag-management.test.js
**/*.test.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/new_features.mdc)
**/*.test.{js,ts}: Follow the mock-first-then-import pattern for Jest mocking; use jest.spyOn() for spy functions; clear mocks between tests; verify mocks with the pattern described intests.mdc
Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Files:
tests/unit/task-manager/tag-management.test.js
**/*.{js,jsx}
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
JavaScript test files using Jest must follow the same testing patterns as TypeScript files, include proper mocking of external dependencies, and achieve the same coverage thresholds
Files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
**/*.test.js
📄 CodeRabbit inference engine (.cursor/rules/tests.mdc)
**/*.test.js: Never use asynchronous operations in tests. Always mock tests properly based on the way the tested functions are defined and used.
Follow Jest test file structure: 1) Imports, 2) Mock setup before importing modules under test, 3) Import modules after mocks, 4) Set up spies on mocked modules, 5) Describe suite with descriptive name, 6) Setup/teardown hooks, 7) Grouped tests for related functionality, 8) Individual test cases with clear descriptions using Arrange-Act-Assert pattern.
When testing CLI commands built with Commander.js: test command action handlers directly rather than mocking the entire Commander chain; create simplified test-specific implementations of command handlers; explicitly handle all options including defaults and shorthand flags; include null/undefined checks for optional parameters; use fixtures for consistent sample data.
Usejest.mock()before any imports. Jest hoists mock calls to the top of the file. Always declare mocks before importing modules being tested. Use factory pattern for complex mocks that need access to other variables.
When testing ES modules with dynamic imports, usejest.unstable_mockModule()beforeawait import(). Include__esModule: truein mock factories. Reset mock functions before dynamic import. Mock named and default exports as needed.
Mock file system operations usingmock-fslibrary. Mock API calls by providing jest.fn() implementations that return expected structures. Mock environment variables in test setup.
When testing functions with callbacks: get the callback from mock's call arguments usingmock.calls[index][argIndex]; execute it directly with test inputs; verify results match expectations.
For task file operations in tests: use test-specific file paths (e.g., 'test-tasks.json'); mockreadJSONandwriteJSONto avoid real file system interactions; verify file operations use correct paths; use different paths for each test; verify modifications on in-memory task objects passed t...
Files:
tests/unit/task-manager/tag-management.test.js
tests/unit/**/*.test.js
📄 CodeRabbit inference engine (.cursor/rules/tests.mdc)
Locate unit tests in
tests/unit/directory. Test individual functions and utilities in isolation, mock all external dependencies, keep tests small and focused.
Files:
tests/unit/task-manager/tag-management.test.js
**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
**/*.{js,ts}: Import and use specific getters from config-manager.js (e.g., getMainProvider(), getLogLevel(), getMainMaxTokens()) to access configuration values needed for application logic
Use isApiKeySet(providerName, session) from config-manager.js to check if a provider's key is available before potentially attempting an AI call
Do not add direct console.log calls outside the logging utility - use the central log function instead
Ensure silent mode is disabled in a finally block to prevent it from staying enabled
Do not access the global silentMode variable directly - use the exported silent mode control functions instead
Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Use ContextGatherer class from utils/contextGatherer.js for AI-powered commands that need project context, supporting tasks, files, custom text, and project tree context
Use FuzzyTaskSearch class from utils/fuzzyTaskSearch.js for automatic task relevance detection with configurable search parameters
Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Do not replace explicit user task selections with fuzzy results - fuzzy search should supplement, not replace user selections
Use readJSON and writeJSON utilities for all JSON file operations instead of raw fs.readFileSync or fs.writeFileSync
Include error handling for JSON file operations and validate JSON structure after reading
Use path.join() for cross-platform path construction and path.resolve() for absolute paths, validating paths before file operations
Support both .env files and MCP session environment for environment variable resolution with fallbacks for missing values
Prefer updating the core function to accept an outputFormat parameter and check outputFormat === 'json' before displaying UI elements
Files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
scripts/**/*.js
📄 CodeRabbit inference engine (.cursor/rules/context_gathering.mdc)
scripts/**/*.js: Use theContextGathererclass fromscripts/modules/utils/contextGatherer.jsto extract context from multiple sources (tasks, files, custom text, project tree) with token counting usinggpt-tokenslibrary
InitializeContextGathererwith project root and tasks path, then callgather()method with tasks array, files array, customContext, includeProjectTree, format ('research', 'chat', or 'system-prompt'), and includeTokenCounts options
Use theFuzzyTaskSearchclass fromscripts/modules/utils/fuzzyTaskSearch.jsfor intelligent task discovery with semantic matching, purpose categorization, and relevance scoring using Fuse.js
Implement a three-step initialization pattern for context-aware commands: (1) validate and parse parameters, (2) initialize context gatherer and find project root, (3) auto-discover relevant tasks using fuzzy search if task IDs not specified
Display token breakdown usingboxenlibrary with sections for tasks, files, and prompts, showing formatted token counts and file sizes in a clean bordered box with title
Process AI result responses usingcli-highlightlibrary to apply syntax highlighting to code blocks with language detection in the formatlanguage\ncode
Set reasonable file size limits (50KB default) and project tree depth limits (3-5 levels) when gathering context to maintain performance
Implement graceful error handling for context gathering: handle missing files with warnings, validate task IDs with helpful messages, continue processing if some context sources fail, and provide fallback behavior
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/**/*
📄 CodeRabbit inference engine (.cursor/rules/dev_workflow.mdc)
Restart the MCP server if core logic in
scripts/modulesor MCP tool definitions change
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/*/[!.]*
📄 CodeRabbit inference engine (.cursor/rules/tags.mdc)
scripts/modules/*/[!.]*: All command files in Task Master must importgetCurrentTagfrom utils.js for tag-aware operations
Every CLI command that operates on tasks must include a--tag <tag>CLI option
Tag resolution must follow the priority order: explicit--tagflag, thengetCurrentTag(projectRoot), then default to 'master'
Find and validate project root in commands with error handling before processing tasks
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/task-manager/**/*.{js,mjs}
📄 CodeRabbit inference engine (.cursor/rules/tags.mdc)
scripts/modules/task-manager/**/*.{js,mjs}: Pass context object{ projectRoot, tag }to all core functions that read or write tasks
Core task functions must accept a context parameter with{ projectRoot, tag }properties
UsereadJSON(tasksPath, projectRoot, tag)andwriteJSON(tasksPath, data, projectRoot, tag)for all task data access
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/task-manager/**/*.js
📄 CodeRabbit inference engine (.cursor/rules/telemetry.mdc)
scripts/modules/task-manager/**/*.js: AI service functions in core logic (e.g., in scripts/modules/task-manager/) must call the appropriate AI service function (e.g., generateObjectService) and pass commandName and outputType in the params object
Core logic functions must extract mainResult from aiServiceResponse and return an object that includes aiServiceResponse.telemetryData
Core logic functions with outputFormat parameter must check if outputFormat === 'text' and call displayAiUsageSummary(aiServiceResponse.telemetryData, 'cli') from scripts/modules/ui.js when applicable
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/task-manager/**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
Do not call AI-specific getters (like getMainModelId, getMainMaxTokens) from core logic functions in scripts/modules/task-manager/*. Instead, pass the role to the unified AI service
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
scripts/modules/**/*.{js,ts}: Implement silent migration for tasks.json files that transforms old format to tagged format, marking global flag and performing complete migration
Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
When a logger object is passed as a parameter to core functions, ensure the receiving function can call methods like .info, .warn, .error on that object
Files:
scripts/modules/task-manager/tag-management.js
🧠 Learnings (20)
📓 Common learnings
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/git_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:23.032Z
Learning: Leverage Task Master's tagged task lists system for multi-context development: branch-specific tasks, merge conflict prevention through task isolation, context switching between development contexts, and parallel development by different team members.
Learnt from: eyaltoledano
Repo: eyaltoledano/claude-task-master PR: 1069
File: .changeset/floppy-news-buy.md:7-38
Timestamp: 2025-08-02T14:54:52.216Z
Learning: For major feature additions like new CLI commands, eyaltoledano prefers detailed changesets with comprehensive descriptions, usage examples, and feature explanations rather than minimal single-line summaries.
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Use visual indicators to show dependency status (✅/⏱️) and format dependency lists consistently when visualizing dependencies
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Applied to files:
tests/unit/task-manager/tag-management.test.js
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/task-manager.js : task-manager.js should handle reading/writing tasks.json with tagged task lists support, implement CRUD operations, delegate AI interactions to ai-services-unified.js layer, and access non-AI configuration via config-manager.js getters
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Applied to files:
tests/unit/task-manager/tag-management.test.js
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
Applied to files:
tests/unit/task-manager/tag-management.test.js
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Calculate and display task completion statistics for the current tag context including total tasks, completed tasks, completion percentage, and subtask completion counts using visual progress indicators
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Use cli-table3 for rendering tables with colored headers (cyan and bold), appropriate column widths for readability, and use helper functions like getStatusWithColor, formatDependenciesWithStatus, and truncate for content cells
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Use chalk.blue for informational messages, chalk.green for success messages, chalk.yellow for warnings, chalk.red for errors, chalk.cyan for prompts and highlights, and chalk.magenta for subtask-related information
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Follow the standard display pattern for UI functions: use documented JSDoc comments describing the function's purpose, parameters, and display a task object with consistent formatting using boxen and chalk
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Display progress indicators using both numeric and visual representations, such as showing completed tasks count, total tasks, completion percentage, and progress bars together
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T17:59:00.056Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/context_gathering.mdc:0-0
Timestamp: 2025-11-24T17:59:00.056Z
Learning: Applies to scripts/**/*.js : Display token breakdown using `boxen` library with sections for tasks, files, and prompts, showing formatted token counts and file sizes in a clean bordered box with title
Applied to files:
scripts/modules/task-manager/tag-management.js
🧬 Code graph analysis (2)
tests/unit/task-manager/tag-management.test.js (6)
scripts/modules/task-manager/tag-management.js (7)
data(104-104)data(278-278)data(590-590)data(845-845)data(985-985)data(1146-1146)data(1516-1516)scripts/modules/task-manager/add-subtask.js (1)
data(29-29)mcp-server/src/core/direct-functions/expand-task.js (1)
data(103-103)mcp-server/src/core/direct-functions/remove-task.js (2)
data(65-65)result(95-98)mcp-server/src/core/direct-functions/set-task-status.js (1)
result(88-96)packages/tm-core/src/modules/storage/adapters/api-storage.ts (1)
listTags(397-421)
scripts/modules/task-manager/tag-management.js (2)
scripts/modules/task-manager/remove-task.js (1)
tasks(48-48)tests/unit/ui.test.js (1)
chalk(17-17)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
- GitHub Check: Test
- GitHub Check: Cursor Bugbot
🔇 Additional comments (6)
scripts/modules/task-manager/tag-management.js (3)
646-646: LGTM!The
readyTasksproperty addition is consistent with the existingcompletedTaskspattern and appropriately exposes the ready task count for both JSON and text output.
689-690: LGTM!The table header updates and column width adjustments are well-implemented:
- Headers use consistent color scheme (cyan.bold)
- Column widths are properly calculated for both metadata views
- Width percentages sum correctly without overflow
- Minimum widths ensure readability
Also applies to: 703-714
734-739: LGTM!The Ready column rendering follows established UI patterns with appropriate color coding:
- Yellow highlights actionable ready tasks (count > 0)
- Gray indicates no ready tasks
- Consistent with the project's color scheme guidelines
As per coding guidelines, the color scheme aligns with the standard use of chalk.yellow for highlighting important information and chalk.gray for empty/neutral states.
tests/unit/task-manager/tag-management.test.js (3)
117-124: LGTM - test isolation is properly implemented.The setup and teardown hooks correctly create and clean the temporary directory for each test, ensuring test isolation.
126-148: LGTM - correctly tests tasks without dependencies.The test properly verifies that tasks with
pendingstatus and no dependencies are counted as ready, whiledonetasks are excluded. The logic aligns with the PR requirements.
174-199: LGTM - comprehensive status filtering test.The test correctly verifies that only actionable statuses (
pending,in-progress,review) are counted as ready, whiledeferredandblockedstatuses are excluded. This aligns with the PR requirements.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (4)
.changeset/list-blocks-ready-filter.md(1 hunks)apps/cli/src/commands/tags.command.ts(3 hunks)scripts/modules/task-manager/tag-management.js(9 hunks)tests/unit/task-manager/tag-management.test.js(1 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
- .changeset/list-blocks-ready-filter.md
🧰 Additional context used
📓 Path-based instructions (17)
**/*.js
📄 CodeRabbit inference engine (.cursor/rules/architecture.mdc)
**/*.js: Always use isSilentMode() function to check current silent mode status instead of directly accessing the global silentMode variable or global.silentMode
Use try/finally block pattern when wrapping core function calls with enableSilentMode/disableSilentMode to ensure silent mode is always restored, even if errors occur
For functions that need to handle both a passed silentMode parameter and check global state, check both the function parameter and global state: const isSilent = options.silentMode || (typeof options.silentMode === 'undefined' && isSilentMode())
Functions should accept their dependencies as parameters rather than using globals to promote testability and explicit dependency injection
Define callbacks as separate functions for easier testing rather than inline functions
Files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
tests/unit/**/*.js
📄 CodeRabbit inference engine (.cursor/rules/architecture.mdc)
Unit tests should be located in tests/unit/ and reflect the module structure with one test file per module
Files:
tests/unit/task-manager/tag-management.test.js
**/*.test.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/new_features.mdc)
**/*.test.{js,ts}: Follow the mock-first-then-import pattern for Jest mocking; use jest.spyOn() for spy functions; clear mocks between tests; verify mocks with the pattern described intests.mdc
Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Files:
tests/unit/task-manager/tag-management.test.js
**/*.{js,jsx}
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
JavaScript test files using Jest must follow the same testing patterns as TypeScript files, include proper mocking of external dependencies, and achieve the same coverage thresholds
Files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
**/*.test.js
📄 CodeRabbit inference engine (.cursor/rules/tests.mdc)
**/*.test.js: Never use asynchronous operations in tests. Always mock tests properly based on the way the tested functions are defined and used.
Follow Jest test file structure: 1) Imports, 2) Mock setup before importing modules under test, 3) Import modules after mocks, 4) Set up spies on mocked modules, 5) Describe suite with descriptive name, 6) Setup/teardown hooks, 7) Grouped tests for related functionality, 8) Individual test cases with clear descriptions using Arrange-Act-Assert pattern.
When testing CLI commands built with Commander.js: test command action handlers directly rather than mocking the entire Commander chain; create simplified test-specific implementations of command handlers; explicitly handle all options including defaults and shorthand flags; include null/undefined checks for optional parameters; use fixtures for consistent sample data.
Usejest.mock()before any imports. Jest hoists mock calls to the top of the file. Always declare mocks before importing modules being tested. Use factory pattern for complex mocks that need access to other variables.
When testing ES modules with dynamic imports, usejest.unstable_mockModule()beforeawait import(). Include__esModule: truein mock factories. Reset mock functions before dynamic import. Mock named and default exports as needed.
Mock file system operations usingmock-fslibrary. Mock API calls by providing jest.fn() implementations that return expected structures. Mock environment variables in test setup.
When testing functions with callbacks: get the callback from mock's call arguments usingmock.calls[index][argIndex]; execute it directly with test inputs; verify results match expectations.
For task file operations in tests: use test-specific file paths (e.g., 'test-tasks.json'); mockreadJSONandwriteJSONto avoid real file system interactions; verify file operations use correct paths; use different paths for each test; verify modifications on in-memory task objects passed t...
Files:
tests/unit/task-manager/tag-management.test.js
tests/unit/**/*.test.js
📄 CodeRabbit inference engine (.cursor/rules/tests.mdc)
Locate unit tests in
tests/unit/directory. Test individual functions and utilities in isolation, mock all external dependencies, keep tests small and focused.
Files:
tests/unit/task-manager/tag-management.test.js
**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
**/*.{js,ts}: Import and use specific getters from config-manager.js (e.g., getMainProvider(), getLogLevel(), getMainMaxTokens()) to access configuration values needed for application logic
Use isApiKeySet(providerName, session) from config-manager.js to check if a provider's key is available before potentially attempting an AI call
Do not add direct console.log calls outside the logging utility - use the central log function instead
Ensure silent mode is disabled in a finally block to prevent it from staying enabled
Do not access the global silentMode variable directly - use the exported silent mode control functions instead
Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Use ContextGatherer class from utils/contextGatherer.js for AI-powered commands that need project context, supporting tasks, files, custom text, and project tree context
Use FuzzyTaskSearch class from utils/fuzzyTaskSearch.js for automatic task relevance detection with configurable search parameters
Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Do not replace explicit user task selections with fuzzy results - fuzzy search should supplement, not replace user selections
Use readJSON and writeJSON utilities for all JSON file operations instead of raw fs.readFileSync or fs.writeFileSync
Include error handling for JSON file operations and validate JSON structure after reading
Use path.join() for cross-platform path construction and path.resolve() for absolute paths, validating paths before file operations
Support both .env files and MCP session environment for environment variable resolution with fallbacks for missing values
Prefer updating the core function to accept an outputFormat parameter and check outputFormat === 'json' before displaying UI elements
Files:
tests/unit/task-manager/tag-management.test.jsapps/cli/src/commands/tags.command.tsscripts/modules/task-manager/tag-management.js
**/*.ts
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
TypeScript test files must achieve minimum code coverage thresholds: 80% lines/functions and 70% branches globally, 90% for utilities, and 85% for middleware; new features must meet or exceed these thresholds
Files:
apps/cli/src/commands/tags.command.ts
**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Import modules with
.jsextension even in TypeScript source files for ESM compatibility
Files:
apps/cli/src/commands/tags.command.ts
apps/cli/src/**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
CLI (@tm/cli) should be a thin presentation layer that calls tm-core methods and displays results; handle only CLI-specific concerns like argument parsing, output formatting, and user prompts
Files:
apps/cli/src/commands/tags.command.ts
scripts/**/*.js
📄 CodeRabbit inference engine (.cursor/rules/context_gathering.mdc)
scripts/**/*.js: Use theContextGathererclass fromscripts/modules/utils/contextGatherer.jsto extract context from multiple sources (tasks, files, custom text, project tree) with token counting usinggpt-tokenslibrary
InitializeContextGathererwith project root and tasks path, then callgather()method with tasks array, files array, customContext, includeProjectTree, format ('research', 'chat', or 'system-prompt'), and includeTokenCounts options
Use theFuzzyTaskSearchclass fromscripts/modules/utils/fuzzyTaskSearch.jsfor intelligent task discovery with semantic matching, purpose categorization, and relevance scoring using Fuse.js
Implement a three-step initialization pattern for context-aware commands: (1) validate and parse parameters, (2) initialize context gatherer and find project root, (3) auto-discover relevant tasks using fuzzy search if task IDs not specified
Display token breakdown usingboxenlibrary with sections for tasks, files, and prompts, showing formatted token counts and file sizes in a clean bordered box with title
Process AI result responses usingcli-highlightlibrary to apply syntax highlighting to code blocks with language detection in the formatlanguage\ncode
Set reasonable file size limits (50KB default) and project tree depth limits (3-5 levels) when gathering context to maintain performance
Implement graceful error handling for context gathering: handle missing files with warnings, validate task IDs with helpful messages, continue processing if some context sources fail, and provide fallback behavior
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/**/*
📄 CodeRabbit inference engine (.cursor/rules/dev_workflow.mdc)
Restart the MCP server if core logic in
scripts/modulesor MCP tool definitions change
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/*/[!.]*
📄 CodeRabbit inference engine (.cursor/rules/tags.mdc)
scripts/modules/*/[!.]*: All command files in Task Master must importgetCurrentTagfrom utils.js for tag-aware operations
Every CLI command that operates on tasks must include a--tag <tag>CLI option
Tag resolution must follow the priority order: explicit--tagflag, thengetCurrentTag(projectRoot), then default to 'master'
Find and validate project root in commands with error handling before processing tasks
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/task-manager/**/*.{js,mjs}
📄 CodeRabbit inference engine (.cursor/rules/tags.mdc)
scripts/modules/task-manager/**/*.{js,mjs}: Pass context object{ projectRoot, tag }to all core functions that read or write tasks
Core task functions must accept a context parameter with{ projectRoot, tag }properties
UsereadJSON(tasksPath, projectRoot, tag)andwriteJSON(tasksPath, data, projectRoot, tag)for all task data access
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/task-manager/**/*.js
📄 CodeRabbit inference engine (.cursor/rules/telemetry.mdc)
scripts/modules/task-manager/**/*.js: AI service functions in core logic (e.g., in scripts/modules/task-manager/) must call the appropriate AI service function (e.g., generateObjectService) and pass commandName and outputType in the params object
Core logic functions must extract mainResult from aiServiceResponse and return an object that includes aiServiceResponse.telemetryData
Core logic functions with outputFormat parameter must check if outputFormat === 'text' and call displayAiUsageSummary(aiServiceResponse.telemetryData, 'cli') from scripts/modules/ui.js when applicable
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/task-manager/**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
Do not call AI-specific getters (like getMainModelId, getMainMaxTokens) from core logic functions in scripts/modules/task-manager/*. Instead, pass the role to the unified AI service
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
scripts/modules/**/*.{js,ts}: Implement silent migration for tasks.json files that transforms old format to tagged format, marking global flag and performing complete migration
Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
When a logger object is passed as a parameter to core functions, ensure the receiving function can call methods like .info, .warn, .error on that object
Files:
scripts/modules/task-manager/tag-management.js
🧠 Learnings (33)
📓 Common learnings
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/git_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:23.032Z
Learning: Leverage Task Master's tagged task lists system for multi-context development: branch-specific tasks, merge conflict prevention through task isolation, context switching between development contexts, and parallel development by different team members.
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to new_features.mdc for guidelines on integrating new features into the Task Master CLI with tagged system considerations
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Applied to files:
tests/unit/task-manager/tag-management.test.js
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Applied to files:
tests/unit/task-manager/tag-management.test.jsapps/cli/src/commands/tags.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Applied to files:
tests/unit/task-manager/tag-management.test.jsapps/cli/src/commands/tags.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/task-manager.js : task-manager.js should handle reading/writing tasks.json with tagged task lists support, implement CRUD operations, delegate AI interactions to ai-services-unified.js layer, and access non-AI configuration via config-manager.js getters
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
Applied to files:
tests/unit/task-manager/tag-management.test.js
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Applied to files:
tests/unit/task-manager/tag-management.test.js
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Applied to files:
tests/unit/task-manager/tag-management.test.jsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Pass context object `{ projectRoot, tag }` to all core functions that read or write tasks
Applied to files:
tests/unit/task-manager/tag-management.test.jsapps/cli/src/commands/tags.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/*/[!.]* : Every CLI command that operates on tasks must include a `--tag <tag>` CLI option
Applied to files:
apps/cli/src/commands/tags.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/commands.js : In CLI commands, use specified tag context or default to current tag; call appropriate core functions with options including targetTag and outputFormat parameters
Applied to files:
apps/cli/src/commands/tags.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-08-02T14:54:52.216Z
Learnt from: eyaltoledano
Repo: eyaltoledano/claude-task-master PR: 1069
File: .changeset/floppy-news-buy.md:7-38
Timestamp: 2025-08-02T14:54:52.216Z
Learning: For major feature additions like new CLI commands, eyaltoledano prefers detailed changesets with comprehensive descriptions, usage examples, and feature explanations rather than minimal single-line summaries.
Applied to files:
apps/cli/src/commands/tags.command.ts
📚 Learning: 2025-11-24T17:59:00.056Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/context_gathering.mdc:0-0
Timestamp: 2025-11-24T17:59:00.056Z
Learning: Applies to scripts/**/*.js : Initialize `ContextGatherer` with project root and tasks path, then call `gather()` method with tasks array, files array, customContext, includeProjectTree, format ('research', 'chat', or 'system-prompt'), and includeTokenCounts options
Applied to files:
apps/cli/src/commands/tags.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to mcp-server/src/core/direct-functions/*.js : In MCP direct functions, support explicit tag specification and use tag resolution for task data operations; default to current tag when not specified
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Core task functions must accept a context parameter with `{ projectRoot, tag }` properties
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Calculate and display task completion statistics for the current tag context including total tasks, completed tasks, completion percentage, and subtask completion counts using visual progress indicators
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-07-20T01:35:05.831Z
Learnt from: rtmcrc
Repo: eyaltoledano/claude-task-master PR: 933
File: scripts/modules/task-manager/parse-prd.js:226-226
Timestamp: 2025-07-20T01:35:05.831Z
Learning: The parsePRD function in scripts/modules/task-manager/parse-prd.js has a different parameter structure than other task-manager functions - it uses `options` parameter instead of `context` parameter because it generates tasks from PRD documents rather than operating on existing tasks.
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : For AI-powered commands that benefit from project context, use the ContextGatherer utility for multi-source context extraction, support task IDs, file paths, custom context, and project tree, implement fuzzy search for automatic task discovery, and display detailed token breakdown for transparency.
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to tasks.json : Organize tasks into separate contexts (tags) within tasks.json using tagged format: {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}} instead of legacy format {"tasks": [...]}
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:06.077Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/mcp.mdc:0-0
Timestamp: 2025-11-24T18:01:06.077Z
Learning: Applies to mcp-server/src/**/*.js : Log the start of execution with sanitized arguments, log successful completion with result summary including cache status, and log all error conditions with appropriate log levels
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:06.077Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/mcp.mdc:0-0
Timestamp: 2025-11-24T18:01:06.077Z
Learning: Applies to mcp-server/src/core/direct-functions/*.js : When calling core functions that accept an options object with mcpLog property, pass the FastMCP log object wrapped in a standard logWrapper object with info, warn, error, debug, and success methods
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:06.077Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/mcp.mdc:0-0
Timestamp: 2025-11-24T18:01:06.077Z
Learning: Applies to scripts/modules/*.js : When implementing MCP support for a command, ensure the core logic function can suppress console output via an outputFormat parameter or other mechanism
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Use cli-table3 for rendering tables with colored headers (cyan and bold), appropriate column widths for readability, and use helper functions like getStatusWithColor, formatDependenciesWithStatus, and truncate for content cells
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Use chalk.blue for informational messages, chalk.green for success messages, chalk.yellow for warnings, chalk.red for errors, chalk.cyan for prompts and highlights, and chalk.magenta for subtask-related information
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Follow the standard display pattern for UI functions: use documented JSDoc comments describing the function's purpose, parameters, and display a task object with consistent formatting using boxen and chalk
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Display progress indicators using both numeric and visual representations, such as showing completed tasks count, total tasks, completion percentage, and progress bars together
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T17:59:00.056Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/context_gathering.mdc:0-0
Timestamp: 2025-11-24T17:59:00.056Z
Learning: Applies to scripts/**/*.js : Display token breakdown using `boxen` library with sections for tasks, files, and prompts, showing formatted token counts and file sizes in a clean bordered box with title
Applied to files:
scripts/modules/task-manager/tag-management.js
🧬 Code graph analysis (2)
apps/cli/src/commands/tags.command.ts (1)
scripts/modules/task-manager/tag-management.js (6)
options(49-49)options(253-253)options(548-552)options(1125-1125)options(1375-1375)options(1477-1477)
scripts/modules/task-manager/tag-management.js (1)
scripts/modules/task-manager/add-task.js (1)
logFn(92-101)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: Cursor Bugbot
🔇 Additional comments (2)
apps/cli/src/commands/tags.command.ts (1)
104-112: LGTM! Clean integration of the ready filter.The
--readyoption is properly integrated into the tags list command with:
- Clear help text and example usage
- Type-safe option parameter
- Correct propagation to the legacy bridge function with appropriate default
The implementation follows existing patterns in the file and aligns well with the PR's goal of surfacing tasks ready for parallel execution.
Also applies to: 250-264
tests/unit/task-manager/tag-management.test.js (1)
117-292: LGTM! Comprehensive test coverage for ready task functionality.The new test suites thoroughly validate the ready task feature:
Suite 1 (ready tasks count):
- ✓ Tasks with no dependencies counted as ready
- ✓ Tasks with satisfied dependencies counted correctly
- ✓ Proper status filtering (excludes deferred/blocked, includes pending/in-progress/review)
Suite 2 (--ready filter):
- ✓ Filters out tags with zero ready tasks
- ✓ Includes all tags when flag is off
- ✓ Handles empty result set correctly
- ✓ Validates both
totalTagsandtagsarray consistencyThe tests follow Jest best practices with proper setup/teardown, isolated test data, and specific assertions. They complement the feature implementation well.
| // Calculate ready tasks (actionable status + dependencies satisfied) | ||
| const completedIds = new Set( | ||
| tasks | ||
| .filter( | ||
| (t) => | ||
| t.status === 'done' || | ||
| t.status === 'completed' || | ||
| t.status === 'cancelled' | ||
| ) | ||
| .map((t) => String(t.id)) | ||
| ); | ||
| const actionableStatuses = ['pending', 'in-progress', 'review']; | ||
| const readyTasks = tasks.filter((t) => { | ||
| if (!actionableStatuses.includes(t.status)) return false; | ||
| if (!t.dependencies || t.dependencies.length === 0) return true; | ||
| return t.dependencies.every((depId) => completedIds.has(String(depId))); | ||
| }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🛠️ Refactor suggestion | 🟠 Major
Extract ready task calculation to a shared utility.
The ready task filtering logic duplicates similar calculations that likely exist in the list command for --ready and --blocking filters. This violates the DRY principle and creates maintenance burden.
Additionally, the hardcoded status values (actionableStatuses and completion statuses) should be defined as constants in a shared location to ensure consistency across the codebase.
🔎 Recommended approach
- Create a shared utility function in
scripts/modules/utils.jsor a dedicated file:
// scripts/modules/utils/task-filters.js
export const ACTIONABLE_STATUSES = ['pending', 'in-progress', 'review'];
export const COMPLETED_STATUSES = ['done', 'completed', 'cancelled'];
export function getReadyTasks(tasks) {
const completedIds = new Set(
tasks
.filter(t => COMPLETED_STATUSES.includes(t.status))
.map(t => String(t.id))
);
return tasks.filter(t => {
if (!ACTIONABLE_STATUSES.includes(t.status)) return false;
if (!t.dependencies || t.dependencies.length === 0) return true;
return t.dependencies.every(depId => completedIds.has(String(depId)));
});
}- Use in tag-management.js:
+import { getReadyTasks } from '../utils/task-filters.js';
- const completedIds = new Set(
- tasks
- .filter(
- (t) =>
- t.status === 'done' ||
- t.status === 'completed' ||
- t.status === 'cancelled'
- )
- .map((t) => String(t.id))
- );
- const actionableStatuses = ['pending', 'in-progress', 'review'];
- const readyTasks = tasks.filter((t) => {
- if (!actionableStatuses.includes(t.status)) return false;
- if (!t.dependencies || t.dependencies.length === 0) return true;
- return t.dependencies.every((depId) => completedIds.has(String(depId)));
- });
+ const readyTasks = getReadyTasks(tasks);This ensures consistency with the list command's ready filtering logic.
Committable suggestion skipped: line range outside the PR's diff.
🤖 Prompt for AI Agents
In scripts/modules/task-manager/tag-management.js around lines 627-643 the
ready-task calculation duplicates logic and hardcodes actionable and completion
statuses; extract this into a shared utility (e.g.,
scripts/modules/utils/task-filters.js) that exports ACTIONABLE_STATUSES and
COMPLETED_STATUSES constants and a getReadyTasks(tasks) function which computes
completedIds from COMPLETED_STATUSES and returns tasks filtered by
ACTIONABLE_STATUSES and dependency completion; then replace the inline logic
here with an import and call to getReadyTasks(tasks) to ensure reuse and
consistency across list/--ready/--blocking implementations.
f6d469a to
deaf041
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
♻️ Duplicate comments (3)
scripts/modules/task-manager/tag-management.js (1)
627-656: Duplicate ready task calculation logic should be extracted to a shared utility.This ready task filtering logic duplicates the implementation in
list.command.ts(filterReadyTasksmethod). Both implementations:
- Use the same actionable statuses:
['pending', 'in-progress', 'review']- Use the same completion statuses:
['done', 'completed', 'cancelled']- Apply the same dependency satisfaction check
Note: The tag-management version includes
'completed'as a terminal status whilelist.command.tsusesisTaskComplete()from@tm/core. This inconsistency could cause subtle behavioral differences.🔎 Recommended approach
Extract shared constants and a utility function to a common location:
// scripts/modules/utils/task-filters.js export const ACTIONABLE_STATUSES = ['pending', 'in-progress', 'review']; export function getReadyTasks(tasks) { const completedIds = new Set( tasks .filter(t => isTaskComplete(t.status)) .map(t => String(t.id)) ); return tasks.filter(t => { if (!ACTIONABLE_STATUSES.includes(t.status)) return false; if (!t.dependencies || t.dependencies.length === 0) return true; return t.dependencies.every(depId => completedIds.has(String(depId))); }); }Then import and use in both files.
apps/cli/src/ui/display/tables.ts (1)
20-24: Type definition is appropriately flexible for table rendering.The
TaskTableItemtype correctly uses optionalblocks?: string[]to handle both enriched tasks (with blocks) and subtasks (without blocks). This is more permissive thanTaskWithBlocksinlist.command.ts, which is appropriate for a UI component that may receive varied inputs.While consolidating types to a shared location would reduce duplication, the current approach is functionally correct.
apps/cli/src/commands/list.command.ts (1)
371-401: Ready filter doesn't include subtask IDs incompletedIds, causing incorrect filtering.The
filterReadyTasksmethod only adds top-level task IDs tocompletedIds, but tasks can depend on subtasks (e.g.,'1.1'). Compare this to thefindNextTaskmethod (lines 593-605) which correctly includes subtask IDs using the format${t.id}.${st.id}.If a task depends on a completed subtask, the dependency won't be found in
completedIds, incorrectly marking the task as "not ready."🔎 Proposed fix
private filterReadyTasks(tasks: TaskWithBlocks[]): TaskWithBlocks[] { const actionableStatuses: TaskStatus[] = [ 'pending', 'in-progress', 'review' ]; // Build set of completed task IDs const completedIds = new Set<string>(); tasks.forEach((t) => { if (isTaskComplete(t.status)) { completedIds.add(String(t.id)); } + // Include completed subtasks + if (t.subtasks) { + t.subtasks.forEach((st) => { + if (isTaskComplete(st.status as TaskStatus)) { + completedIds.add(`${t.id}.${st.id}`); + } + }); + } }); return tasks.filter((task) => { if (!actionableStatuses.includes(task.status)) { return false; } if (!task.dependencies || task.dependencies.length === 0) { return true; } return task.dependencies.every((depId) => completedIds.has(String(depId)) ); }); }
🧹 Nitpick comments (2)
apps/cli/src/ui/display/tables.ts (1)
47-91: Column width calculation is thorough but could be simplified.The explicit width arrays for each optional column count (0, 1, 2, 3) work correctly but are verbose. Consider extracting to a configuration object or computing dynamically. However, this is a minor maintainability concern and the current implementation is correct.
apps/cli/tests/unit/commands/list.command.spec.ts (1)
209-250: Consider adding a test for subtask dependencies.The current tests don't cover the case where a task depends on a subtask (e.g.,
dependencies: ['1.1']). Given the bug identified infilterReadyTaskswhere subtask IDs aren't added tocompletedIds, adding such a test would help verify the fix.🔎 Suggested test case
it('should correctly handle subtask dependencies', async () => { const command = new ListTasksCommand(); const mockTasks = [ { id: '1', title: 'Parent Task', status: 'in-progress', dependencies: [], subtasks: [ { id: '1', title: 'Subtask 1', status: 'done', dependencies: [] } ] }, { id: '2', title: 'Task 2', status: 'pending', dependencies: ['1.1'] // depends on completed subtask } ]; // ... mock setup ... await (command as any).executeCommand({ ready: true, json: true }); const output = consoleLogSpy.mock.calls[0][0]; const parsed = JSON.parse(output); // Task 2 should be ready since subtask 1.1 is done expect(parsed.tasks.map((t: any) => t.id)).toContain('2'); });
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (7)
.changeset/list-blocks-ready-filter.md(1 hunks)apps/cli/src/commands/list.command.ts(5 hunks)apps/cli/src/commands/tags.command.ts(3 hunks)apps/cli/src/ui/display/tables.ts(4 hunks)apps/cli/tests/unit/commands/list.command.spec.ts(3 hunks)scripts/modules/task-manager/tag-management.js(9 hunks)tests/unit/task-manager/tag-management.test.js(1 hunks)
🚧 Files skipped from review as they are similar to previous changes (3)
- .changeset/list-blocks-ready-filter.md
- apps/cli/src/commands/tags.command.ts
- tests/unit/task-manager/tag-management.test.js
🧰 Additional context used
📓 Path-based instructions (16)
**/*.ts
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
TypeScript test files must achieve minimum code coverage thresholds: 80% lines/functions and 70% branches globally, 90% for utilities, and 85% for middleware; new features must meet or exceed these thresholds
Files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
**/*.{js,ts}: Import and use specific getters from config-manager.js (e.g., getMainProvider(), getLogLevel(), getMainMaxTokens()) to access configuration values needed for application logic
Use isApiKeySet(providerName, session) from config-manager.js to check if a provider's key is available before potentially attempting an AI call
Do not add direct console.log calls outside the logging utility - use the central log function instead
Ensure silent mode is disabled in a finally block to prevent it from staying enabled
Do not access the global silentMode variable directly - use the exported silent mode control functions instead
Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Use ContextGatherer class from utils/contextGatherer.js for AI-powered commands that need project context, supporting tasks, files, custom text, and project tree context
Use FuzzyTaskSearch class from utils/fuzzyTaskSearch.js for automatic task relevance detection with configurable search parameters
Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Do not replace explicit user task selections with fuzzy results - fuzzy search should supplement, not replace user selections
Use readJSON and writeJSON utilities for all JSON file operations instead of raw fs.readFileSync or fs.writeFileSync
Include error handling for JSON file operations and validate JSON structure after reading
Use path.join() for cross-platform path construction and path.resolve() for absolute paths, validating paths before file operations
Support both .env files and MCP session environment for environment variable resolution with fallbacks for missing values
Prefer updating the core function to accept an outputFormat parameter and check outputFormat === 'json' before displaying UI elements
Files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsscripts/modules/task-manager/tag-management.js
**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Import modules with
.jsextension even in TypeScript source files for ESM compatibility
Files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
apps/cli/src/**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
CLI (@tm/cli) should be a thin presentation layer that calls tm-core methods and displays results; handle only CLI-specific concerns like argument parsing, output formatting, and user prompts
Files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
**/*.spec.ts
📄 CodeRabbit inference engine (CLAUDE.md)
Place package and app test files in
packages/<package-name>/src/<module>/<file>.spec.tsorapps/<app-name>/src/<module>/<file>.spec.tsalongside source files
Files:
apps/cli/tests/unit/commands/list.command.spec.ts
**/*.{spec,test}.ts
📄 CodeRabbit inference engine (CLAUDE.md)
**/*.{spec,test}.ts: Always use.tsfor TypeScript tests, never.js
NEVER use async/await in test functions unless testing actual asynchronous operations; use synchronous top-level imports instead of dynamicawait import()
Files:
apps/cli/tests/unit/commands/list.command.spec.ts
apps/cli/**/*.{spec,test}.ts
📄 CodeRabbit inference engine (CLAUDE.md)
In unit tests for apps/cli, mock tm-core responses but use real Commander/chalk/inquirer/other npm packages to test display logic
Files:
apps/cli/tests/unit/commands/list.command.spec.ts
**/*.js
📄 CodeRabbit inference engine (.cursor/rules/architecture.mdc)
**/*.js: Always use isSilentMode() function to check current silent mode status instead of directly accessing the global silentMode variable or global.silentMode
Use try/finally block pattern when wrapping core function calls with enableSilentMode/disableSilentMode to ensure silent mode is always restored, even if errors occur
For functions that need to handle both a passed silentMode parameter and check global state, check both the function parameter and global state: const isSilent = options.silentMode || (typeof options.silentMode === 'undefined' && isSilentMode())
Functions should accept their dependencies as parameters rather than using globals to promote testability and explicit dependency injection
Define callbacks as separate functions for easier testing rather than inline functions
Files:
scripts/modules/task-manager/tag-management.js
scripts/**/*.js
📄 CodeRabbit inference engine (.cursor/rules/context_gathering.mdc)
scripts/**/*.js: Use theContextGathererclass fromscripts/modules/utils/contextGatherer.jsto extract context from multiple sources (tasks, files, custom text, project tree) with token counting usinggpt-tokenslibrary
InitializeContextGathererwith project root and tasks path, then callgather()method with tasks array, files array, customContext, includeProjectTree, format ('research', 'chat', or 'system-prompt'), and includeTokenCounts options
Use theFuzzyTaskSearchclass fromscripts/modules/utils/fuzzyTaskSearch.jsfor intelligent task discovery with semantic matching, purpose categorization, and relevance scoring using Fuse.js
Implement a three-step initialization pattern for context-aware commands: (1) validate and parse parameters, (2) initialize context gatherer and find project root, (3) auto-discover relevant tasks using fuzzy search if task IDs not specified
Display token breakdown usingboxenlibrary with sections for tasks, files, and prompts, showing formatted token counts and file sizes in a clean bordered box with title
Process AI result responses usingcli-highlightlibrary to apply syntax highlighting to code blocks with language detection in the formatlanguage\ncode
Set reasonable file size limits (50KB default) and project tree depth limits (3-5 levels) when gathering context to maintain performance
Implement graceful error handling for context gathering: handle missing files with warnings, validate task IDs with helpful messages, continue processing if some context sources fail, and provide fallback behavior
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/**/*
📄 CodeRabbit inference engine (.cursor/rules/dev_workflow.mdc)
Restart the MCP server if core logic in
scripts/modulesor MCP tool definitions change
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/*/[!.]*
📄 CodeRabbit inference engine (.cursor/rules/tags.mdc)
scripts/modules/*/[!.]*: All command files in Task Master must importgetCurrentTagfrom utils.js for tag-aware operations
Every CLI command that operates on tasks must include a--tag <tag>CLI option
Tag resolution must follow the priority order: explicit--tagflag, thengetCurrentTag(projectRoot), then default to 'master'
Find and validate project root in commands with error handling before processing tasks
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/task-manager/**/*.{js,mjs}
📄 CodeRabbit inference engine (.cursor/rules/tags.mdc)
scripts/modules/task-manager/**/*.{js,mjs}: Pass context object{ projectRoot, tag }to all core functions that read or write tasks
Core task functions must accept a context parameter with{ projectRoot, tag }properties
UsereadJSON(tasksPath, projectRoot, tag)andwriteJSON(tasksPath, data, projectRoot, tag)for all task data access
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/task-manager/**/*.js
📄 CodeRabbit inference engine (.cursor/rules/telemetry.mdc)
scripts/modules/task-manager/**/*.js: AI service functions in core logic (e.g., in scripts/modules/task-manager/) must call the appropriate AI service function (e.g., generateObjectService) and pass commandName and outputType in the params object
Core logic functions must extract mainResult from aiServiceResponse and return an object that includes aiServiceResponse.telemetryData
Core logic functions with outputFormat parameter must check if outputFormat === 'text' and call displayAiUsageSummary(aiServiceResponse.telemetryData, 'cli') from scripts/modules/ui.js when applicable
Files:
scripts/modules/task-manager/tag-management.js
**/*.{js,jsx}
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
JavaScript test files using Jest must follow the same testing patterns as TypeScript files, include proper mocking of external dependencies, and achieve the same coverage thresholds
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/task-manager/**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
Do not call AI-specific getters (like getMainModelId, getMainMaxTokens) from core logic functions in scripts/modules/task-manager/*. Instead, pass the role to the unified AI service
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
scripts/modules/**/*.{js,ts}: Implement silent migration for tasks.json files that transforms old format to tagged format, marking global flag and performing complete migration
Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
When a logger object is passed as a parameter to core functions, ensure the receiving function can call methods like .info, .warn, .error on that object
Files:
scripts/modules/task-manager/tag-management.js
🧠 Learnings (74)
📓 Common learnings
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/git_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:23.032Z
Learning: Leverage Task Master's tagged task lists system for multi-context development: branch-specific tasks, merge conflict prevention through task isolation, context switching between development contexts, and parallel development by different team members.
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to new_features.mdc for guidelines on integrating new features into the Task Master CLI with tagged system considerations
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: The tasks.json file should use a tagged task lists structure with multiple named task lists as top-level keys (e.g., {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}}), supporting backward compatibility through silent migration from legacy {"tasks": [...]} format
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/task-manager.js : task-manager.js should handle reading/writing tasks.json with tagged task lists support, implement CRUD operations, delegate AI interactions to ai-services-unified.js layer, and access non-AI configuration via config-manager.js getters
Applied to files:
apps/cli/src/commands/list.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use consistent properties for subtasks (id, title, description, status, dependencies, details) without duplicating parent task properties, maintaining simple numeric IDs unique within the parent task
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Applied to files:
apps/cli/src/commands/list.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs, using numeric IDs for direct task references and string IDs with dot notation (e.g., '1.2') for subtask references
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent and convert between formats appropriately when needed, avoiding circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Support both task and subtask dependencies in cycle detection
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Do not create circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Use string IDs with dot notation (e.g., "1.2") for subtask references
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Remove references to non-existent tasks during validation
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks and self-references during cleanup, tracking and reporting changes made during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Detect circular dependencies using DFS and validate task references before operations
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Respect dependency chains and task priorities when selecting work
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Applied to files:
apps/cli/src/commands/list.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
Applied to files:
apps/cli/src/commands/list.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Core task functions must accept a context parameter with `{ projectRoot, tag }` properties
Applied to files:
apps/cli/src/commands/list.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Implement reusable task finding utilities that support both task and subtask lookups and add context to subtask results
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T17:58:47.030Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-11-24T17:58:47.030Z
Learning: Applies to scripts/modules/commands.js : Follow the add-subtask command structure with proper options: --parent (required), --task-id, --title, --description, --details, --dependencies, --status, and --generate, with comprehensive parameter validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Follow the provided structure for adding subtasks, including required options and detailed error handling.
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Select tasks based on dependencies (all marked 'done'), priority level, and ID order
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Calculate and display task completion statistics for the current tag context including total tasks, completed tasks, completion percentage, and subtask completion counts using visual progress indicators
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Include all required task properties (id, title, description, status, dependencies, priority, details, testStrategy, subtasks) in each task object without adding extra properties outside the standard schema
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/ui.js : ui.js should handle CLI output formatting including tables, colors, boxes, spinners, and display tasks, reports, progress, suggestions, and migration notices
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Display progress indicators using both numeric and visual representations, such as showing completed tasks count, total tasks, completion percentage, and progress bars together
Applied to files:
apps/cli/src/commands/list.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Generate appropriate numbers of subtasks based on task complexity analysis, using recommended subtask counts from complexity analysis when available instead of always using default counts
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Follow the standard display pattern for UI functions: use documented JSDoc comments describing the function's purpose, parameters, and display a task object with consistent formatting using boxen and chalk
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Use cli-table3 for rendering tables with colored headers (cyan and bold), appropriate column widths for readability, and use helper functions like getStatusWithColor, formatDependenciesWithStatus, and truncate for content cells
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Don't include task manipulations within UI functions; avoid creating circular dependencies with other modules
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-09-26T19:05:47.555Z
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 1252
File: packages/ai-sdk-provider-grok-cli/package.json:11-13
Timestamp: 2025-09-26T19:05:47.555Z
Learning: In the eyaltoledano/claude-task-master repository, internal tm/ packages use a specific export pattern where the "exports" field points to TypeScript source files (./src/index.ts) while "main" points to compiled output (./dist/index.js) and "types" points to source files (./src/index.ts). This pattern is used consistently across internal packages like tm/core and tm/ai-sdk-provider-grok-cli because they are consumed directly during build-time bundling with tsdown rather than being published as separate packages.
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Applied to files:
apps/cli/src/ui/display/tables.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-09-03T12:16:15.866Z
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 1178
File: packages/tm-core/package.json:13-64
Timestamp: 2025-09-03T12:16:15.866Z
Learning: For internal packages in the claude-task-master project, Crunchyman-ralph prefers pointing package.json "types" entries to src .ts files rather than dist .d.ts files for better developer experience (DX), as the packages are not being exported as SDKs.
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Use visual indicators to show dependency status (✅/⏱️) and format dependency lists consistently when visualizing dependencies
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Format dependency lists consistently for visualization
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : When testing CLI commands built with Commander.js: test command action handlers directly rather than mocking the entire Commander chain; create simplified test-specific implementations of command handlers; explicitly handle all options including defaults and shorthand flags; include null/undefined checks for optional parameters; use fixtures for consistent sample data.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to apps/cli/**/*.{spec,test}.ts : In unit tests for apps/cli, mock tm-core responses but use real Commander/chalk/inquirer/other npm packages to test display logic
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : For task file operations in tests: use test-specific file paths (e.g., 'test-tasks.json'); mock `readJSON` and `writeJSON` to avoid real file system interactions; verify file operations use correct paths; use different paths for each test; verify modifications on in-memory task objects passed to `writeJSON`.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to packages/tm-core/**/*.{spec,test}.ts : In unit tests for tm/core, mock only external I/O (Supabase, APIs, filesystem) and use real internal services
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : When testing UI functions: mock console output and verify correct formatting; test conditional output logic; use `toContain()` or `toMatch()` rather than exact `toBe()` for strings with emojis or formatting; create separate tests for different behavior modes; test structure of formatted output rather than exact string matching.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to **/tests/integration/**/*.{spec,test}.ts : In integration tests, use real tm-core and mock only external boundaries (APIs, DB, filesystem)
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to **/*.test.ts : Unit tests must follow the describe/it pattern, use beforeEach for mock setup with jest.clearAllMocks(), include specific assertions with expect(), and test both success and error scenarios including edge cases
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to tests/teardown.ts : Global teardown file must be created to handle cleanup after all tests complete and prevent worker process leaks
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to tests/setup.ts : Create global test setup file that configures jest.setTimeout(10000), clears all mocks after each test with jest.clearAllMocks(), and initializes global test configuration
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to apps/mcp/**/*.{spec,test}.ts : In unit tests for apps/mcp, mock tm-core responses but use real MCP framework to test response formatting
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Use established mocking patterns from auth.test.ts as templates: mock bcrypt with proper TypeScript typing, mock Prisma client with transaction support, and always clear mocks between tests
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to **/*.integration.test.ts : Integration tests must use supertest for API endpoint testing, verify database state changes after operations, clean test data before each test, and include full request/response validation with expected HTTP status codes
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-12-11T14:45:14.973Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/AGENTS.md:0-0
Timestamp: 2025-12-11T14:45:14.973Z
Learning: Use task status values: 'pending', 'in-progress', 'done', 'deferred', 'cancelled', or 'blocked'
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : Mock file system operations using `mock-fs` library. Mock API calls by providing jest.fn() implementations that return expected structures. Mock environment variables in test setup.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/task-manager.js : Data manipulation features (create, read, update, delete tasks) should be placed in `task-manager.js` and follow guidelines in `tasks.mdc`
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Pass context object `{ projectRoot, tag }` to all core functions that read or write tasks
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T17:59:00.056Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/context_gathering.mdc:0-0
Timestamp: 2025-11-24T17:59:00.056Z
Learning: Applies to scripts/**/*.js : Initialize `ContextGatherer` with project root and tasks path, then call `gather()` method with tasks array, files array, customContext, includeProjectTree, format ('research', 'chat', or 'system-prompt'), and includeTokenCounts options
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-07-20T01:35:05.831Z
Learnt from: rtmcrc
Repo: eyaltoledano/claude-task-master PR: 933
File: scripts/modules/task-manager/parse-prd.js:226-226
Timestamp: 2025-07-20T01:35:05.831Z
Learning: The parsePRD function in scripts/modules/task-manager/parse-prd.js has a different parameter structure than other task-manager functions - it uses `options` parameter instead of `context` parameter because it generates tasks from PRD documents rather than operating on existing tasks.
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : For AI-powered commands that benefit from project context, use the ContextGatherer utility for multi-source context extraction, support task IDs, file paths, custom context, and project tree, implement fuzzy search for automatic task discovery, and display detailed token breakdown for transparency.
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/commands.js : In CLI commands, use specified tag context or default to current tag; call appropriate core functions with options including targetTag and outputFormat parameters
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to tasks.json : Organize tasks into separate contexts (tags) within tasks.json using tagged format: {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}} instead of legacy format {"tasks": [...]}
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:06.077Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/mcp.mdc:0-0
Timestamp: 2025-11-24T18:01:06.077Z
Learning: Applies to mcp-server/src/**/*.js : Log the start of execution with sanitized arguments, log successful completion with result summary including cache status, and log all error conditions with appropriate log levels
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:06.077Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/mcp.mdc:0-0
Timestamp: 2025-11-24T18:01:06.077Z
Learning: Applies to mcp-server/src/core/direct-functions/*.js : When calling core functions that accept an options object with mcpLog property, pass the FastMCP log object wrapped in a standard logWrapper object with info, warn, error, debug, and success methods
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:06.077Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/mcp.mdc:0-0
Timestamp: 2025-11-24T18:01:06.077Z
Learning: Applies to scripts/modules/*.js : When implementing MCP support for a command, ensure the core logic function can suppress console output via an outputFormat parameter or other mechanism
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Use chalk.blue for informational messages, chalk.green for success messages, chalk.yellow for warnings, chalk.red for errors, chalk.cyan for prompts and highlights, and chalk.magenta for subtask-related information
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T17:59:00.056Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/context_gathering.mdc:0-0
Timestamp: 2025-11-24T17:59:00.056Z
Learning: Applies to scripts/**/*.js : Display token breakdown using `boxen` library with sections for tasks, files, and prompts, showing formatted token counts and file sizes in a clean bordered box with title
Applied to files:
scripts/modules/task-manager/tag-management.js
🧬 Code graph analysis (4)
apps/cli/src/commands/list.command.ts (3)
packages/tm-core/src/common/types/index.ts (2)
Task(131-159)TaskStatus(20-28)scripts/modules/dependency-manager.js (1)
depIdStr(1342-1342)packages/tm-core/src/common/constants/index.ts (1)
isTaskComplete(68-70)
apps/cli/src/ui/display/tables.ts (1)
packages/tm-core/src/common/types/index.ts (1)
Subtask(165-169)
apps/cli/tests/unit/commands/list.command.spec.ts (1)
apps/cli/src/commands/list.command.ts (1)
ListTasksCommand(77-726)
scripts/modules/task-manager/tag-management.js (1)
scripts/modules/task-manager/add-task.js (1)
logFn(92-101)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
- GitHub Check: Test
- GitHub Check: Cursor Bugbot
deaf041 to
59d4242
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
♻️ Duplicate comments (3)
scripts/modules/task-manager/tag-management.js (1)
627-656: Ready task calculation logic is duplicated and may have status inconsistency.This ready-task filtering logic duplicates similar calculations in
apps/cli/src/commands/list.command.ts. A past review comment already flagged this for extraction to a shared utility.Additionally, the status check includes
'completed'(line 633), but per project guidelines, the valid statuses are:'pending','in-progress','done','deferred','cancelled','blocked', and'review'. The'completed'status may be legacy or invalid.🔎 Recommended fix
Remove the redundant
'completed'status check to align with valid statuses:const completedIds = new Set( tasks .filter( (t) => - t.status === 'done' || - t.status === 'completed' || - t.status === 'cancelled' + t.status === 'done' || t.status === 'cancelled' ) .map((t) => String(t.id)) );Consider extracting this logic to a shared utility as suggested in the prior review.
apps/cli/src/ui/display/tables.ts (1)
20-24: Type definition differs from list.command.ts.This file defines
TaskTableItem = (Task | Subtask) & { blocks?: string[] }with optionalblocks, whilelist.command.tsdefinesTaskWithBlocks = Task & { blocks: string[] }with requiredblocks.The more flexible optional definition here is appropriate for the table renderer since it can handle both enriched and non-enriched inputs. However, a past review comment suggested consolidating these types to a shared location.
Consider moving the type to a shared location (e.g.,
apps/cli/src/types/task-types.ts) to avoid divergence.apps/cli/src/commands/list.command.ts (1)
368-409: Subtask dependencies not handled in filterReadyTasks.The
filterReadyTasksmethod only adds top-level task IDs tocompletedIds, but dependencies can reference subtasks using dot notation (e.g.,'1.1'). If a task depends on a completed subtask, that dependency won't be recognized as satisfied.The
findNextTaskmethod (lines 593-605) correctly handles subtask IDs by adding${t.id}.${st.id}tocompletedIds. The same pattern should be applied here.🔎 Recommended fix
private filterReadyTasks(tasks: TaskWithBlocks[]): TaskWithBlocks[] { const actionableStatuses: TaskStatus[] = [ 'pending', 'in-progress', 'review' ]; // Build set of completed task IDs const completedIds = new Set<string>(); tasks.forEach((t) => { if (isTaskComplete(t.status)) { completedIds.add(String(t.id)); } + // Also add completed subtask IDs + if (t.subtasks) { + t.subtasks.forEach((st) => { + if (isTaskComplete(st.status as TaskStatus)) { + completedIds.add(`${t.id}.${st.id}`); + } + }); + } });
🧹 Nitpick comments (2)
scripts/modules/task-manager/tag-management.js (1)
718-728: Consider adjusting column width proportions for better readability.The column widths for the metadata view (
showMetadata = true) allocate 8% each to Tasks, Ready, and Done, which may be tight for headers. The current proportions sum to 98%, leaving minimal margin.This is a minor UX concern; the layout should still work but could be tested on narrower terminals.
apps/cli/tests/unit/commands/list.command.spec.ts (1)
8-10: Local constant shadows mock export.
TERMINAL_COMPLETE_STATUSESis defined at module scope (line 9) and also exported from the mocked@tm/core(line 33). The local constant is used by theisTaskCompletemock implementations. This works but is slightly fragile—if the local constant's order differs from the real export, tests could pass but production could fail.Consider defining this once and reusing it in all mocks for consistency, or simply inline the array in each mock since it's small.
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (7)
.changeset/list-blocks-ready-filter.md(1 hunks)apps/cli/src/commands/list.command.ts(5 hunks)apps/cli/src/commands/tags.command.ts(3 hunks)apps/cli/src/ui/display/tables.ts(4 hunks)apps/cli/tests/unit/commands/list.command.spec.ts(3 hunks)scripts/modules/task-manager/tag-management.js(9 hunks)tests/unit/task-manager/tag-management.test.js(1 hunks)
🚧 Files skipped from review as they are similar to previous changes (3)
- apps/cli/src/commands/tags.command.ts
- .changeset/list-blocks-ready-filter.md
- tests/unit/task-manager/tag-management.test.js
🧰 Additional context used
📓 Path-based instructions (16)
**/*.ts
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
TypeScript test files must achieve minimum code coverage thresholds: 80% lines/functions and 70% branches globally, 90% for utilities, and 85% for middleware; new features must meet or exceed these thresholds
Files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
**/*.{js,ts}: Import and use specific getters from config-manager.js (e.g., getMainProvider(), getLogLevel(), getMainMaxTokens()) to access configuration values needed for application logic
Use isApiKeySet(providerName, session) from config-manager.js to check if a provider's key is available before potentially attempting an AI call
Do not add direct console.log calls outside the logging utility - use the central log function instead
Ensure silent mode is disabled in a finally block to prevent it from staying enabled
Do not access the global silentMode variable directly - use the exported silent mode control functions instead
Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Use ContextGatherer class from utils/contextGatherer.js for AI-powered commands that need project context, supporting tasks, files, custom text, and project tree context
Use FuzzyTaskSearch class from utils/fuzzyTaskSearch.js for automatic task relevance detection with configurable search parameters
Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Do not replace explicit user task selections with fuzzy results - fuzzy search should supplement, not replace user selections
Use readJSON and writeJSON utilities for all JSON file operations instead of raw fs.readFileSync or fs.writeFileSync
Include error handling for JSON file operations and validate JSON structure after reading
Use path.join() for cross-platform path construction and path.resolve() for absolute paths, validating paths before file operations
Support both .env files and MCP session environment for environment variable resolution with fallbacks for missing values
Prefer updating the core function to accept an outputFormat parameter and check outputFormat === 'json' before displaying UI elements
Files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsscripts/modules/task-manager/tag-management.js
**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Import modules with
.jsextension even in TypeScript source files for ESM compatibility
Files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
apps/cli/src/**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
CLI (@tm/cli) should be a thin presentation layer that calls tm-core methods and displays results; handle only CLI-specific concerns like argument parsing, output formatting, and user prompts
Files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
**/*.spec.ts
📄 CodeRabbit inference engine (CLAUDE.md)
Place package and app test files in
packages/<package-name>/src/<module>/<file>.spec.tsorapps/<app-name>/src/<module>/<file>.spec.tsalongside source files
Files:
apps/cli/tests/unit/commands/list.command.spec.ts
**/*.{spec,test}.ts
📄 CodeRabbit inference engine (CLAUDE.md)
**/*.{spec,test}.ts: Always use.tsfor TypeScript tests, never.js
NEVER use async/await in test functions unless testing actual asynchronous operations; use synchronous top-level imports instead of dynamicawait import()
Files:
apps/cli/tests/unit/commands/list.command.spec.ts
apps/cli/**/*.{spec,test}.ts
📄 CodeRabbit inference engine (CLAUDE.md)
In unit tests for apps/cli, mock tm-core responses but use real Commander/chalk/inquirer/other npm packages to test display logic
Files:
apps/cli/tests/unit/commands/list.command.spec.ts
**/*.js
📄 CodeRabbit inference engine (.cursor/rules/architecture.mdc)
**/*.js: Always use isSilentMode() function to check current silent mode status instead of directly accessing the global silentMode variable or global.silentMode
Use try/finally block pattern when wrapping core function calls with enableSilentMode/disableSilentMode to ensure silent mode is always restored, even if errors occur
For functions that need to handle both a passed silentMode parameter and check global state, check both the function parameter and global state: const isSilent = options.silentMode || (typeof options.silentMode === 'undefined' && isSilentMode())
Functions should accept their dependencies as parameters rather than using globals to promote testability and explicit dependency injection
Define callbacks as separate functions for easier testing rather than inline functions
Files:
scripts/modules/task-manager/tag-management.js
scripts/**/*.js
📄 CodeRabbit inference engine (.cursor/rules/context_gathering.mdc)
scripts/**/*.js: Use theContextGathererclass fromscripts/modules/utils/contextGatherer.jsto extract context from multiple sources (tasks, files, custom text, project tree) with token counting usinggpt-tokenslibrary
InitializeContextGathererwith project root and tasks path, then callgather()method with tasks array, files array, customContext, includeProjectTree, format ('research', 'chat', or 'system-prompt'), and includeTokenCounts options
Use theFuzzyTaskSearchclass fromscripts/modules/utils/fuzzyTaskSearch.jsfor intelligent task discovery with semantic matching, purpose categorization, and relevance scoring using Fuse.js
Implement a three-step initialization pattern for context-aware commands: (1) validate and parse parameters, (2) initialize context gatherer and find project root, (3) auto-discover relevant tasks using fuzzy search if task IDs not specified
Display token breakdown usingboxenlibrary with sections for tasks, files, and prompts, showing formatted token counts and file sizes in a clean bordered box with title
Process AI result responses usingcli-highlightlibrary to apply syntax highlighting to code blocks with language detection in the formatlanguage\ncode
Set reasonable file size limits (50KB default) and project tree depth limits (3-5 levels) when gathering context to maintain performance
Implement graceful error handling for context gathering: handle missing files with warnings, validate task IDs with helpful messages, continue processing if some context sources fail, and provide fallback behavior
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/**/*
📄 CodeRabbit inference engine (.cursor/rules/dev_workflow.mdc)
Restart the MCP server if core logic in
scripts/modulesor MCP tool definitions change
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/*/[!.]*
📄 CodeRabbit inference engine (.cursor/rules/tags.mdc)
scripts/modules/*/[!.]*: All command files in Task Master must importgetCurrentTagfrom utils.js for tag-aware operations
Every CLI command that operates on tasks must include a--tag <tag>CLI option
Tag resolution must follow the priority order: explicit--tagflag, thengetCurrentTag(projectRoot), then default to 'master'
Find and validate project root in commands with error handling before processing tasks
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/task-manager/**/*.{js,mjs}
📄 CodeRabbit inference engine (.cursor/rules/tags.mdc)
scripts/modules/task-manager/**/*.{js,mjs}: Pass context object{ projectRoot, tag }to all core functions that read or write tasks
Core task functions must accept a context parameter with{ projectRoot, tag }properties
UsereadJSON(tasksPath, projectRoot, tag)andwriteJSON(tasksPath, data, projectRoot, tag)for all task data access
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/task-manager/**/*.js
📄 CodeRabbit inference engine (.cursor/rules/telemetry.mdc)
scripts/modules/task-manager/**/*.js: AI service functions in core logic (e.g., in scripts/modules/task-manager/) must call the appropriate AI service function (e.g., generateObjectService) and pass commandName and outputType in the params object
Core logic functions must extract mainResult from aiServiceResponse and return an object that includes aiServiceResponse.telemetryData
Core logic functions with outputFormat parameter must check if outputFormat === 'text' and call displayAiUsageSummary(aiServiceResponse.telemetryData, 'cli') from scripts/modules/ui.js when applicable
Files:
scripts/modules/task-manager/tag-management.js
**/*.{js,jsx}
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
JavaScript test files using Jest must follow the same testing patterns as TypeScript files, include proper mocking of external dependencies, and achieve the same coverage thresholds
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/task-manager/**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
Do not call AI-specific getters (like getMainModelId, getMainMaxTokens) from core logic functions in scripts/modules/task-manager/*. Instead, pass the role to the unified AI service
Files:
scripts/modules/task-manager/tag-management.js
scripts/modules/**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
scripts/modules/**/*.{js,ts}: Implement silent migration for tasks.json files that transforms old format to tagged format, marking global flag and performing complete migration
Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
When a logger object is passed as a parameter to core functions, ensure the receiving function can call methods like .info, .warn, .error on that object
Files:
scripts/modules/task-manager/tag-management.js
🧠 Learnings (77)
📓 Common learnings
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/git_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:23.032Z
Learning: Leverage Task Master's tagged task lists system for multi-context development: branch-specific tasks, merge conflict prevention through task isolation, context switching between development contexts, and parallel development by different team members.
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: The tasks.json file should use a tagged task lists structure with multiple named task lists as top-level keys (e.g., {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}}), supporting backward compatibility through silent migration from legacy {"tasks": [...]} format
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/task-manager.js : task-manager.js should handle reading/writing tasks.json with tagged task lists support, implement CRUD operations, delegate AI interactions to ai-services-unified.js layer, and access non-AI configuration via config-manager.js getters
Applied to files:
apps/cli/src/commands/list.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use consistent properties for subtasks (id, title, description, status, dependencies, details) without duplicating parent task properties, maintaining simple numeric IDs unique within the parent task
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Applied to files:
apps/cli/src/commands/list.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs, using numeric IDs for direct task references and string IDs with dot notation (e.g., '1.2') for subtask references
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent and convert between formats appropriately when needed, avoiding circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Support both task and subtask dependencies in cycle detection
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Do not create circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Use string IDs with dot notation (e.g., "1.2") for subtask references
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Remove references to non-existent tasks during validation
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks and self-references during cleanup, tracking and reporting changes made during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Detect circular dependencies using DFS and validate task references before operations
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Respect dependency chains and task priorities when selecting work
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Applied to files:
apps/cli/src/commands/list.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
Applied to files:
apps/cli/src/commands/list.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Core task functions must accept a context parameter with `{ projectRoot, tag }` properties
Applied to files:
apps/cli/src/commands/list.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Implement reusable task finding utilities that support both task and subtask lookups and add context to subtask results
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsapps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T17:58:47.030Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-11-24T17:58:47.030Z
Learning: Applies to scripts/modules/commands.js : Follow the add-subtask command structure with proper options: --parent (required), --task-id, --title, --description, --details, --dependencies, --status, and --generate, with comprehensive parameter validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Follow the provided structure for adding subtasks, including required options and detailed error handling.
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Select tasks based on dependencies (all marked 'done'), priority level, and ID order
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Calculate and display task completion statistics for the current tag context including total tasks, completed tasks, completion percentage, and subtask completion counts using visual progress indicators
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Include all required task properties (id, title, description, status, dependencies, priority, details, testStrategy, subtasks) in each task object without adding extra properties outside the standard schema
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/ui.js : ui.js should handle CLI output formatting including tables, colors, boxes, spinners, and display tasks, reports, progress, suggestions, and migration notices
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Display progress indicators using both numeric and visual representations, such as showing completed tasks count, total tasks, completion percentage, and progress bars together
Applied to files:
apps/cli/src/commands/list.command.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Generate appropriate numbers of subtasks based on task complexity analysis, using recommended subtask counts from complexity analysis when available instead of always using default counts
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Follow the standard display pattern for UI functions: use documented JSDoc comments describing the function's purpose, parameters, and display a task object with consistent formatting using boxen and chalk
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Use cli-table3 for rendering tables with colored headers (cyan and bold), appropriate column widths for readability, and use helper functions like getStatusWithColor, formatDependenciesWithStatus, and truncate for content cells
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Don't include task manipulations within UI functions; avoid creating circular dependencies with other modules
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Applied to files:
apps/cli/src/ui/display/tables.tsscripts/modules/task-manager/tag-management.js
📚 Learning: 2025-09-03T12:16:15.866Z
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 1178
File: packages/tm-core/package.json:13-64
Timestamp: 2025-09-03T12:16:15.866Z
Learning: For internal packages in the claude-task-master project, Crunchyman-ralph prefers pointing package.json "types" entries to src .ts files rather than dist .d.ts files for better developer experience (DX), as the packages are not being exported as SDKs.
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-09-26T19:05:47.555Z
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 1252
File: packages/ai-sdk-provider-grok-cli/package.json:11-13
Timestamp: 2025-09-26T19:05:47.555Z
Learning: In the eyaltoledano/claude-task-master repository, internal tm/ packages use a specific export pattern where the "exports" field points to TypeScript source files (./src/index.ts) while "main" points to compiled output (./dist/index.js) and "types" points to source files (./src/index.ts). This pattern is used consistently across internal packages like tm/core and tm/ai-sdk-provider-grok-cli because they are consumed directly during build-time bundling with tsdown rather than being published as separate packages.
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Use visual indicators to show dependency status (✅/⏱️) and format dependency lists consistently when visualizing dependencies
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Format dependency lists consistently for visualization
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : When testing CLI commands built with Commander.js: test command action handlers directly rather than mocking the entire Commander chain; create simplified test-specific implementations of command handlers; explicitly handle all options including defaults and shorthand flags; include null/undefined checks for optional parameters; use fixtures for consistent sample data.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to apps/cli/**/*.{spec,test}.ts : In unit tests for apps/cli, mock tm-core responses but use real Commander/chalk/inquirer/other npm packages to test display logic
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : For task file operations in tests: use test-specific file paths (e.g., 'test-tasks.json'); mock `readJSON` and `writeJSON` to avoid real file system interactions; verify file operations use correct paths; use different paths for each test; verify modifications on in-memory task objects passed to `writeJSON`.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:00:32.617Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to tests.mdc for guidelines on implementing and maintaining tests for Task Master CLI
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : When testing UI functions: mock console output and verify correct formatting; test conditional output logic; use `toContain()` or `toMatch()` rather than exact `toBe()` for strings with emojis or formatting; create separate tests for different behavior modes; test structure of formatted output rather than exact string matching.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to package.json : package.json scripts must include: 'test', 'test:watch', 'test:coverage', 'test:unit', 'test:integration', 'test:e2e', and 'test:ci' commands for testing framework integration
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to **/*.test.ts : Unit tests must follow the describe/it pattern, use beforeEach for mock setup with jest.clearAllMocks(), include specific assertions with expect(), and test both success and error scenarios including edge cases
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to packages/tm-core/**/*.{spec,test}.ts : In unit tests for tm/core, mock only external I/O (Supabase, APIs, filesystem) and use real internal services
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to **/tests/integration/**/*.{spec,test}.ts : In integration tests, use real tm-core and mock only external boundaries (APIs, DB, filesystem)
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to tests/teardown.ts : Global teardown file must be created to handle cleanup after all tests complete and prevent worker process leaks
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to tests/setup.ts : Create global test setup file that configures jest.setTimeout(10000), clears all mocks after each test with jest.clearAllMocks(), and initializes global test configuration
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T22:09:45.455Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: CLAUDE.md:0-0
Timestamp: 2025-11-24T22:09:45.455Z
Learning: Applies to apps/mcp/**/*.{spec,test}.ts : In unit tests for apps/mcp, mock tm-core responses but use real MCP framework to test response formatting
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Use established mocking patterns from auth.test.ts as templates: mock bcrypt with proper TypeScript typing, mock Prisma client with transaction support, and always clear mocks between tests
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:13.456Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/test_workflow.mdc:0-0
Timestamp: 2025-11-24T18:03:13.456Z
Learning: Applies to **/*.integration.test.ts : Integration tests must use supertest for API endpoint testing, verify database state changes after operations, clean test data before each test, and include full request/response validation with expected HTTP status codes
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-12-11T14:45:14.973Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/AGENTS.md:0-0
Timestamp: 2025-12-11T14:45:14.973Z
Learning: Use task status values: 'pending', 'in-progress', 'done', 'deferred', 'cancelled', or 'blocked'
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:03:46.713Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tests.mdc:0-0
Timestamp: 2025-11-24T18:03:46.713Z
Learning: Applies to **/*.test.js : Mock file system operations using `mock-fs` library. Mock API calls by providing jest.fn() implementations that return expected structures. Mock environment variables in test setup.
Applied to files:
apps/cli/tests/unit/commands/list.command.spec.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to mcp-server/src/core/direct-functions/*.js : In MCP direct functions, support explicit tag specification and use tag resolution for task data operations; default to current tag when not specified
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/task-manager.js : Data manipulation features (create, read, update, delete tasks) should be placed in `task-manager.js` and follow guidelines in `tasks.mdc`
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Pass context object `{ projectRoot, tag }` to all core functions that read or write tasks
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T17:59:00.056Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/context_gathering.mdc:0-0
Timestamp: 2025-11-24T17:59:00.056Z
Learning: Applies to scripts/**/*.js : Initialize `ContextGatherer` with project root and tasks path, then call `gather()` method with tasks array, files array, customContext, includeProjectTree, format ('research', 'chat', or 'system-prompt'), and includeTokenCounts options
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-07-20T01:35:05.831Z
Learnt from: rtmcrc
Repo: eyaltoledano/claude-task-master PR: 933
File: scripts/modules/task-manager/parse-prd.js:226-226
Timestamp: 2025-07-20T01:35:05.831Z
Learning: The parsePRD function in scripts/modules/task-manager/parse-prd.js has a different parameter structure than other task-manager functions - it uses `options` parameter instead of `context` parameter because it generates tasks from PRD documents rather than operating on existing tasks.
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : For AI-powered commands that benefit from project context, use the ContextGatherer utility for multi-source context extraction, support task IDs, file paths, custom context, and project tree, implement fuzzy search for automatic task discovery, and display detailed token breakdown for transparency.
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/commands.js : In CLI commands, use specified tag context or default to current tag; call appropriate core functions with options including targetTag and outputFormat parameters
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to tasks.json : Organize tasks into separate contexts (tags) within tasks.json using tagged format: {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}} instead of legacy format {"tasks": [...]}
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:06.077Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/mcp.mdc:0-0
Timestamp: 2025-11-24T18:01:06.077Z
Learning: Applies to mcp-server/src/**/*.js : Log the start of execution with sanitized arguments, log successful completion with result summary including cache status, and log all error conditions with appropriate log levels
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:06.077Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/mcp.mdc:0-0
Timestamp: 2025-11-24T18:01:06.077Z
Learning: Applies to mcp-server/src/core/direct-functions/*.js : When calling core functions that accept an options object with mcpLog property, pass the FastMCP log object wrapped in a standard logWrapper object with info, warn, error, debug, and success methods
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:01:06.077Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/mcp.mdc:0-0
Timestamp: 2025-11-24T18:01:06.077Z
Learning: Applies to scripts/modules/*.js : When implementing MCP support for a command, ensure the core logic function can suppress console output via an outputFormat parameter or other mechanism
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Use chalk.blue for informational messages, chalk.green for success messages, chalk.yellow for warnings, chalk.red for errors, chalk.cyan for prompts and highlights, and chalk.magenta for subtask-related information
Applied to files:
scripts/modules/task-manager/tag-management.js
📚 Learning: 2025-11-24T17:59:00.056Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/context_gathering.mdc:0-0
Timestamp: 2025-11-24T17:59:00.056Z
Learning: Applies to scripts/**/*.js : Display token breakdown using `boxen` library with sections for tasks, files, and prompts, showing formatted token counts and file sizes in a clean bordered box with title
Applied to files:
scripts/modules/task-manager/tag-management.js
🧬 Code graph analysis (3)
apps/cli/src/ui/display/tables.ts (1)
packages/tm-core/src/common/types/index.ts (1)
Subtask(165-169)
apps/cli/tests/unit/commands/list.command.spec.ts (1)
apps/cli/src/commands/list.command.ts (1)
ListTasksCommand(77-726)
scripts/modules/task-manager/tag-management.js (3)
scripts/modules/task-manager/set-task-status.js (1)
options(33-33)mcp-server/src/core/direct-functions/fix-dependencies.js (1)
options(56-56)scripts/modules/task-manager/add-task.js (1)
logFn(92-101)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
- GitHub Check: Test
- GitHub Check: Cursor Bugbot
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
♻️ Duplicate comments (1)
apps/cli/src/commands/list.command.ts (1)
371-402: Critical: Subtask completion not tracked in ready filter.The
completedIdsset only includes top-level task IDs (line 383), but tasks can have dependencies on subtasks using dot notation (e.g.,"1.1"). When a task depends on a completed subtask, the dependency won't be recognized as satisfied, causing the task to be incorrectly excluded from--readyresults.Compare with
findNextTask(lines 605-611), which correctly handles subtasks by adding${t.id}.${st.id}to the completed set.🔎 Proposed fix
// Build set of completed task IDs const completedIds = new Set<string>(); tasks.forEach((t) => { if (isTaskComplete(t.status)) { completedIds.add(String(t.id)); } + // Include completed subtasks + if (t.subtasks) { + t.subtasks.forEach((st) => { + if (isTaskComplete(st.status as TaskStatus)) { + completedIds.add(`${t.id}.${st.id}`); + } + }); + } });Based on learnings: Task dependencies can reference subtasks using dot notation (e.g., "1.2"), and dependency checks must handle both top-level and subtask IDs.
🧹 Nitpick comments (1)
apps/cli/src/commands/list.command.ts (1)
371-409: Consider moving filter logic to @tm/core for reusability.The
filterReadyTasksandfilterBlockingTasksmethods implement business logic that could be useful in other contexts (e.g., the extension, API endpoints). Per coding guidelines stating "CLI should be a thin presentation layer that calls tm-core methods," consider moving these filters to@tm/corefor better separation of concerns and reusability.This would also make the filters available to other consumers of the core library without duplicating the logic.
As per coding guidelines: CLI should be a thin presentation layer over @tm/core.
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
apps/cli/src/commands/list.command.ts(5 hunks)
🧰 Additional context used
📓 Path-based instructions (4)
**/*.ts
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
TypeScript test files must achieve minimum code coverage thresholds: 80% lines/functions and 70% branches globally, 90% for utilities, and 85% for middleware; new features must meet or exceed these thresholds
Files:
apps/cli/src/commands/list.command.ts
**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
**/*.{js,ts}: Import and use specific getters from config-manager.js (e.g., getMainProvider(), getLogLevel(), getMainMaxTokens()) to access configuration values needed for application logic
Use isApiKeySet(providerName, session) from config-manager.js to check if a provider's key is available before potentially attempting an AI call
Do not add direct console.log calls outside the logging utility - use the central log function instead
Ensure silent mode is disabled in a finally block to prevent it from staying enabled
Do not access the global silentMode variable directly - use the exported silent mode control functions instead
Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Use ContextGatherer class from utils/contextGatherer.js for AI-powered commands that need project context, supporting tasks, files, custom text, and project tree context
Use FuzzyTaskSearch class from utils/fuzzyTaskSearch.js for automatic task relevance detection with configurable search parameters
Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Do not replace explicit user task selections with fuzzy results - fuzzy search should supplement, not replace user selections
Use readJSON and writeJSON utilities for all JSON file operations instead of raw fs.readFileSync or fs.writeFileSync
Include error handling for JSON file operations and validate JSON structure after reading
Use path.join() for cross-platform path construction and path.resolve() for absolute paths, validating paths before file operations
Support both .env files and MCP session environment for environment variable resolution with fallbacks for missing values
Prefer updating the core function to accept an outputFormat parameter and check outputFormat === 'json' before displaying UI elements
Files:
apps/cli/src/commands/list.command.ts
**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Import modules with
.jsextension even in TypeScript source files for ESM compatibility
Files:
apps/cli/src/commands/list.command.ts
apps/cli/src/**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
CLI (@tm/cli) should be a thin presentation layer that calls tm-core methods and displays results; handle only CLI-specific concerns like argument parsing, output formatting, and user prompts
Files:
apps/cli/src/commands/list.command.ts
🧠 Learnings (41)
📓 Common learnings
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/git_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:23.032Z
Learning: Leverage Task Master's tagged task lists system for multi-context development: branch-specific tasks, merge conflict prevention through task isolation, context switching between development contexts, and parallel development by different team members.
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: The tasks.json file should use a tagged task lists structure with multiple named task lists as top-level keys (e.g., {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}}), supporting backward compatibility through silent migration from legacy {"tasks": [...]} format
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/task-manager.js : task-manager.js should handle reading/writing tasks.json with tagged task lists support, implement CRUD operations, delegate AI interactions to ai-services-unified.js layer, and access non-AI configuration via config-manager.js getters
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use consistent properties for subtasks (id, title, description, status, dependencies, details) without duplicating parent task properties, maintaining simple numeric IDs unique within the parent task
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs, using numeric IDs for direct task references and string IDs with dot notation (e.g., '1.2') for subtask references
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent and convert between formats appropriately when needed, avoiding circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Support both task and subtask dependencies in cycle detection
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Do not create circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Use string IDs with dot notation (e.g., "1.2") for subtask references
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Remove references to non-existent tasks during validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks and self-references during cleanup, tracking and reporting changes made during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Detect circular dependencies using DFS and validate task references before operations
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Respect dependency chains and task priorities when selecting work
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Core task functions must accept a context parameter with `{ projectRoot, tag }` properties
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Implement reusable task finding utilities that support both task and subtask lookups and add context to subtask results
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:47.030Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-11-24T17:58:47.030Z
Learning: Applies to scripts/modules/commands.js : Follow the add-subtask command structure with proper options: --parent (required), --task-id, --title, --description, --details, --dependencies, --status, and --generate, with comprehensive parameter validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Follow the provided structure for adding subtasks, including required options and detailed error handling.
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Select tasks based on dependencies (all marked 'done'), priority level, and ID order
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Calculate and display task completion statistics for the current tag context including total tasks, completed tasks, completion percentage, and subtask completion counts using visual progress indicators
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/ui.js : ui.js should handle CLI output formatting including tables, colors, boxes, spinners, and display tasks, reports, progress, suggestions, and migration notices
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Follow the standard display pattern for UI functions: use documented JSDoc comments describing the function's purpose, parameters, and display a task object with consistent formatting using boxen and chalk
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Provide next step suggestions after command completion using a consistent format with a boxen container displaying suggested commands using chalk formatting
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:00.056Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/context_gathering.mdc:0-0
Timestamp: 2025-11-24T17:59:00.056Z
Learning: Applies to scripts/**/*.js : Display token breakdown using `boxen` library with sections for tasks, files, and prompts, showing formatted token counts and file sizes in a clean bordered box with title
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:49.782Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/telemetry.mdc:0-0
Timestamp: 2025-11-24T18:02:49.782Z
Learning: Applies to scripts/modules/task-manager/**/*.js : Core logic functions with outputFormat parameter must check if outputFormat === 'text' and call displayAiUsageSummary(aiServiceResponse.telemetryData, 'cli') from scripts/modules/ui.js when applicable
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Use boxen for important success messages with clear formatting, provide suggested next steps after command completion, and include ready-to-use commands for follow-up actions.
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Generate appropriate numbers of subtasks based on task complexity analysis, using recommended subtask counts from complexity analysis when available instead of always using default counts
Applied to files:
apps/cli/src/commands/list.command.ts
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
- GitHub Check: Test
- GitHub Check: Cursor Bugbot
🔇 Additional comments (6)
apps/cli/src/commands/list.command.ts (6)
53-60: LGTM: Clean type definitions for new feature.The
readyandblockingoptions are properly typed, and theTaskWithBlockstype correctly extendsTaskwith theblocksfield. The type system now accurately reflects the runtime data structure.
287-340: Well-structured deferred filtering logic.The implementation correctly handles the interaction between status filtering and ready/blocking filters by:
- Fetching all tasks when
needsAllTasksis true (skipping the status filter)- Computing blocks and applying ready/blocking filters with full task context
- Re-applying the status filter afterward if it was deferred
This ensures dependency completion checks have access to all task states, preventing false negatives.
345-366: LGTM: Correct inverse dependency computation.The
buildBlocksMapimplementation correctly inverts the dependency graph by:
- Initializing all task IDs with empty arrays
- For each dependency, adding the dependent task to the dependency's blocks list
The fallback to an empty array (line 358) handles cases where dependencies reference tasks not in the current set.
407-409: LGTM: Clean blocking filter.The implementation correctly identifies blocking tasks by checking for non-empty
blocksarrays. Simple and effective.
533-577: LGTM: Appropriate conditional rendering.The code correctly suppresses dashboards and next-task recommendations when
--readyor--blockingfilters are active. This prevents displaying misleading statistics computed from filtered subsets and avoids redundant recommendations when users have already specified what they want to see.
304-308: The code correctly filters tasks by tag. Dependencies must reference existing task IDs within the same tag, so cross-tag dependency concerns do not apply here. Tag filtering is intentional for maintaining isolated task contexts.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
♻️ Duplicate comments (4)
apps/cli/src/commands/list.command.ts (3)
371-398: Cross-tag dependencies may not be handled correctly.When fetching tasks per-tag, the
filterReadyTaskscall only sees tasks from that specific tag. If cross-tag dependencies exist (e.g., a task in "feature-a" depending on a task in "master"), the dependency won't be recognized as satisfied sincecompletedIdsis built per-tag.Based on learnings, tasks are always within a tag context, so this may be acceptable if cross-tag dependencies aren't supported. Please verify whether cross-tag dependencies are a valid use case.
58-66: Type duplication with tables.ts.
TaskWithBlocksis defined here with requiredblocks, whileTaskTableItemintables.tshas optionalblocks. This duplication was flagged in a previous review. Consider consolidating into a shared types file.
463-469: Subtask dependencies not tracked in completedIds.The
completedIdsset only includes top-level task IDs, but ignores subtasks. If a task has a dependency on a completed subtask (e.g.,"2.1"), it won't be recognized as satisfied. Compare withfindNextTask(lines 690-702) which correctly handles this.🔎 Suggested fix
// Build set of completed task IDs const completedIds = new Set<string>(); tasks.forEach((t) => { if (isTaskComplete(t.status)) { completedIds.add(String(t.id)); } + // Also track completed subtasks + if (t.subtasks) { + t.subtasks.forEach((st) => { + if (isTaskComplete(st.status as TaskStatus)) { + completedIds.add(`${t.id}.${st.id}`); + } + }); + } });apps/cli/src/ui/display/tables.ts (1)
20-24: Fix Biome formatting error.The pipeline is failing due to a formatting issue on this type definition. Run
biome format --writeto fix.Additionally, this type duplicates
TaskWithBlocksfromlist.command.tsbut with different semantics (optionalblocksvs required). As noted in previous review, consider consolidating these types in a shared location.
🧹 Nitpick comments (3)
apps/cli/src/ui/display/tables.ts (2)
49-105: Consider simplifying column width configuration.The branching logic for 0-4 optional columns works correctly but is verbose. A lookup table or configuration object could reduce duplication and make it easier to maintain.
🔎 Example simplification
const WIDTH_CONFIGS: Record<number, number[]> = { }; const baseColWidths = (WIDTH_CONFIGS[optionalCols] || WIDTH_CONFIGS[4]) .map(pct => Math.floor(tableWidth * pct));
180-194: Unnecessary type cast.The cast
task as TaskTableItemon line 182 is redundant sincetaskis already typed asTaskTableItemfrom the function parameter. This can be removed.🔎 Suggested fix
if (showBlocks) { // Show tasks that depend on this one - const taskWithBlocks = task as TaskTableItem; - if (!taskWithBlocks.blocks || taskWithBlocks.blocks.length === 0) { + if (!task.blocks || task.blocks.length === 0) { row.push(chalk.gray('-')); } else { // Gray out blocks for completed tasks (no longer blocking) - const blocksText = taskWithBlocks.blocks.join(', '); + const blocksText = task.blocks.join(', '); row.push( isTaskComplete(task.status) ? chalk.gray(blocksText) : chalk.yellow(blocksText) ); } }apps/cli/src/commands/list.command.ts (1)
391-397: Redundant tagName mapping.The
tagNameproperty is already added toenrichedTaskson line 388, andfilterReadyTaskspreserves it. The spread operation on lines 395-397 redundantly overwritestagNamewith the same value.🔎 Suggested fix
// Apply ready filter to this tag's tasks const readyTasks = this.filterReadyTasks(enrichedTasks); // Add tag name to each task and collect - allTaggedTasks.push( - ...readyTasks.map((task) => ({ ...task, tagName })) - ); + allTaggedTasks.push(...readyTasks);
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (3)
.changeset/list-blocks-ready-filter.mdapps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
🚧 Files skipped from review as they are similar to previous changes (1)
- .changeset/list-blocks-ready-filter.md
🧰 Additional context used
📓 Path-based instructions (4)
**/*.ts
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
TypeScript test files must achieve minimum code coverage thresholds: 80% lines/functions and 70% branches globally, 90% for utilities, and 85% for middleware; new features must meet or exceed these thresholds
Files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
**/*.{js,ts}: Import and use specific getters from config-manager.js (e.g., getMainProvider(), getLogLevel(), getMainMaxTokens()) to access configuration values needed for application logic
Use isApiKeySet(providerName, session) from config-manager.js to check if a provider's key is available before potentially attempting an AI call
Do not add direct console.log calls outside the logging utility - use the central log function instead
Ensure silent mode is disabled in a finally block to prevent it from staying enabled
Do not access the global silentMode variable directly - use the exported silent mode control functions instead
Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Use ContextGatherer class from utils/contextGatherer.js for AI-powered commands that need project context, supporting tasks, files, custom text, and project tree context
Use FuzzyTaskSearch class from utils/fuzzyTaskSearch.js for automatic task relevance detection with configurable search parameters
Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Do not replace explicit user task selections with fuzzy results - fuzzy search should supplement, not replace user selections
Use readJSON and writeJSON utilities for all JSON file operations instead of raw fs.readFileSync or fs.writeFileSync
Include error handling for JSON file operations and validate JSON structure after reading
Use path.join() for cross-platform path construction and path.resolve() for absolute paths, validating paths before file operations
Support both .env files and MCP session environment for environment variable resolution with fallbacks for missing values
Prefer updating the core function to accept an outputFormat parameter and check outputFormat === 'json' before displaying UI elements
Files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Import modules with
.jsextension even in TypeScript source files for ESM compatibility
Files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
apps/cli/src/**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
CLI (@tm/cli) should be a thin presentation layer that calls tm-core methods and displays results; handle only CLI-specific concerns like argument parsing, output formatting, and user prompts
Files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
🧠 Learnings (54)
📓 Common learnings
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/git_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:23.032Z
Learning: Leverage Task Master's tagged task lists system for multi-context development: branch-specific tasks, merge conflict prevention through task isolation, context switching between development contexts, and parallel development by different team members.
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/AGENTS.md:0-0
Timestamp: 2025-12-11T14:45:14.973Z
Learning: Applies to assets/.claude/settings.json : Add Claude Code tool allowlist configuration in `.claude/settings.json` to include 'Edit', 'Bash(task-master *)', 'Bash(git commit:*)', 'Bash(git add:*)', 'Bash(npm run *)', and 'mcp__task_master_ai__*'
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to new_features.mdc for guidelines on integrating new features into the Task Master CLI with tagged system considerations
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to mcp-server/src/core/direct-functions/*.js : In MCP direct functions, support explicit tag specification and use tag resolution for task data operations; default to current tag when not specified
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/*/[!.]* : Every CLI command that operates on tasks must include a `--tag <tag>` CLI option
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Learnt from: mm-parthy
Repo: eyaltoledano/claude-task-master PR: 943
File: scripts/modules/task-manager/list-tasks.js:0-0
Timestamp: 2025-07-18T08:29:52.384Z
Learning: TODO comments about adding tag support to internal functions like readComplexityReport are obsolete in the boundary-first tag resolution pattern because report paths are already resolved at the CLI command boundary layer before reaching these functions.
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: The tasks.json file should use a tagged task lists structure with multiple named task lists as top-level keys (e.g., {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}}), supporting backward compatibility through silent migration from legacy {"tasks": [...]} format
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to tasks.json : Organize tasks into separate contexts (tags) within tasks.json using tagged format: {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}} instead of legacy format {"tasks": [...]}
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/task-manager.js : task-manager.js should handle reading/writing tasks.json with tagged task lists support, implement CRUD operations, delegate AI interactions to ai-services-unified.js layer, and access non-AI configuration via config-manager.js getters
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use consistent properties for subtasks (id, title, description, status, dependencies, details) without duplicating parent task properties, maintaining simple numeric IDs unique within the parent task
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs, using numeric IDs for direct task references and string IDs with dot notation (e.g., '1.2') for subtask references
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent and convert between formats appropriately when needed, avoiding circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Support both task and subtask dependencies in cycle detection
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Do not create circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Use string IDs with dot notation (e.g., "1.2") for subtask references
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Remove references to non-existent tasks during validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks and self-references during cleanup, tracking and reporting changes made during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Detect circular dependencies using DFS and validate task references before operations
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Respect dependency chains and task priorities when selecting work
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Core task functions must accept a context parameter with `{ projectRoot, tag }` properties
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Implement reusable task finding utilities that support both task and subtask lookups and add context to subtask results
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-31T21:48:00.389Z
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/*/[!.]* : Every CLI command that operates on tasks must include a `--tag <tag>` CLI option
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:47.030Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-11-24T17:58:47.030Z
Learning: Applies to scripts/modules/commands.js : Follow the add-subtask command structure with proper options: --parent (required), --task-id, --title, --description, --details, --dependencies, --status, and --generate, with comprehensive parameter validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Follow the provided structure for adding subtasks, including required options and detailed error handling.
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Select tasks based on dependencies (all marked 'done'), priority level, and ID order
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:00:32.617Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to taskmaster.mdc for comprehensive reference of Taskmaster MCP tools and CLI commands with tagged task lists information
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/commands.js : In CLI commands, use specified tag context or default to current tag; call appropriate core functions with options including targetTag and outputFormat parameters
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Use `readJSON(tasksPath, projectRoot, tag)` and `writeJSON(tasksPath, data, projectRoot, tag)` for all task data access
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Calculate and display task completion statistics for the current tag context including total tasks, completed tasks, completion percentage, and subtask completion counts using visual progress indicators
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/ui.js : ui.js should handle CLI output formatting including tables, colors, boxes, spinners, and display tasks, reports, progress, suggestions, and migration notices
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Follow the standard display pattern for UI functions: use documented JSDoc comments describing the function's purpose, parameters, and display a task object with consistent formatting using boxen and chalk
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Provide next step suggestions after command completion using a consistent format with a boxen container displaying suggested commands using chalk formatting
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:00.056Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/context_gathering.mdc:0-0
Timestamp: 2025-11-24T17:59:00.056Z
Learning: Applies to scripts/**/*.js : Display token breakdown using `boxen` library with sections for tasks, files, and prompts, showing formatted token counts and file sizes in a clean bordered box with title
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:49.782Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/telemetry.mdc:0-0
Timestamp: 2025-11-24T18:02:49.782Z
Learning: Applies to scripts/modules/task-manager/**/*.js : Core logic functions with outputFormat parameter must check if outputFormat === 'text' and call displayAiUsageSummary(aiServiceResponse.telemetryData, 'cli') from scripts/modules/ui.js when applicable
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Generate appropriate numbers of subtasks based on task complexity analysis, using recommended subtask counts from complexity analysis when available instead of always using default counts
Applied to files:
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Use boxen for important success messages with clear formatting, provide suggested next steps after command completion, and include ready-to-use commands for follow-up actions.
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Use cli-table3 for rendering tables with colored headers (cyan and bold), appropriate column widths for readability, and use helper functions like getStatusWithColor, formatDependenciesWithStatus, and truncate for content cells
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-09-03T12:16:15.866Z
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 1178
File: packages/tm-core/package.json:13-64
Timestamp: 2025-09-03T12:16:15.866Z
Learning: For internal packages in the claude-task-master project, Crunchyman-ralph prefers pointing package.json "types" entries to src .ts files rather than dist .d.ts files for better developer experience (DX), as the packages are not being exported as SDKs.
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-09-26T19:05:47.555Z
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 1252
File: packages/ai-sdk-provider-grok-cli/package.json:11-13
Timestamp: 2025-09-26T19:05:47.555Z
Learning: In the eyaltoledano/claude-task-master repository, internal tm/ packages use a specific export pattern where the "exports" field points to TypeScript source files (./src/index.ts) while "main" points to compiled output (./dist/index.js) and "types" points to source files (./src/index.ts). This pattern is used consistently across internal packages like tm/core and tm/ai-sdk-provider-grok-cli because they are consumed directly during build-time bundling with tsdown rather than being published as separate packages.
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Include all required task properties (id, title, description, status, dependencies, priority, details, testStrategy, subtasks) in each task object without adding extra properties outside the standard schema
Applied to files:
apps/cli/src/ui/display/tables.ts
🧬 Code graph analysis (2)
apps/cli/src/commands/list.command.ts (3)
packages/tm-core/src/common/types/index.ts (3)
Task(131-159)StorageType(11-11)TaskStatus(20-28)packages/tm-core/src/common/constants/index.ts (1)
isTaskComplete(68-70)apps/cli/src/utils/display-helpers.ts (1)
displayCommandHeader(14-43)
apps/cli/src/ui/display/tables.ts (1)
packages/tm-core/src/common/types/index.ts (1)
Subtask(165-169)
🪛 GitHub Actions: CI
apps/cli/src/commands/list.command.ts
[error] 124-129: Biome format check failed. Formatter would have printed changes here. Run 'biome format .' to apply fixes or 'biome format --write' to write changes.
apps/cli/src/ui/display/tables.ts
[error] 24-27: Biome format check failed. Formatter would have printed changes to type definition. Run 'biome format .' to apply fixes or 'biome format --write' to write changes.
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: Cursor Bugbot
🔇 Additional comments (4)
apps/cli/src/ui/display/tables.ts (1)
207-253: LGTM!The subtask rendering correctly handles the optional Tag and Blocks columns with appropriate dash placeholders, maintaining consistent alignment with parent task rows.
apps/cli/src/commands/list.command.ts (3)
426-450: LGTM!The
buildBlocksMapcorrectly inverts the dependency graph by adding each task to its dependencies' blocks lists. The logic is clean and efficient.
301-347: LGTM - Status filter ordering is correct.The implementation correctly defers the status filter when
--readyor--blockingis used, ensuringcompletedIdsis built from the full task set before filtering. This addresses the previously flagged concern about status filter ordering.
622-667: LGTM!Suppressing dashboards and next-task recommendations when using
--ready,--blocking, or--all-tagsis appropriate since these filtered views would show misleading aggregate statistics.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
♻️ Duplicate comments (1)
apps/cli/src/commands/list.command.ts (1)
463-468: Subtask completion not tracked in ready filter.The
completedIdsset only includes top-level task IDs. When a task depends on a completed subtask (e.g.,"2.1"), that dependency won't be recognized as satisfied. Compare tofindNextTask(lines 695-701), which correctly adds subtask IDs in the format${t.id}.${st.id}.🔎 Proposed fix
Add subtask IDs to the completed set:
// Build set of completed task IDs const completedIds = new Set<string>(); tasks.forEach((t) => { if (isTaskComplete(t.status)) { completedIds.add(String(t.id)); } + // Also track completed subtasks + if (t.subtasks) { + t.subtasks.forEach((st) => { + if (isTaskComplete(st.status as TaskStatus)) { + completedIds.add(`${t.id}.${st.id}`); + } + }); + } });
🧹 Nitpick comments (1)
apps/cli/src/ui/display/tables.ts (1)
52-108: Consider extracting column width calculation into a helper.The if-else cascade with hardcoded percentages makes it difficult to adjust layouts or add new optional columns. A helper function that takes column counts and returns proportional widths would improve maintainability.
Example approach
function calculateColumnWidths( tableWidth: number, coreColumns: number, optionalColumns: number ): number[] { // Define proportions based on total column count const totalCols = coreColumns + optionalColumns; const baseWidthMap = { // ... etc }; const proportions = baseWidthMap[totalCols] || /* fallback */; return proportions.map(p => Math.floor(tableWidth * p)); }This centralizes the logic and makes it easier to tune layouts.
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
apps/cli/src/commands/list.command.tsapps/cli/src/ui/display/tables.ts
🧰 Additional context used
📓 Path-based instructions (4)
**/*.ts
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
TypeScript test files must achieve minimum code coverage thresholds: 80% lines/functions and 70% branches globally, 90% for utilities, and 85% for middleware; new features must meet or exceed these thresholds
Files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
**/*.{js,ts}: Import and use specific getters from config-manager.js (e.g., getMainProvider(), getLogLevel(), getMainMaxTokens()) to access configuration values needed for application logic
Use isApiKeySet(providerName, session) from config-manager.js to check if a provider's key is available before potentially attempting an AI call
Do not add direct console.log calls outside the logging utility - use the central log function instead
Ensure silent mode is disabled in a finally block to prevent it from staying enabled
Do not access the global silentMode variable directly - use the exported silent mode control functions instead
Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Use ContextGatherer class from utils/contextGatherer.js for AI-powered commands that need project context, supporting tasks, files, custom text, and project tree context
Use FuzzyTaskSearch class from utils/fuzzyTaskSearch.js for automatic task relevance detection with configurable search parameters
Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Do not replace explicit user task selections with fuzzy results - fuzzy search should supplement, not replace user selections
Use readJSON and writeJSON utilities for all JSON file operations instead of raw fs.readFileSync or fs.writeFileSync
Include error handling for JSON file operations and validate JSON structure after reading
Use path.join() for cross-platform path construction and path.resolve() for absolute paths, validating paths before file operations
Support both .env files and MCP session environment for environment variable resolution with fallbacks for missing values
Prefer updating the core function to accept an outputFormat parameter and check outputFormat === 'json' before displaying UI elements
Files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Import modules with
.jsextension even in TypeScript source files for ESM compatibility
Files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
apps/cli/src/**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
CLI (@tm/cli) should be a thin presentation layer that calls tm-core methods and displays results; handle only CLI-specific concerns like argument parsing, output formatting, and user prompts
Files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
🧠 Learnings (57)
📓 Common learnings
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/git_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:23.032Z
Learning: Leverage Task Master's tagged task lists system for multi-context development: branch-specific tasks, merge conflict prevention through task isolation, context switching between development contexts, and parallel development by different team members.
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to new_features.mdc for guidelines on integrating new features into the Task Master CLI with tagged system considerations
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Learnt from: eyaltoledano
Repo: eyaltoledano/claude-task-master PR: 1069
File: .changeset/floppy-news-buy.md:7-38
Timestamp: 2025-08-02T14:54:52.216Z
Learning: For major feature additions like new CLI commands, eyaltoledano prefers detailed changesets with comprehensive descriptions, usage examples, and feature explanations rather than minimal single-line summaries.
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/AGENTS.md:0-0
Timestamp: 2025-12-11T14:45:14.973Z
Learning: Applies to assets/.claude/settings.json : Add Claude Code tool allowlist configuration in `.claude/settings.json` to include 'Edit', 'Bash(task-master *)', 'Bash(git commit:*)', 'Bash(git add:*)', 'Bash(npm run *)', and 'mcp__task_master_ai__*'
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Implement reusable task finding utilities that support both task and subtask lookups and add context to subtask results
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Use cli-table3 for rendering tables with colored headers (cyan and bold), appropriate column widths for readability, and use helper functions like getStatusWithColor, formatDependenciesWithStatus, and truncate for content cells
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-09-26T19:05:47.555Z
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 1252
File: packages/ai-sdk-provider-grok-cli/package.json:11-13
Timestamp: 2025-09-26T19:05:47.555Z
Learning: In the eyaltoledano/claude-task-master repository, internal tm/ packages use a specific export pattern where the "exports" field points to TypeScript source files (./src/index.ts) while "main" points to compiled output (./dist/index.js) and "types" points to source files (./src/index.ts). This pattern is used consistently across internal packages like tm/core and tm/ai-sdk-provider-grok-cli because they are consumed directly during build-time bundling with tsdown rather than being published as separate packages.
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Include all required task properties (id, title, description, status, dependencies, priority, details, testStrategy, subtasks) in each task object without adding extra properties outside the standard schema
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use consistent properties for subtasks (id, title, description, status, dependencies, details) without duplicating parent task properties, maintaining simple numeric IDs unique within the parent task
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: The tasks.json file should use a tagged task lists structure with multiple named task lists as top-level keys (e.g., {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}}), supporting backward compatibility through silent migration from legacy {"tasks": [...]} format
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-09-03T12:16:15.866Z
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 1178
File: packages/tm-core/package.json:13-64
Timestamp: 2025-09-03T12:16:15.866Z
Learning: For internal packages in the claude-task-master project, Crunchyman-ralph prefers pointing package.json "types" entries to src .ts files rather than dist .d.ts files for better developer experience (DX), as the packages are not being exported as SDKs.
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Calculate and display task completion statistics for the current tag context including total tasks, completed tasks, completion percentage, and subtask completion counts using visual progress indicators
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/ui.js : ui.js should handle CLI output formatting including tables, colors, boxes, spinners, and display tasks, reports, progress, suggestions, and migration notices
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:47.030Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-11-24T17:58:47.030Z
Learning: Applies to scripts/modules/commands.js : Provide clear feedback about operation status, display success or error messages after completion, and use colored output (chalk) to distinguish between message types
Applied to files:
apps/cli/src/ui/display/tables.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Generate appropriate numbers of subtasks based on task complexity analysis, using recommended subtask counts from complexity analysis when available instead of always using default counts
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs, using numeric IDs for direct task references and string IDs with dot notation (e.g., '1.2') for subtask references
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Follow the standard display pattern for UI functions: use documented JSDoc comments describing the function's purpose, parameters, and display a task object with consistent formatting using boxen and chalk
Applied to files:
apps/cli/src/ui/display/tables.tsapps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to tasks.json : Organize tasks into separate contexts (tags) within tasks.json using tagged format: {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}} instead of legacy format {"tasks": [...]}
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/task-manager.js : task-manager.js should handle reading/writing tasks.json with tagged task lists support, implement CRUD operations, delegate AI interactions to ai-services-unified.js layer, and access non-AI configuration via config-manager.js getters
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent and convert between formats appropriately when needed, avoiding circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Support both task and subtask dependencies in cycle detection
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Do not create circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Use string IDs with dot notation (e.g., "1.2") for subtask references
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Remove references to non-existent tasks during validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks and self-references during cleanup, tracking and reporting changes made during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Detect circular dependencies using DFS and validate task references before operations
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Respect dependency chains and task priorities when selecting work
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Core task functions must accept a context parameter with `{ projectRoot, tag }` properties
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/*/[!.]* : Every CLI command that operates on tasks must include a `--tag <tag>` CLI option
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-31T21:48:00.389Z
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to mcp-server/src/core/direct-functions/*.js : In MCP direct functions, support explicit tag specification and use tag resolution for task data operations; default to current tag when not specified
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:47.030Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-11-24T17:58:47.030Z
Learning: Applies to scripts/modules/commands.js : Follow the add-subtask command structure with proper options: --parent (required), --task-id, --title, --description, --details, --dependencies, --status, and --generate, with comprehensive parameter validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Follow the provided structure for adding subtasks, including required options and detailed error handling.
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Select tasks based on dependencies (all marked 'done'), priority level, and ID order
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:00:32.617Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to taskmaster.mdc for comprehensive reference of Taskmaster MCP tools and CLI commands with tagged task lists information
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:00:32.617Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to architecture.mdc for understanding the high-level architecture of the Task Master CLI application, including the tagged task lists system
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/commands.js : In CLI commands, use specified tag context or default to current tag; call appropriate core functions with options including targetTag and outputFormat parameters
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Use `readJSON(tasksPath, projectRoot, tag)` and `writeJSON(tasksPath, data, projectRoot, tag)` for all task data access
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Provide next step suggestions after command completion using a consistent format with a boxen container displaying suggested commands using chalk formatting
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:00.056Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/context_gathering.mdc:0-0
Timestamp: 2025-11-24T17:59:00.056Z
Learning: Applies to scripts/**/*.js : Display token breakdown using `boxen` library with sections for tasks, files, and prompts, showing formatted token counts and file sizes in a clean bordered box with title
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:49.782Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/telemetry.mdc:0-0
Timestamp: 2025-11-24T18:02:49.782Z
Learning: Applies to scripts/modules/task-manager/**/*.js : Core logic functions with outputFormat parameter must check if outputFormat === 'text' and call displayAiUsageSummary(aiServiceResponse.telemetryData, 'cli') from scripts/modules/ui.js when applicable
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Use boxen for important success messages with clear formatting, provide suggested next steps after command completion, and include ready-to-use commands for follow-up actions.
Applied to files:
apps/cli/src/commands/list.command.ts
🪛 GitHub Actions: CI
apps/cli/src/commands/list.command.ts
[error] 396-396: tsc --noEmit failed: TS2345: Argument of type 'TaskWithBlocks' is not assignable to parameter of type 'TaskWithTag'.
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: Cursor Bugbot
🔇 Additional comments (2)
apps/cli/src/ui/display/tables.ts (1)
183-197: LGTM: Blocks column rendering logic is sound.The color coding (gray for completed, yellow for active blocks) effectively communicates whether a task is still actively blocking others. The use of
isTaskCompleteensures consistency with other status checks.apps/cli/src/commands/list.command.ts (1)
307-319: No issue found. The tag filter at line 319 is correct—dependencies are restricted to within-tag boundaries by design, sofilterReadyTasks()only needs tasks from the specified tag to accurately compute satisfied dependencies.Likely an incorrect or invalid review comment.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
♻️ Duplicate comments (1)
apps/cli/src/commands/list.command.ts (1)
455-486: Fix subtask dependency handling in ready filter.The
filterReadyTasksmethod only adds top-level task IDs tocompletedIds(lines 464-469), ignoring subtasks. If a task depends on a subtask like"1.1", that dependency will never be satisfied, and the task will incorrectly be excluded from ready results.The
findNextTaskmethod (lines 696-702) correctly includes subtask IDs using the format${parentId}.${subtaskId}. Apply the same pattern here.🔎 Proposed fix
Add subtask IDs to completedIds:
private filterReadyTasks(tasks: TaskWithBlocks[]): TaskWithBlocks[] { // Statuses that are actionable (not deferred, blocked, or terminal) const actionableStatuses: TaskStatus[] = [ 'pending', 'in-progress', 'review' ]; - // Build set of completed task IDs + // Build set of completed task IDs (including subtasks) const completedIds = new Set<string>(); tasks.forEach((t) => { if (isTaskComplete(t.status)) { completedIds.add(String(t.id)); } + // Include completed subtasks with format "parentId.subtaskId" + if (t.subtasks) { + t.subtasks.forEach((st) => { + if (isTaskComplete(st.status as TaskStatus)) { + completedIds.add(`${t.id}.${st.id}`); + } + }); + } }); return tasks.filter((task) => { // Must be in an actionable status (excludes deferred, blocked, done, cancelled) if (!actionableStatuses.includes(task.status)) { return false; } // Must have all dependencies satisfied if (!task.dependencies || task.dependencies.length === 0) { return true; } return task.dependencies.every((depId) => completedIds.has(String(depId)) ); }); }
🧹 Nitpick comments (1)
apps/cli/src/commands/list.command.ts (1)
392-395: MakefilterReadyTasksgeneric to preserve input type.The type cast on line 394 assumes that
filterReadyTaskspreserves thetagNameproperty, but the function signature returnsTaskWithBlocks[], which doesn't includetagName. While the cast is safe at runtime (becausefilter()preserves properties), it's fragile and could break if the implementation changes.🔎 Proposed refactor
Make the function generic to preserve all input properties:
/** * Filter to only tasks that are ready to work on (dependencies satisfied, actionable status) */ - private filterReadyTasks(tasks: TaskWithBlocks[]): TaskWithBlocks[] { + private filterReadyTasks<T extends TaskWithBlocks>(tasks: T[]): T[] { // Statuses that are actionable (not deferred, blocked, or terminal) const actionableStatuses: TaskStatus[] = [ 'pending', 'in-progress', 'review' ]; // Build set of completed task IDs const completedIds = new Set<string>(); tasks.forEach((t) => { if (isTaskComplete(t.status)) { completedIds.add(String(t.id)); } }); return tasks.filter((task) => { // Must be in an actionable status (excludes deferred, blocked, done, cancelled) if (!actionableStatuses.includes(task.status)) { return false; } // Must have all dependencies satisfied if (!task.dependencies || task.dependencies.length === 0) { return true; } return task.dependencies.every((depId) => completedIds.has(String(depId)) ); }); }Then remove the cast at line 394:
- const tasksToAdd: TaskWithTag[] = options.ready - ? (this.filterReadyTasks(enrichedTasks) as TaskWithTag[]) - : enrichedTasks; + const tasksToAdd = options.ready + ? this.filterReadyTasks(enrichedTasks) + : enrichedTasks;TypeScript will infer
T = TaskWithTagand returnTaskWithTag[]automatically.
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
apps/cli/src/commands/list.command.ts
🧰 Additional context used
📓 Path-based instructions (4)
**/*.ts
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
TypeScript test files must achieve minimum code coverage thresholds: 80% lines/functions and 70% branches globally, 90% for utilities, and 85% for middleware; new features must meet or exceed these thresholds
Files:
apps/cli/src/commands/list.command.ts
**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
**/*.{js,ts}: Import and use specific getters from config-manager.js (e.g., getMainProvider(), getLogLevel(), getMainMaxTokens()) to access configuration values needed for application logic
Use isApiKeySet(providerName, session) from config-manager.js to check if a provider's key is available before potentially attempting an AI call
Do not add direct console.log calls outside the logging utility - use the central log function instead
Ensure silent mode is disabled in a finally block to prevent it from staying enabled
Do not access the global silentMode variable directly - use the exported silent mode control functions instead
Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Use ContextGatherer class from utils/contextGatherer.js for AI-powered commands that need project context, supporting tasks, files, custom text, and project tree context
Use FuzzyTaskSearch class from utils/fuzzyTaskSearch.js for automatic task relevance detection with configurable search parameters
Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Do not replace explicit user task selections with fuzzy results - fuzzy search should supplement, not replace user selections
Use readJSON and writeJSON utilities for all JSON file operations instead of raw fs.readFileSync or fs.writeFileSync
Include error handling for JSON file operations and validate JSON structure after reading
Use path.join() for cross-platform path construction and path.resolve() for absolute paths, validating paths before file operations
Support both .env files and MCP session environment for environment variable resolution with fallbacks for missing values
Prefer updating the core function to accept an outputFormat parameter and check outputFormat === 'json' before displaying UI elements
Files:
apps/cli/src/commands/list.command.ts
**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Import modules with
.jsextension even in TypeScript source files for ESM compatibility
Files:
apps/cli/src/commands/list.command.ts
apps/cli/src/**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
CLI (@tm/cli) should be a thin presentation layer that calls tm-core methods and displays results; handle only CLI-specific concerns like argument parsing, output formatting, and user prompts
Files:
apps/cli/src/commands/list.command.ts
🧠 Learnings (51)
📓 Common learnings
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/git_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:23.032Z
Learning: Leverage Task Master's tagged task lists system for multi-context development: branch-specific tasks, merge conflict prevention through task isolation, context switching between development contexts, and parallel development by different team members.
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: The tasks.json file should use a tagged task lists structure with multiple named task lists as top-level keys (e.g., {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}}), supporting backward compatibility through silent migration from legacy {"tasks": [...]} format
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to tasks.json : Organize tasks into separate contexts (tags) within tasks.json using tagged format: {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}} instead of legacy format {"tasks": [...]}
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:00:32.617Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to architecture.mdc for understanding the high-level architecture of the Task Master CLI application, including the tagged task lists system
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/task-manager.js : task-manager.js should handle reading/writing tasks.json with tagged task lists support, implement CRUD operations, delegate AI interactions to ai-services-unified.js layer, and access non-AI configuration via config-manager.js getters
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use consistent properties for subtasks (id, title, description, status, dependencies, details) without duplicating parent task properties, maintaining simple numeric IDs unique within the parent task
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs, using numeric IDs for direct task references and string IDs with dot notation (e.g., '1.2') for subtask references
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent and convert between formats appropriately when needed, avoiding circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Support both task and subtask dependencies in cycle detection
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Do not create circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Use string IDs with dot notation (e.g., "1.2") for subtask references
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Remove references to non-existent tasks during validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks and self-references during cleanup, tracking and reporting changes made during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Detect circular dependencies using DFS and validate task references before operations
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Respect dependency chains and task priorities when selecting work
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Core task functions must accept a context parameter with `{ projectRoot, tag }` properties
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/*/[!.]* : Every CLI command that operates on tasks must include a `--tag <tag>` CLI option
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-31T21:48:00.389Z
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to mcp-server/src/core/direct-functions/*.js : In MCP direct functions, support explicit tag specification and use tag resolution for task data operations; default to current tag when not specified
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Implement reusable task finding utilities that support both task and subtask lookups and add context to subtask results
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:47.030Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-11-24T17:58:47.030Z
Learning: Applies to scripts/modules/commands.js : Follow the add-subtask command structure with proper options: --parent (required), --task-id, --title, --description, --details, --dependencies, --status, and --generate, with comprehensive parameter validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Follow the provided structure for adding subtasks, including required options and detailed error handling.
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Select tasks based on dependencies (all marked 'done'), priority level, and ID order
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:00:32.617Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to taskmaster.mdc for comprehensive reference of Taskmaster MCP tools and CLI commands with tagged task lists information
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/commands.js : In CLI commands, use specified tag context or default to current tag; call appropriate core functions with options including targetTag and outputFormat parameters
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Use `readJSON(tasksPath, projectRoot, tag)` and `writeJSON(tasksPath, data, projectRoot, tag)` for all task data access
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Calculate and display task completion statistics for the current tag context including total tasks, completed tasks, completion percentage, and subtask completion counts using visual progress indicators
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/ui.js : ui.js should handle CLI output formatting including tables, colors, boxes, spinners, and display tasks, reports, progress, suggestions, and migration notices
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Follow the standard display pattern for UI functions: use documented JSDoc comments describing the function's purpose, parameters, and display a task object with consistent formatting using boxen and chalk
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Provide next step suggestions after command completion using a consistent format with a boxen container displaying suggested commands using chalk formatting
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:00.056Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/context_gathering.mdc:0-0
Timestamp: 2025-11-24T17:59:00.056Z
Learning: Applies to scripts/**/*.js : Display token breakdown using `boxen` library with sections for tasks, files, and prompts, showing formatted token counts and file sizes in a clean bordered box with title
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:49.782Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/telemetry.mdc:0-0
Timestamp: 2025-11-24T18:02:49.782Z
Learning: Applies to scripts/modules/task-manager/**/*.js : Core logic functions with outputFormat parameter must check if outputFormat === 'text' and call displayAiUsageSummary(aiServiceResponse.telemetryData, 'cli') from scripts/modules/ui.js when applicable
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Generate appropriate numbers of subtasks based on task complexity analysis, using recommended subtask counts from complexity analysis when available instead of always using default counts
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Use boxen for important success messages with clear formatting, provide suggested next steps after command completion, and include ready-to-use commands for follow-up actions.
Applied to files:
apps/cli/src/commands/list.command.ts
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
- GitHub Check: Test
- GitHub Check: Cursor Bugbot
🔇 Additional comments (5)
apps/cli/src/commands/list.command.ts (5)
53-66: LGTM!The new options and type definitions are well-structured.
TaskWithBlocksandTaskWithTagclearly model the enriched task data for cross-tag listing scenarios.
121-129: LGTM!The new CLI options are clearly documented with helpful descriptions.
623-668: LGTM!The display logic correctly suppresses dashboards and next-task recommendations when filtering by
--ready,--blocking, or--all-tags, preventing misleading statistics. The task table properly shows blocks and tag columns in the appropriate contexts.
691-702: Good reference implementation for subtask handling.This method correctly includes subtask IDs in
completedIdsusing the format${parentId}.${subtaskId}. This is the pattern that should be applied infilterReadyTasksto fix the subtask dependency bug.
307-322: The status filter deferral logic is correct, but cross-tag dependencies are not visible with--tag --ready.The tag filter (line 319) remains active even when
needsAllTasksis true. When a task in the current tag depends on a completed task in a different tag, that dependency won't be satisfied because only the current tag's completed tasks are included in the ready filter computation.While
--all-tags --readyresolves this by fetching across all tags, users combining--tag feature-a --readymay encounter tasks that appear blocked even though their dependencies are satisfied elsewhere. Consider documenting this limitation.
| private async getTasksFromAllTags( | ||
| options: ListCommandOptions | ||
| ): Promise<ListTasksResult> { | ||
| if (!this.tmCore) { | ||
| throw new Error('TmCore not initialized'); | ||
| } | ||
|
|
||
| // Get all tags | ||
| const tagsResult = await this.tmCore.tasks.getTagsWithStats(); | ||
| const allTaggedTasks: TaskWithTag[] = []; | ||
|
|
||
| // Fetch tasks from each tag | ||
| for (const tagInfo of tagsResult.tags) { | ||
| const tagName = tagInfo.name; | ||
|
|
||
| // Get tasks for this tag | ||
| const result = await this.tmCore.tasks.list({ | ||
| tag: tagName, | ||
| includeSubtasks: options.withSubtasks | ||
| }); | ||
|
|
||
| // Build blocks map for this tag's tasks | ||
| const blocksMap = this.buildBlocksMap(result.tasks); | ||
|
|
||
| // Enrich tasks with blocks field and tag name | ||
| const enrichedTasks: TaskWithTag[] = result.tasks.map((task) => ({ | ||
| ...task, | ||
| blocks: blocksMap.get(String(task.id)) || [], | ||
| tagName | ||
| })); | ||
|
|
||
| // Apply ready filter only if --ready is specified | ||
| // Cast is safe because filterReadyTasks preserves all properties | ||
| const tasksToAdd: TaskWithTag[] = options.ready | ||
| ? (this.filterReadyTasks(enrichedTasks) as TaskWithTag[]) | ||
| : enrichedTasks; | ||
|
|
||
| allTaggedTasks.push(...tasksToAdd); | ||
| } | ||
|
|
||
| // Apply additional filters if specified | ||
| let filteredTasks: TaskWithTag[] = allTaggedTasks; | ||
|
|
||
| if (options.blocking) { | ||
| filteredTasks = filteredTasks.filter((task) => task.blocks.length > 0); | ||
| } | ||
|
|
||
| // Apply status filter if specified | ||
| if (options.status && options.status !== 'all') { | ||
| const statusValues = options.status | ||
| .split(',') | ||
| .map((s) => s.trim() as TaskStatus); | ||
| filteredTasks = filteredTasks.filter((task) => | ||
| statusValues.includes(task.status) | ||
| ); | ||
| } | ||
|
|
||
| return { | ||
| tasks: filteredTasks, | ||
| total: allTaggedTasks.length, | ||
| filtered: filteredTasks.length, | ||
| storageType: this.tmCore.tasks.getStorageType(), | ||
| allTags: true | ||
| }; | ||
| } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix blocks computation to include cross-tag relationships.
Lines 381-382 compute the blocks map per-tag, which misses cross-tag blocking relationships. If task A in feature-a depends on task B in master, task B's blocks field won't include A.
This breaks the --all-tags --blocking filter, which is intended to show tasks that block others across all tags. The blocks map must be built from all tasks across all tags, not per-tag.
🔎 Proposed fix
Collect all tasks first, then build the blocks map once:
private async getTasksFromAllTags(
options: ListCommandOptions
): Promise<ListTasksResult> {
if (!this.tmCore) {
throw new Error('TmCore not initialized');
}
// Get all tags
const tagsResult = await this.tmCore.tasks.getTagsWithStats();
- const allTaggedTasks: TaskWithTag[] = [];
+ const allTasks: Task[] = [];
+ const allTaggedTasks: TaskWithTag[] = [];
// Fetch tasks from each tag
for (const tagInfo of tagsResult.tags) {
const tagName = tagInfo.name;
// Get tasks for this tag
const result = await this.tmCore.tasks.list({
tag: tagName,
includeSubtasks: options.withSubtasks
});
-
- // Build blocks map for this tag's tasks
- const blocksMap = this.buildBlocksMap(result.tasks);
+
+ allTasks.push(...result.tasks);
+ }
+
+ // Build blocks map from ALL tasks to capture cross-tag blocking
+ const blocksMap = this.buildBlocksMap(allTasks);
+
+ // Now enrich tasks with blocks and tag name
+ for (const tagInfo of tagsResult.tags) {
+ const tagName = tagInfo.name;
+ const tagTasks = allTasks.filter(t => /* match by tag - needs tag field on Task */);
// Enrich tasks with blocks field and tag name
- const enrichedTasks: TaskWithTag[] = result.tasks.map((task) => ({
+ const enrichedTasks: TaskWithTag[] = tagTasks.map((task) => ({
...task,
blocks: blocksMap.get(String(task.id)) || [],
tagName
}));
// Apply ready filter only if --ready is specified
// Cast is safe because filterReadyTasks preserves all properties
const tasksToAdd: TaskWithTag[] = options.ready
? (this.filterReadyTasks(enrichedTasks) as TaskWithTag[])
: enrichedTasks;
allTaggedTasks.push(...tasksToAdd);
}Note: This fix requires tasks to have a tag field or another way to associate them with their tag after fetching. You may need to adjust based on the Task type structure.
Committable suggestion skipped: line range outside the PR's diff.
…gnment Addresses eyaltoledano#1532 - Add --ready filter: shows tasks with all dependencies satisfied - Add --blocking filter: shows tasks that block other tasks - Combine --ready --blocking for high-impact tasks (ready AND blocking) - Add Blocks column to task table (inverse of Dependencies) - Include blocks field in JSON output This enables teams to quickly identify: - What tasks can be started immediately (--ready) - What tasks unlock the most work (--blocking) - High-priority tasks for maximum throughput (--ready --blocking)
- Add TaskWithBlocks type and update ListTasksResult to use it - Fix bug where --ready filter failed when combined with --status by fetching all tasks first, then applying status filter after ready/blocking filters compute their results - Update filter method signatures to use TaskWithBlocks type - Format code
Tasks with deferred or blocked status are intentionally not actionable, so they should not appear when filtering for ready-to-work tasks. Only pending, in-progress, and review statuses are considered actionable.
- Add Ready column to tags list showing count of ready-to-work tasks - Ready = actionable status (pending/in-progress/review) + deps satisfied - Add unit tests for ready count calculation - Update changeset and PR description
Add --ready flag to 'tm tags list' that filters out tags with no ready tasks available, making it easier to find tags that have parallelizable work when managing multiple AI sessions. - Filter tags to only those with ready tasks (readyTasks > 0) - Update table rendering to use filtered list - Add 3 tests for --ready filter functionality - Update changeset with new feature
When filtering by --ready or --blocking, the dashboard statistics would show misleading numbers (based on filtered tasks instead of all tasks). Skip the dashboard display and suggested next steps when filters are applied, keeping the output focused on the filtered task table.
The options were only available on the 'tags list' subcommand but not on 'tags' directly. Now 'tm tags --ready' works as expected alongside 'tm tags list --ready'.
- Add --all-tags option that fetches and displays tasks from all tags - Tag column shown as first column when using --all-tags for easy scanning - Works with --ready to show all actionable tasks across the project - Supports --json output with tagName field for each task - Compact output shows tag prefix for each task - Update changeset with new feature
- Fix --all-tags to only apply ready filter when --ready is specified - Update help text to clarify --all-tags can be used without --ready - Fix Biome formatting errors and import sorting
ed1c3b4 to
b4c7e83
Compare
- Fix column widths for --all-tags display (Tag wider, Title visible) - Add validation to prevent --all-tags with --watch mode - Improve help text formatting
Track total task count before applying ready/blocking filters, matching the behavior of getTasks. This ensures the 'total' field always represents all tasks before filtering in both methods.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
Caution
Some comments are outside the diff and can’t be posted inline due to platform limitations.
⚠️ Outside diff range comments (1)
apps/cli/src/commands/list.command.ts (1)
329-333: The--readyfilter has a legitimate limitation with cross-tag dependencies.When
--readyis used without--all-tags, tasks are fetched from a single tag (line 330). If a task has a dependency on another task from a different tag, that dependency won't be included in the fetched results, so it won't appear incompletedIds(lines 479-484). This causes the task to incorrectly show as "not ready" even if its cross-tag dependency is complete.This is an edge case rooted in a design inconsistency: the move command documentation states "dependencies are only within tags" (move-task.js:746), yet add-task.js allows creating cross-tag dependencies by validating against
getAllTasks(). To address this properly, either:
- Prevent cross-tag dependencies entirely at creation time in add-task.js, or
- Update the
--readyfilter to fetch all tasks when needed to resolve cross-tag dependenciesFor now, users should use
tm list --ready --all-tagsto correctly handle ready filtering across tags.
♻️ Duplicate comments (2)
apps/cli/src/commands/list.command.ts (2)
396-404: Cross-tag blocking relationships not captured in blocks map.The
blocksMapis built per-tag (line 397), so cross-tag dependencies aren't reflected in theblocksfield. If task A infeature-adepends on task B inmaster, task B'sblocksarray won't include A.This affects
--all-tags --blockingaccuracy. Consider building the blocks map from all collected tasks after the loop completes.🔎 Suggested approach
private async getTasksFromAllTags( options: ListCommandOptions ): Promise<ListTasksResult> { // ... const tagsResult = await this.tmCore.tasks.getTagsWithStats(); - const allTaggedTasks: TaskWithTag[] = []; + const allRawTasks: Array<Task & { tagName: string }> = []; let totalTaskCount = 0; for (const tagInfo of tagsResult.tags) { const tagName = tagInfo.name; const result = await this.tmCore.tasks.list({ tag: tagName, includeSubtasks: options.withSubtasks }); totalTaskCount += result.tasks.length; - const blocksMap = this.buildBlocksMap(result.tasks); - const enrichedTasks: TaskWithTag[] = result.tasks.map((task) => ({ - ...task, - blocks: blocksMap.get(String(task.id)) || [], - tagName - })); - allTaggedTasks.push(...enrichedTasks); + allRawTasks.push(...result.tasks.map(t => ({ ...t, tagName }))); } + // Build blocks map from ALL tasks to capture cross-tag relationships + const blocksMap = this.buildBlocksMap(allRawTasks); + const allTaggedTasks: TaskWithTag[] = allRawTasks.map((task) => ({ + ...task, + blocks: blocksMap.get(String(task.id)) || [] + })); // ... rest of filtering
478-500: Subtask dependencies not recognized in ready filter.The
completedIdsset only includes top-level task IDs (lines 480-484), but tasks can depend on subtasks (e.g.,"1.1"). Compare withfindNextTask(lines 706-718) which correctly includes subtask IDs using${t.id}.${st.id}format.Tasks depending on completed subtasks will incorrectly appear as "not ready."
🔎 Suggested fix to include subtask IDs
const completedIds = new Set<string>(); tasks.forEach((t) => { if (isTaskComplete(t.status)) { completedIds.add(String(t.id)); } + // Also track completed subtasks + if (t.subtasks) { + t.subtasks.forEach((st) => { + if (isTaskComplete(st.status as TaskStatus)) { + completedIds.add(`${t.id}.${st.id}`); + } + }); + } });
🧹 Nitpick comments (1)
apps/cli/src/commands/list.command.ts (1)
584-588: Consider type narrowing instead ofas anyassertion.The
(task as any).tagNameworks correctly but loses type safety. SinceallTagsimpliestasksisTaskWithTag[], consider narrowing the type:const taggedTasks = tasks as TaskWithTag[]; taggedTasks.forEach((task) => { const tagPrefix = allTags ? chalk.magenta(`[${task.tagName}] `) : ''; // ... });This is a minor improvement for type safety.
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
apps/cli/src/commands/list.command.ts
🧰 Additional context used
📓 Path-based instructions (4)
**/*.ts
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
TypeScript test files must achieve minimum code coverage thresholds: 80% lines/functions and 70% branches globally, 90% for utilities, and 85% for middleware; new features must meet or exceed these thresholds
Files:
apps/cli/src/commands/list.command.ts
**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
**/*.{js,ts}: Import and use specific getters from config-manager.js (e.g., getMainProvider(), getLogLevel(), getMainMaxTokens()) to access configuration values needed for application logic
Use isApiKeySet(providerName, session) from config-manager.js to check if a provider's key is available before potentially attempting an AI call
Do not add direct console.log calls outside the logging utility - use the central log function instead
Ensure silent mode is disabled in a finally block to prevent it from staying enabled
Do not access the global silentMode variable directly - use the exported silent mode control functions instead
Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Use ContextGatherer class from utils/contextGatherer.js for AI-powered commands that need project context, supporting tasks, files, custom text, and project tree context
Use FuzzyTaskSearch class from utils/fuzzyTaskSearch.js for automatic task relevance detection with configurable search parameters
Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Do not replace explicit user task selections with fuzzy results - fuzzy search should supplement, not replace user selections
Use readJSON and writeJSON utilities for all JSON file operations instead of raw fs.readFileSync or fs.writeFileSync
Include error handling for JSON file operations and validate JSON structure after reading
Use path.join() for cross-platform path construction and path.resolve() for absolute paths, validating paths before file operations
Support both .env files and MCP session environment for environment variable resolution with fallbacks for missing values
Prefer updating the core function to accept an outputFormat parameter and check outputFormat === 'json' before displaying UI elements
Files:
apps/cli/src/commands/list.command.ts
**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Import modules with
.jsextension even in TypeScript source files for ESM compatibility
Files:
apps/cli/src/commands/list.command.ts
apps/cli/src/**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
CLI (@tm/cli) should be a thin presentation layer that calls tm-core methods and displays results; handle only CLI-specific concerns like argument parsing, output formatting, and user prompts
Files:
apps/cli/src/commands/list.command.ts
🧠 Learnings (52)
📓 Common learnings
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/git_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:23.032Z
Learning: Leverage Task Master's tagged task lists system for multi-context development: branch-specific tasks, merge conflict prevention through task isolation, context switching between development contexts, and parallel development by different team members.
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to new_features.mdc for guidelines on integrating new features into the Task Master CLI with tagged system considerations
Learnt from: eyaltoledano
Repo: eyaltoledano/claude-task-master PR: 1069
File: .changeset/floppy-news-buy.md:7-38
Timestamp: 2025-08-02T14:54:52.216Z
Learning: For major feature additions like new CLI commands, eyaltoledano prefers detailed changesets with comprehensive descriptions, usage examples, and feature explanations rather than minimal single-line summaries.
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: The tasks.json file should use a tagged task lists structure with multiple named task lists as top-level keys (e.g., {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}}), supporting backward compatibility through silent migration from legacy {"tasks": [...]} format
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to tasks.json : Organize tasks into separate contexts (tags) within tasks.json using tagged format: {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}} instead of legacy format {"tasks": [...]}
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/*/[!.]* : Every CLI command that operates on tasks must include a `--tag <tag>` CLI option
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/task-manager.js : task-manager.js should handle reading/writing tasks.json with tagged task lists support, implement CRUD operations, delegate AI interactions to ai-services-unified.js layer, and access non-AI configuration via config-manager.js getters
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use consistent properties for subtasks (id, title, description, status, dependencies, details) without duplicating parent task properties, maintaining simple numeric IDs unique within the parent task
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs, using numeric IDs for direct task references and string IDs with dot notation (e.g., '1.2') for subtask references
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent and convert between formats appropriately when needed, avoiding circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Support both task and subtask dependencies in cycle detection
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Do not create circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Use string IDs with dot notation (e.g., "1.2") for subtask references
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Remove references to non-existent tasks during validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks and self-references during cleanup, tracking and reporting changes made during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Detect circular dependencies using DFS and validate task references before operations
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Respect dependency chains and task priorities when selecting work
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Core task functions must accept a context parameter with `{ projectRoot, tag }` properties
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-31T21:48:00.389Z
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to mcp-server/src/core/direct-functions/*.js : In MCP direct functions, support explicit tag specification and use tag resolution for task data operations; default to current tag when not specified
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement silent migration for tasks.json files that transforms old format to tagged format, marking global flag and performing complete migration
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Implement reusable task finding utilities that support both task and subtask lookups and add context to subtask results
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:47.030Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-11-24T17:58:47.030Z
Learning: Applies to scripts/modules/commands.js : Follow the add-subtask command structure with proper options: --parent (required), --task-id, --title, --description, --details, --dependencies, --status, and --generate, with comprehensive parameter validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Follow the provided structure for adding subtasks, including required options and detailed error handling.
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Select tasks based on dependencies (all marked 'done'), priority level, and ID order
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:00:32.617Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to taskmaster.mdc for comprehensive reference of Taskmaster MCP tools and CLI commands with tagged task lists information
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:00:32.617Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to architecture.mdc for understanding the high-level architecture of the Task Master CLI application, including the tagged task lists system
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/commands.js : In CLI commands, use specified tag context or default to current tag; call appropriate core functions with options including targetTag and outputFormat parameters
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Use `readJSON(tasksPath, projectRoot, tag)` and `writeJSON(tasksPath, data, projectRoot, tag)` for all task data access
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Calculate and display task completion statistics for the current tag context including total tasks, completed tasks, completion percentage, and subtask completion counts using visual progress indicators
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/ui.js : ui.js should handle CLI output formatting including tables, colors, boxes, spinners, and display tasks, reports, progress, suggestions, and migration notices
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Follow the standard display pattern for UI functions: use documented JSDoc comments describing the function's purpose, parameters, and display a task object with consistent formatting using boxen and chalk
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Provide next step suggestions after command completion using a consistent format with a boxen container displaying suggested commands using chalk formatting
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:00.056Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/context_gathering.mdc:0-0
Timestamp: 2025-11-24T17:59:00.056Z
Learning: Applies to scripts/**/*.js : Display token breakdown using `boxen` library with sections for tasks, files, and prompts, showing formatted token counts and file sizes in a clean bordered box with title
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:49.782Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/telemetry.mdc:0-0
Timestamp: 2025-11-24T18:02:49.782Z
Learning: Applies to scripts/modules/task-manager/**/*.js : Core logic functions with outputFormat parameter must check if outputFormat === 'text' and call displayAiUsageSummary(aiServiceResponse.telemetryData, 'cli') from scripts/modules/ui.js when applicable
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Generate appropriate numbers of subtasks based on task complexity analysis, using recommended subtask counts from complexity analysis when available instead of always using default counts
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Use boxen for important success messages with clear formatting, provide suggested next steps after command completion, and include ready-to-use commands for follow-up actions.
Applied to files:
apps/cli/src/commands/list.command.ts
🧬 Code graph analysis (1)
apps/cli/src/commands/list.command.ts (6)
packages/tm-core/src/common/types/index.ts (2)
Task(131-159)TaskStatus(20-28)scripts/modules/task-manager/tag-management.js (1)
actionableStatuses(638-638)packages/tm-core/src/common/constants/index.ts (1)
isTaskComplete(68-70)apps/cli/src/utils/display-helpers.ts (1)
displayCommandHeader(14-43)apps/cli/src/ui/components/dashboard.component.ts (1)
displayDashboards(517-594)apps/cli/src/ui/components/next-task.component.ts (1)
getTaskDescription(133-149)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
- GitHub Check: Test
- GitHub Check: Cursor Bugbot
🔇 Additional comments (8)
apps/cli/src/commands/list.command.ts (8)
58-66: LGTM! Clean type definitions for enriched task data.The type hierarchy with
TaskWithBlocksandTaskWithTagextending it is well-structured and aligns with the feature requirements.
71-78: LGTM! Result interface properly extended for cross-tag support.The union type and
allTagsflag provide clear semantics for downstream consumers.
121-129: LGTM! Clear option definitions with helpful descriptions.The help text for
--all-tagsappropriately suggests combining with--readyfor actionable tasks.
279-288: Good validation preventing incompatible option combination.Clear error message with actionable guidance for users. This properly addresses the case where
--all-tagswould otherwise be silently ignored in watch mode.
444-465: LGTM! Clean inverse dependency graph construction.The implementation correctly inverts the dependency relationships to build the blocks map.
506-508: LGTM! Simple and correct blocking filter.
545-562: LGTM! JSON output properly reflects cross-tag context.The metadata correctly indicates when all tags are being listed.
638-649: Good UX: Dashboard and recommendations hidden for filtered views.Hiding dashboard statistics and next-task recommendations when using
--ready,--blocking, or--all-tagsprevents showing misleading aggregate data. The filtered task list is self-explanatory in these contexts.
Apply the ready filter within each tag's loop iteration to respect tag-scoped dependencies. Task IDs may overlap between tags, so filtering globally would incorrectly consider a task ready if its dependency happens to be complete in a different tag.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
♻️ Duplicate comments (1)
apps/cli/src/commands/list.command.ts (1)
479-485: Subtask IDs not included in completedIds, breaking subtask dependency checks.The
completedIdsset only includes top-level task IDs (line 483), but dependencies can reference subtasks using dot notation (e.g.,"2.1"). Tasks depending on completed subtasks will incorrectly be excluded from--readyresults because their subtask dependencies won't be found incompletedIds.Compare with
findNextTask(lines 712-716) which correctly handles subtask IDs:if (t.subtasks) { t.subtasks.forEach((st) => { if (isTaskComplete(st.status as TaskStatus)) { completedIds.add(`${t.id}.${st.id}`); } }); }🔎 Proposed fix
// Build set of completed task IDs const completedIds = new Set<string>(); tasks.forEach((t) => { if (isTaskComplete(t.status)) { completedIds.add(String(t.id)); } + // Also add completed subtask IDs for subtask dependency resolution + if (t.subtasks) { + t.subtasks.forEach((st) => { + if (isTaskComplete(st.status as TaskStatus)) { + completedIds.add(`${t.id}.${st.id}`); + } + }); + } });
🧹 Nitpick comments (1)
apps/cli/src/commands/list.command.ts (1)
582-589: Consider type-safe access fortagName.The
(task as any).tagNamecast works correctly but bypasses type checking. SinceallTagsis already checked, you could use a type guard or narrow the type:🔎 Type-safe alternative
- const tagPrefix = - allTags && (task as any).tagName - ? chalk.magenta(`[${(task as any).tagName}] `) - : ''; + const tagPrefix = + allTags && 'tagName' in task + ? chalk.magenta(`[${(task as TaskWithTag).tagName}] `) + : '';
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
apps/cli/src/commands/list.command.ts
🧰 Additional context used
📓 Path-based instructions (4)
**/*.ts
📄 CodeRabbit inference engine (.cursor/rules/test_workflow.mdc)
TypeScript test files must achieve minimum code coverage thresholds: 80% lines/functions and 70% branches globally, 90% for utilities, and 85% for middleware; new features must meet or exceed these thresholds
Files:
apps/cli/src/commands/list.command.ts
**/*.{js,ts}
📄 CodeRabbit inference engine (.cursor/rules/utilities.mdc)
**/*.{js,ts}: Import and use specific getters from config-manager.js (e.g., getMainProvider(), getLogLevel(), getMainMaxTokens()) to access configuration values needed for application logic
Use isApiKeySet(providerName, session) from config-manager.js to check if a provider's key is available before potentially attempting an AI call
Do not add direct console.log calls outside the logging utility - use the central log function instead
Ensure silent mode is disabled in a finally block to prevent it from staying enabled
Do not access the global silentMode variable directly - use the exported silent mode control functions instead
Do not duplicate task ID formatting logic across modules - centralize formatting utilities
Use ContextGatherer class from utils/contextGatherer.js for AI-powered commands that need project context, supporting tasks, files, custom text, and project tree context
Use FuzzyTaskSearch class from utils/fuzzyTaskSearch.js for automatic task relevance detection with configurable search parameters
Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Do not replace explicit user task selections with fuzzy results - fuzzy search should supplement, not replace user selections
Use readJSON and writeJSON utilities for all JSON file operations instead of raw fs.readFileSync or fs.writeFileSync
Include error handling for JSON file operations and validate JSON structure after reading
Use path.join() for cross-platform path construction and path.resolve() for absolute paths, validating paths before file operations
Support both .env files and MCP session environment for environment variable resolution with fallbacks for missing values
Prefer updating the core function to accept an outputFormat parameter and check outputFormat === 'json' before displaying UI elements
Files:
apps/cli/src/commands/list.command.ts
**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
Import modules with
.jsextension even in TypeScript source files for ESM compatibility
Files:
apps/cli/src/commands/list.command.ts
apps/cli/src/**/*.{ts,tsx}
📄 CodeRabbit inference engine (CLAUDE.md)
CLI (@tm/cli) should be a thin presentation layer that calls tm-core methods and displays results; handle only CLI-specific concerns like argument parsing, output formatting, and user prompts
Files:
apps/cli/src/commands/list.command.ts
🧠 Learnings (52)
📓 Common learnings
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/git_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:23.032Z
Learning: Leverage Task Master's tagged task lists system for multi-context development: branch-specific tasks, merge conflict prevention through task isolation, context switching between development contexts, and parallel development by different team members.
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/*/[!.]* : Every CLI command that operates on tasks must include a `--tag <tag>` CLI option
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: The tasks.json file should use a tagged task lists structure with multiple named task lists as top-level keys (e.g., {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}}), supporting backward compatibility through silent migration from legacy {"tasks": [...]} format
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to tasks.json : Organize tasks into separate contexts (tags) within tasks.json using tagged format: {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}} instead of legacy format {"tasks": [...]}
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:00:32.617Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to architecture.mdc for understanding the high-level architecture of the Task Master CLI application, including the tagged task lists system
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/task-manager.js : task-manager.js should handle reading/writing tasks.json with tagged task lists support, implement CRUD operations, delegate AI interactions to ai-services-unified.js layer, and access non-AI configuration via config-manager.js getters
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/*.{js,ts} : Use fuzzy search to supplement user-provided task IDs and display discovered task IDs to users for transparency
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use consistent properties for subtasks (id, title, description, status, dependencies, details) without duplicating parent task properties, maintaining simple numeric IDs unique within the parent task
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs, using numeric IDs for direct task references and string IDs with dot notation (e.g., '1.2') for subtask references
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent and convert between formats appropriately when needed, avoiding circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Support both task and subtask dependencies in cycle detection
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Allow numeric subtask IDs to reference other subtasks within the same parent
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Do not create circular dependencies between subtasks
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Represent task dependencies as arrays of task IDs
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Use string IDs with dot notation (e.g., "1.2") for subtask references
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Format task and dependency IDs consistently, check for existing dependencies to prevent duplicates, and sort dependencies for better readability when adding dependencies
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Remove references to non-existent tasks during validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:09:40.548Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-07-18T17:09:40.548Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:18.662Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dependencies.mdc:0-0
Timestamp: 2025-11-24T17:59:18.662Z
Learning: Applies to scripts/modules/dependency-manager.js : Check for and remove references to non-existent tasks and self-references during cleanup, tracking and reporting changes made during cleanup
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Detect circular dependencies using DFS and validate task references before operations
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Respect dependency chains and task priorities when selecting work
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Core task functions must accept a context parameter with `{ projectRoot, tag }` properties
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/*/[!.]* : Every CLI command that operates on tasks must include a `--tag <tag>` CLI option
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-31T21:48:00.389Z
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to mcp-server/src/core/direct-functions/*.js : In MCP direct functions, support explicit tag specification and use tag resolution for task data operations; default to current tag when not specified
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement silent migration for tasks.json files that transforms old format to tagged format, marking global flag and performing complete migration
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:43.972Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Implement reusable task finding utilities that support both task and subtask lookups and add context to subtask results
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:47.030Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-11-24T17:58:47.030Z
Learning: Applies to scripts/modules/commands.js : Follow the add-subtask command structure with proper options: --parent (required), --task-id, --title, --description, --details, --dependencies, --status, and --generate, with comprehensive parameter validation
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Follow the provided structure for adding subtasks, including required options and detailed error handling.
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Process large task lists efficiently; minimize file I/O operations per feature execution; cache tag resolution results when appropriate; avoid keeping all tag data in memory simultaneously
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:05:02.114Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: assets/.windsurfrules:0-0
Timestamp: 2025-11-24T18:05:02.114Z
Learning: Select tasks based on dependencies (all marked 'done'), priority level, and ID order
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:00:32.617Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to taskmaster.mdc for comprehensive reference of Taskmaster MCP tools and CLI commands with tagged task lists information
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:01:44.169Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/commands.js : In CLI commands, use specified tag context or default to current tag; call appropriate core functions with options including targetTag and outputFormat parameters
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:04.644Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Applies to scripts/modules/task-manager/**/*.{js,mjs} : Use `readJSON(tasksPath, projectRoot, tag)` and `writeJSON(tasksPath, data, projectRoot, tag)` for all task data access
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Calculate and display task completion statistics for the current tag context including total tasks, completed tasks, completion percentage, and subtask completion counts using visual progress indicators
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:58:07.992Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/ui.js : ui.js should handle CLI output formatting including tables, colors, boxes, spinners, and display tasks, reports, progress, suggestions, and migration notices
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Follow the standard display pattern for UI functions: use documented JSDoc comments describing the function's purpose, parameters, and display a task object with consistent formatting using boxen and chalk
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:04:01.629Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/ui.mdc:0-0
Timestamp: 2025-11-24T18:04:01.629Z
Learning: Applies to scripts/modules/ui.js : Provide next step suggestions after command completion using a consistent format with a boxen container displaying suggested commands using chalk formatting
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T17:59:00.056Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/context_gathering.mdc:0-0
Timestamp: 2025-11-24T17:59:00.056Z
Learning: Applies to scripts/**/*.js : Display token breakdown using `boxen` library with sections for tasks, files, and prompts, showing formatted token counts and file sizes in a clean bordered box with title
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:49.782Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/telemetry.mdc:0-0
Timestamp: 2025-11-24T18:02:49.782Z
Learning: Applies to scripts/modules/task-manager/**/*.js : Core logic functions with outputFormat parameter must check if outputFormat === 'text' and call displayAiUsageSummary(aiServiceResponse.telemetryData, 'cli') from scripts/modules/ui.js when applicable
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-11-24T18:02:36.388Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Generate appropriate numbers of subtasks based on task complexity analysis, using recommended subtask counts from complexity analysis when available instead of always using default counts
Applied to files:
apps/cli/src/commands/list.command.ts
📚 Learning: 2025-07-18T17:08:48.695Z
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/commands.mdc:0-0
Timestamp: 2025-07-18T17:08:48.695Z
Learning: Applies to scripts/modules/commands.js : Use boxen for important success messages with clear formatting, provide suggested next steps after command completion, and include ready-to-use commands for follow-up actions.
Applied to files:
apps/cli/src/commands/list.command.ts
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
- GitHub Check: Test
- GitHub Check: Cursor Bugbot
🔇 Additional comments (9)
apps/cli/src/commands/list.command.ts (9)
53-77: LGTM! Well-structured type definitions.The new types
TaskWithBlocksandTaskWithTagproperly extend the baseTasktype, and the union type inListTasksResultcorrectly handles both single-tag and cross-tag listing scenarios.
121-129: LGTM! Clear option descriptions.The new CLI options are well-documented and follow the existing option pattern.
168-171: LGTM! Clean routing logic.The conditional routing to
getTasksFromAllTagsvsgetTasksis straightforward and correctly gated by theallTagsoption.
279-288: Good addition of explicit validation.This properly prevents the
--all-tagswith--watchcombination that would otherwise silently ignore--all-tags, providing clear user guidance.
312-365: Correctly defers status filter for ready/blocking computation.The logic properly fetches all tasks before applying ready/blocking filters, then applies the status filter afterward. This addresses the concern about status filtering interfering with dependency satisfaction checks.
Note: The tag filter remains applied, which is consistent with the tagged task lists design where dependencies are scoped per-tag. Based on learnings, every task exists within a tag context and dependencies are represented within that context.
445-466: LGTM! Correct dependency graph inversion.The method correctly builds the inverse mapping from dependencies to blocking relationships.
507-509: LGTM! Simple and correct filter.The blocking filter correctly identifies tasks that have dependent tasks.
546-562: LGTM! JSON metadata correctly reflects cross-tag state.The metadata includes
allTagsflag and uses'all'as the tag value for cross-tag listings.
639-684: Good UX decisions for filtered views.Suppressing the dashboard, next task recommendation, and suggested steps when filtering by
--ready,--blocking, or--all-tagsprevents displaying misleading statistics and redundant suggestions. TheshowBlocksandshowTagtable options are correctly set based on context.
| // Build blocks map for this tag's tasks | ||
| const blocksMap = this.buildBlocksMap(result.tasks); | ||
|
|
||
| // Enrich tasks with blocks field and tag name | ||
| const enrichedTasks: TaskWithTag[] = result.tasks.map((task) => ({ | ||
| ...task, | ||
| blocks: blocksMap.get(String(task.id)) || [], | ||
| tagName | ||
| })); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Cross-tag blocking relationships not captured in blocks map.
The blocksMap is built per-tag (line 397), which means tasks that block tasks in other tags won't show those blocking relationships. For example, if task 5 in feature depends on task 3 in master, task 3's blocks array won't include task 5.
This affects --all-tags --blocking results, which will only show tasks blocking within their own tag.
🔎 Suggested approach
Build a unified blocks map from all tasks across all tags before enrichment:
private async getTasksFromAllTags(
options: ListCommandOptions
): Promise<ListTasksResult> {
// ... existing code ...
const tagsResult = await this.tmCore.tasks.getTagsWithStats();
+ const allTasks: Array<Task & { tagName: string }> = [];
- const allTaggedTasks: TaskWithTag[] = [];
let totalTaskCount = 0;
// First pass: collect all tasks
for (const tagInfo of tagsResult.tags) {
const result = await this.tmCore.tasks.list({
tag: tagInfo.name,
includeSubtasks: options.withSubtasks
});
totalTaskCount += result.tasks.length;
+ result.tasks.forEach(t => allTasks.push({ ...t, tagName: tagInfo.name }));
- // ... per-tag processing ...
}
+ // Build unified blocks map from ALL tasks
+ const blocksMap = this.buildBlocksMap(allTasks);
+
+ // Enrich all tasks with blocks
+ const enrichedTasks: TaskWithTag[] = allTasks.map(task => ({
+ ...task,
+ blocks: blocksMap.get(String(task.id)) || []
+ }));
+
+ // Apply ready filter per-tag to respect tag-scoped dependencies
+ // Group by tag, filter, then flatten
+ // ...Committable suggestion skipped: line range outside the PR's diff.
🤖 Prompt for AI Agents
In apps/cli/src/commands/list.command.ts around lines 396 to 404, the blocksMap
is currently built only from result.tasks for the current tag so cross-tag
blocking relationships are missed; instead gather all tasks from all tag results
(flatten the results into a single tasks array), call this.buildBlocksMap once
on that unified tasks array to create a global blocksMap, and then when
enriching each tag's tasks use blocksMap.get(String(task.id)) || [] so blocks
from other tags are included; ensure you still set tagName per task when
mapping.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The per-tag blocks map is intentional and correct for Task Master's data model.
Why cross-tag blocking doesn't apply:
- Task Master dependencies are tag-scoped - dependencies only reference task IDs within the same tag
- Each tag has its own isolated task namespace (task 1 in tag A is completely different from task 1 in tag B)
- There's no syntax or mechanism for a task in one tag to depend on a task in another tag
What building a unified blocks map would incorrectly do:
- If tag A has task 2 depending on task 1, and tag B has task 1 (unrelated), the unified map would incorrectly show tag B's task 1 as blocking tag A's task 2
- This creates false blocking relationships between tasks that have no actual dependency relationship
The current per-tag approach correctly reflects the actual dependency relationships that exist in the data.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bjcoombs, thank you for the clarification! You're absolutely right—I misunderstood the dependency model.
The per-tag blocks map is the correct implementation given that dependencies are tag-scoped. Building a unified map would indeed create false relationships between unrelated tasks that happen to share the same ID in different tags.
I appreciate you explaining the design rationale!
✏️ Learnings added
Learnt from: bjcoombs
Repo: eyaltoledano/claude-task-master PR: 1533
File: apps/cli/src/commands/list.command.ts:396-404
Timestamp: 2025-12-29T14:56:42.723Z
Learning: In Task Master, task dependencies are tag-scoped: dependencies only reference task IDs within the same tag context. Each tag has its own isolated task namespace, so task 1 in tag A is completely different from task 1 in tag B. There is no syntax or mechanism for a task in one tag to depend on a task in another tag.
Note: Learnings are effective only in the context of similar code segments. To apply general coding guidelines, please configure review instructions. You can manage existing learnings in the app.
🧠 Learnings used
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tags.mdc:0-0
Timestamp: 2025-11-24T18:02:04.644Z
Learning: Every command that reads or writes tasks.json must be tag-aware and support the tagged task lists system
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Filter and display tasks by status within the current tag context, handling subtask display in lists and using consistent table formats
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to scripts/modules/*.js : Design core logic to work with both legacy (flat tasks array) and tagged task data formats; use tag resolution functions (getTasksForTag, setTasksForTag) for task data access; support silent migration during feature usage
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to **/{utils,utilities}/**/*.{js,ts} : Implement reusable task finding utilities that support both task and subtask lookups and add context to subtask results
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement tag resolution functions (getTasksForTag, setTasksForTag, getCurrentTag) that provide backward compatibility with legacy format and default to master tag
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: The tasks.json file should use a tagged task lists structure with multiple named task lists as top-level keys (e.g., {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}}), supporting backward compatibility through silent migration from legacy {"tasks": [...]} format
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Format task files with consistent structure including task metadata (ID, title, status), dependencies with status indicators, and tag context information in the file header
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Implement status update functions that handle both individual tasks and subtasks within the current tag context, considering subtask status when updating parent tasks and suggesting parent task updates when all subtasks are done
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to tasks.json : Organize tasks into separate contexts (tags) within tasks.json using tagged format: {"master": {"tasks": [...]}, "feature-branch": {"tasks": [...]}} instead of legacy format {"tasks": [...]}
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Extract tasks from PRD documents using AI within the current tag context (defaulting to "master"), providing clear prompts to guide AI task generation and validating/cleaning up AI-generated tasks
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/tasks.mdc:0-0
Timestamp: 2025-11-24T18:02:36.388Z
Learning: Applies to scripts/modules/task-manager.js : Use tag resolution functions (getTasksForTag and setTasksForTag) in core task functions to maintain backward compatibility instead of directly manipulating the tagged structure
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/new_features.mdc:0-0
Timestamp: 2025-11-24T18:01:44.169Z
Learning: Applies to **/*.test.{js,ts} : Test new features with both legacy and tagged task data formats; verify tag resolution behavior; test migration compatibility; ensure pre-migration projects are handled correctly
Learnt from: mm-parthy
Repo: eyaltoledano/claude-task-master PR: 943
File: scripts/modules/ui.js:1211-1211
Timestamp: 2025-07-18T07:52:44.890Z
Learning: The boundary-first tag resolution pattern means that context validation in UI functions like displayTaskById is unnecessary because tag and projectRoot resolution happens at the CLI command boundary layer before reaching these functions.
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dev_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:06.827Z
Learning: Do not put detailed implementation subtasks, refactoring work, experimental features, or team member-specific tasks in the master tag
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/architecture.mdc:0-0
Timestamp: 2025-11-24T17:58:07.992Z
Learning: Applies to scripts/modules/dependency-manager.js : dependency-manager.js should manage task dependencies by handling add/remove/validate/fix operations across tagged task contexts
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to dependencies.mdc for guidelines on managing task dependencies and relationships across tagged task contexts
Learnt from: Crunchyman-ralph
Repo: eyaltoledano/claude-task-master PR: 997
File: apps/extension/src/services/task-repository.ts:25-57
Timestamp: 2025-07-31T21:48:00.389Z
Learning: In the eyaltoledano/claude-task-master repository, every task is always part of a tag - there is no concept of untagged tasks. The tag system is mandatory and comprehensive, meaning all tasks exist within a tag context (with 'master' as the default tag if none specified).
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/git_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:23.032Z
Learning: Leverage Task Master's tagged task lists system for multi-context development: branch-specific tasks, merge conflict prevention through task isolation, context switching between development contexts, and parallel development by different team members.
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/dev_workflow.mdc:0-0
Timestamp: 2025-11-24T18:00:06.827Z
Learning: When collaborating with teammates, create a separate task tag for the user's work to avoid conflicts (e.g., `task-master add-tag my-work --copy-from-current`)
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/utilities.mdc:0-0
Timestamp: 2025-11-24T18:04:43.972Z
Learning: Applies to scripts/modules/**/*.{js,ts} : Implement complete migration functions for tagged task lists that handle configuration, state file creation, and migration status tracking
Learnt from: CR
Repo: eyaltoledano/claude-task-master PR: 0
File: .cursor/rules/glossary.mdc:0-0
Timestamp: 2025-11-24T18:00:32.617Z
Learning: Refer to new_features.mdc for guidelines on integrating new features into the Task Master CLI with tagged system considerations
Learnt from: eyaltoledano
Repo: eyaltoledano/claude-task-master PR: 1069
File: .changeset/floppy-news-buy.md:7-38
Timestamp: 2025-08-02T14:54:52.216Z
Learning: For major feature additions like new CLI commands, eyaltoledano prefers detailed changesets with comprehensive descriptions, usage examples, and feature explanations rather than minimal single-line summaries.
Crunchyman-ralph
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice!
Make sure this is something that exists in tm-core, basically the tm-core is the "business logic" layer and apps/* are the thin interfaces (mcp, cli, etc..)
Lets make sure this also exists for mcp commands not just cli.
Also one more thing, make sure you are making your business logic changes inside tm-core but for both strategies: file-storage and api-storage.
If this is something that is not applicable in api-storage and only in file-storage you can simply implement an empty function inside api-storage or throw that this is not a function that exists in api-storage
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: move this to the same position as list.command.ts and make it a list.command.spec.ts that is right next to its source file
Summary
Addresses #1532
Adds filters to the
listcommand to identify tasks that can be worked on in parallel. Use case: running multiple AI sessions simultaneously and quickly seeing which tasks are independent and ready to start.--readyfilter shows only tasks with all dependencies satisfied--blockingfilter shows only tasks that block other tasks--ready --blockingto find high-impact tasks (ready AND blocking others)Also adds a "Blocks" column to show the inverse of dependencies, a "Ready" column to
tagscommand, and--readyfilter totagscommand.Example workflow
When running 3 AI sessions in parallel:
This complements
task-master nextby showing ALL available parallel work, not just the single next task.Changes Made
New Command Options
New Table Columns
List command - Added "Blocks" column showing which tasks depend on each task:
Tags command - Added "Ready" column showing count of ready tasks:
JSON Output
Blocks field included in JSON output:
{ "tasks": [{ "id": "1", "title": "Setup infrastructure", "blocks": ["2", "3", "4"], ... }] }Ready Task Logic
Tasks are "ready" if they:
pending,in-progress,review)Excluded from ready:
done,cancelled- already finisheddeferred- intentionally postponedblocked- waiting on external factorsTechnical Details
buildBlocksMap(): Inverts the dependency graphfilterReadyTasks(): Filters to tasks with satisfied deps and actionable statusfilterBlockingTasks(): Filters to tasks that appear in other tasks' dependenciesTesting
Test plan
task-master list --ready- should show only tasks with deps satisfiedtask-master list --blocking- should show only tasks that block otherstask-master list --ready --blocking- should show intersection--json)task-master tags- should show Ready column with countstask-master tags --ready- should filter out tags with no ready tasksSummary by CodeRabbit
New Features
Tests
✏️ Tip: You can customize this high-level summary in your review settings.
Note
Adds filtering and visibility to identify parallelizable work and dependencies across tags.
apps/cli/src/commands/list.command.ts: adds--ready,--blocking, and--all-tags; computes inverse dependencies viabuildBlocksMapand enriches tasks withblocks; supports cross-tag listing (withtagName), defers status filtering when needed; validates--all-tagscannot combine with--watch; hides dashboards when filtered; JSON metadata includesallTagsandtag: "all"when applicableapps/cli/src/ui/display/tables.ts: task table gains optionalBlocksandTagcolumns; grays out blocks for completed tasks; layout adapts to optional columnsapps/cli/src/commands/tags.command.tsandscripts/modules/task-manager/tag-management.js: adds--readyfilter andReadycolumn; counts ready tasks (actionable statuses with satisfied deps); filters tags when--readyis set.changeset/list-blocks-ready-filter.mdWritten by Cursor Bugbot for commit f837091. This will update automatically on new commits. Configure here.