**Parse nullable game_time safely in game lookup** #51

Closed
opened 2026-04-12 23:26:54 +02:00 by umpire274 · 0 comments
umpire274 commented 2026-04-12 23:26:54 +02:00 (Migrated from github.com)

Parse nullable game_time safely in game lookup

get_game_by_id reads g.game_time into a String, but that column is nullable in migrated databases (migration v4 explicitly backfills NULL as game_time when the old schema lacked the column). For those rows, row.get(4)? returns an error, so this lookup fails and both history/export paths silently fall back to "-" values, dropping real matchup/date/venue context for legacy games. Please read game_time as Option<String> (or COALESCE in SQL) so legacy data remains exportable.

Useful? React with 👍 / 👎.

Originally posted by @chatgpt-codex-connector[bot] in https://github.com/umpire274/bs_scoring/pull/49#discussion_r3070131660

**Parse nullable game_time safely in game lookup** `get_game_by_id` reads `g.game_time` into a `String`, but that column is nullable in migrated databases (migration v4 explicitly backfills `NULL as game_time` when the old schema lacked the column). For those rows, `row.get(4)?` returns an error, so this lookup fails and both history/export paths silently fall back to `"-"` values, dropping real matchup/date/venue context for legacy games. Please read `game_time` as `Option<String>` (or `COALESCE` in SQL) so legacy data remains exportable. Useful? React with 👍 / 👎. _Originally posted by @chatgpt-codex-connector[bot] in https://github.com/umpire274/bs_scoring/pull/49#discussion_r3070131660_
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
umpire274/bs_scoring#51
No description provided.