Module tasks

Module tasks 

Source
Expand description

Task models and task list parsing. Task domain models, parsing, update helpers, and repository ports.

This module implements the core logic for Ito’s task tracking system, which supports two formats:

  • Enhanced: Structured markdown with waves, dependencies, and metadata.
  • Checkbox: Legacy simple checklist format.

Key components:

Structs§

ProgressInfo
Common task domain types. Summary counts computed from the parsed tasks.
TaskDiagnostic
Common task domain types. A parse-time diagnostic emitted while reading a tasks file.
TaskItem
Common task domain types. A normalized task entry parsed from a tasks tracking file.
TasksParseResult
Parsed task tracking result. Output of parsing a tasks.md file.
WaveInfo
Parsed wave metadata from enhanced format. Wave metadata parsed from enhanced tasks files.

Enums§

DiagnosticLevel
Common task domain types. Diagnostic severity.
TaskKind
Common task domain types. Task classification.
TaskStatus
Common task domain types. Status values supported by Ito task tracking.
TasksFormat
Common task domain types. The detected format of a tasks.md file.

Traits§

TaskRepository
Repository port for loading and querying task data. Port for accessing task data.

Functions§

compute_ready_and_blocked
Compute ready vs blocked tasks for a parsed tracking file. Compute ready tasks and blocked tasks (with reasons) from a parsed tasks file.
detect_tasks_format
Detect whether a tasks.md file is enhanced or checkbox format. Detects whether task tracking contents use the enhanced wave-based format or the legacy checkbox format.
enhanced_tasks_template
Generate the enhanced tasks.md template for a change. Generate the default template for an enhanced-format tasks.md.
is_safe_tracking_filename
Returns true when a tracking filename is safe as a single path segment. Return true when tracking_file is safe as a single filename.
parse_tasks_tracking_file
Parse task tracking markdown into a normalized representation. Parse a tasks.md tracking file into a normalized representation.
tasks_path
Build a tasks path with fallback behavior for invalid ids. Path to {ito_path}/changes/{change_id}/tasks.md.
tasks_path_checked
Build a tasks path only when the change id is a safe path segment. Path to {ito_path}/changes/{change_id}/tasks.md when change_id is safe.
tracking_path_checked
Build a tracking file path when change id + filename are safe. Path to {ito_path}/changes/{change_id}/{tracking_file} when both inputs are safe.
update_checkbox_task_status
Update checkbox-format task status markers. Update the status marker of a checkbox-formatted task in the given file contents.
update_enhanced_task_status
Update enhanced-format task status and metadata. Update the status and “Updated At” metadata of an enhanced-format task block.