print_summary_weekly, print_summary_weekly_totals and _aggregate summed
raw duration_hours, which is None for open (unfinished) entries, raising
TypeError: float + NoneType. Skip open entries from the weekly totals,
matching to_csv_entries and parser.aggregate. Add regression tests.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Prefix the project name or note column with ~ to mark an entry as
count-but-don't-export. Marked entries are included in summary and
status totals but omitted from all csv output (both --raw and
aggregated, single-day and weekly).
| 09:00 | 17:00 | 8:00 | ~Leave | | Day off |
| 09:00 | 17:00 | 8:00 | Leave | | ~Day off |
The ~ is stripped from whichever field carries it before any
downstream processing, so project map resolution is unaffected.
Implementation:
- parse_table sets skip_csv=True on marked rows and strips the ~
- new filter_skip_csv() helper in parser.py
- to_csv_entries() skips skip_csv rows
- _cmd_csv calls filter_skip_csv() before aggregate_rows()
- Add `write_csv_weekly()` to output.py: writes entries from multiple
days as a single CSV with one header row, correct date per row
- Add `-w`/`--weekly` flag to csv subparser
- _cmd_csv branches on args.weekly: fetches week sections, formats
per-day date strings, calls write_csv_weekly; --raw is honoured
- Add TestWriteCsvWeekly with 6 tests
- Update README with weekly csv usage examples
- Add `to_csv_entries()` to output.py: converts raw rows to write_csv
entries one-for-one, without merging by (project, description)
- Add `--raw` flag to the csv subparser; _cmd_csv branches on it
- Add TestToCsvEntries with 6 tests
- Update README with --raw usage example
- Add .coverage and htmlcov/ to .gitignore
- Add stories subcommand listing stories worked on, grouped by project
- Preserve story_raw in parser row dicts alongside the stripped story,
so markdown links are available for display
- print_stories() filters to rows with a non-empty story field,
deduplicates by stripped story text (preferring the linked version),
sums hours per story, and outputs an indented Markdown list
- Project names resolved through project_map (same as csv/summary)
- -w/--weekly flag aggregates stories across the full week
- Add tests for print_stories covering deduplication, link preservation,
grouping, empty rows, and story-less row exclusion
- Fix flex daily target in status: use projected hours per prior day
rather than fixed 8h when computing remaining hours for today