fabro/lib
Bryan Helmkamp 237fb4a12f
refactor(workflow): finish StageId migration in projection and durations
Make iter_stages() and iter_stages_mut() yield in first_event_seq order so
callers don't need to re-sort. Drops boilerplate sorts in the billing handler
and the run-dump builder.

Replace extract_stage_durations_from_events with two intent-explicit
rollups built on extract_stage_durations_by_stage_id:
- total_stage_duration_by_node (sum across visits) for billing/usage
- latest_stage_duration_by_node (highest visit) for finalize/retro

The old function silently picked an arbitrary visit's duration per node;
the new helpers preserve all visit data and document the rollup choice
at the call site.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-04 18:54:31 -04:00
..
crates refactor(workflow): finish StageId migration in projection and durations 2026-05-04 18:54:31 -04:00
packages/fabro-api-client fabro(01KQT1VDVXGWN9P6MFK4R5E44D): implement (succeeded) 2026-05-04 18:27:54 +00:00