Task: Fix mapper write sites: timepoint_to_timestamp → datetime::to_db_string
This page documents a task in the Unify entity timestamp fields: replace optional<db_timestamp> with std::string story. It captures the goal, current status, acceptance, and any notes or results.
Goal
Eliminate timepoint_to_timestamp (silent-failure write-side
conversion) in favour of datetime::to_db_string, which cannot fail
for valid time_points and throws rather than returning an empty
timestamp.
Status
| Field | Value |
|---|---|
| State | DONE |
| Parent story | Unify entity timestamp fields: replace optional<db_timestamp> with std::string |
| Now | Nothing. |
| Waiting on | Nothing. |
| Next | Nothing — task closed. |
| Last touched | 2026-06-04 |
Acceptance
- No call sites of
timepoint_to_timestampremain. timepoint_to_timestampis deleted frommapper_helpers.hpp.- Both throwing overloads of
timestamp_to_timepointremain. - Build green.
Plan
(Transient implementation strategy. Written when work starts;
distilled into the parent story's * Decisions and cleared when the
task closes. Plans do not outlive their task.)
Notes
PRs
| PR | Title |
|---|---|
| #1036 | [multi,compass] Timestamp unification mop-up; compass test logging toggle |
Review
| # | Comment summary | File | Decision | Notes |
|---|---|---|---|---|
| 1 | Now field should be 'Nothing.' on DONE tasks | task_fix-mapper-write-sites.org | Fixed in c54d298b1 |
Result
All write-site call sites had already been migrated to
datetime::to_db_string as part of PR #1033 — a grep on the mop-up
branch found zero remaining callers. This task therefore reduced to
deleting the timepoint_to_timestamp function and its doc block from
mapper_helpers.hpp. Both throwing timestamp_to_timepoint overloads
remain. Full build green.