docs: record date selection baseline

This commit is contained in:
Ashley Venn 2026-07-02 08:11:29 -07:00
parent 0c1731003f
commit 7a0bb72f43

View file

@ -4,7 +4,7 @@
# Date Selection 01 Block 01 — Scope and Baseline # Date Selection 01 Block 01 — Scope and Baseline
**Status:** Planned. **Status:** Complete.
**Goal:** Verify the persistence-backed app baseline and lock the exact semantics **Goal:** Verify the persistence-backed app baseline and lock the exact semantics
for date selection before implementing UI callbacks. for date selection before implementing UI callbacks.
@ -117,6 +117,33 @@ reopening architectural decisions.
- Selected-date behavior is documented. - Selected-date behavior is documented.
- Tests and validation commands for the plan are known. - Tests and validation commands for the plan are known.
## Implementation notes
- Persistence Plan 1 has been fast-forward merged into `main` before this branch
was created. Normal Flutter startup uses `PersistentSchedulerComposition.open`
and `SqliteApplicationRuntime.open`; seeded demo data remains isolated to
`DemoSchedulerComposition.seeded` for tests and explicit demo construction.
- The existing composition root owns `GetTodayStateQuery`,
`V1ApplicationCommandUseCases`, `V1ApplicationManagementUseCases`, owner id,
owner timezone, operation clocks, and SQLite lifecycle/disposal.
- Selected date will live in a dedicated `SelectedDateController`. `FocusFlowHome`
owns that controller and wires it to Today reads and command execution. Widgets
will receive callbacks and display-ready labels only; they will not instantiate
repositories, Drift types, scheduler use cases, or engine objects.
- Selected date is the visible owner-local `CivilDate`. Changing it is read-only:
previous/next move one civil day, picker selection jumps directly to the chosen
civil date, command timestamps use the runtime clock, backlog scheduling targets
the selected planning day, and completion records the real completion instant.
- Validation targets to preserve: `scripts/test.sh`; `flutter test` in
`apps/focus_flow_flutter`; controller, app, widget, model, and persistent
lifecycle Flutter tests added by this plan; core query and command tests under
`packages/scheduler_core`; SQLite lifecycle tests under
`packages/scheduler_persistence_sqlite`.
- Baseline validation on this branch: `flutter test` in
`apps/focus_flow_flutter` passed with 24 tests. `scripts/test.sh` did not reach
package tests because `dart analyze` failed in the Dart analysis server with
`OS Error: Too many open files, errno = 24` while setting analysis roots.
## Validation after block ## Validation after block
```sh ```sh