Skip to content

depth1 mapcat update - #1740

Open
axf295 wants to merge 1 commit into
masterfrom
mapcat_update
Open

depth1 mapcat update#1740
axf295 wants to merge 1 commit into
masterfrom
mapcat_update

Conversation

@axf295

@axf295 axf295 commented Sep 9, 2026

Copy link
Copy Markdown

Used claude to update the relevant mapcat integration per mapcat v0.4.0

mapcat's uuid7/datetime/path-rename migrations left this module behind:

  • ctime/start_time/stop_time were passed as raw unix-time floats into columns mapcat's "Swapping to datetime" migration made datetime, causing session.commit() to raise "SQLite DateTime type only accepts Python datetime and date objects" on the very first commit_depth1_tods call (outside the mapmaking try/except, so it hard-crashes the pipeline before a map is made).
  • commit_depth1_map passed time_path, a field DepthOneMapTable no longer has (split into start_time_path/mean_time_path/end_time_path). SQLModel silently drops unknown kwargs, so no time-map path was ever recorded.
  • commit_depth1_tods passed map_name into TODDepthOneTable, which has no such column anymore (association is via a many-to-many relationship through TODToMapTable). The kwarg was silently ignored, so TODs were never actually linked to their map.

Verified against a real mapcat db migrated to head: commit succeeds, ctime/start_time/stop_time land as datetimes, mean_time_path is populated, and the TOD<->map relationship is linked in both directions.

Claude-Session: https://claude.ai/code/session_01Rh1TMcQhLGM8TyQZ947Rvt

@axf295
axf295 requested a review from chervias September 9, 2026 02:38
mapcat's uuid7/datetime/path-rename migrations left this module behind:

- ctime/start_time/stop_time were passed as raw unix-time floats into
  columns mapcat's "Swapping to datetime" migration made datetime,
  causing session.commit() to raise
  "SQLite DateTime type only accepts Python datetime and date objects"
  on the very first commit_depth1_tods call (outside the mapmaking
  try/except, so it hard-crashes the pipeline before a map is made).
- commit_depth1_map passed time_path, a field DepthOneMapTable no
  longer has (split into start_time_path/mean_time_path/end_time_path).
  SQLModel silently drops unknown kwargs, so no time-map path was ever
  recorded.
- commit_depth1_tods passed map_name into TODDepthOneTable, which has
  no such column anymore (association is via a many-to-many
  relationship through TODToMapTable). The kwarg was silently ignored,
  so TODs were never actually linked to their map.

Verified against a real mapcat db migrated to head: commit succeeds,
ctime/start_time/stop_time land as datetimes, mean_time_path is
populated, and the TOD<->map relationship is linked in both
directions.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Rh1TMcQhLGM8TyQZ947Rvt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant