Skip to content

MAINT: Memory Model cleanup - #1937

Merged
rlundeen2 merged 2 commits into
microsoft:mainfrom
rlundeen2:rlundeen2/urban-waddle
Jun 4, 2026
Merged

MAINT: Memory Model cleanup#1937
rlundeen2 merged 2 commits into
microsoft:mainfrom
rlundeen2:rlundeen2/urban-waddle

Conversation

@rlundeen2

Copy link
Copy Markdown
Contributor

This converts simplifies our memory model class. It is phase 11 of the pyrit.models refactor

https://gist.github.com/rlundeen2/3e8daa8e12a11b4b6e52587b3c9b1dca

This doesn't clean up as much as I thought we could; we still have to repeat things. That's because sqlalchemy reserves some important extensions (like ID) and needs to coerce types in an incompatible way (e.g. some things are serialized and truncated).

So in this PR we don't gain much from the thin models, but it's still a win.

rlundeen2 and others added 2 commits June 4, 2026 10:06
…n helpers

Centralize naive->UTC datetime normalization in a UTCDateTime TypeDecorator
(fixes latent naive completion_time bug) and factor repeated identifier
model_dump/model_validate calls into explicit helper functions.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Comment thread pyrit/memory/memory_models.py
@rlundeen2
rlundeen2 added this pull request to the merge queue Jun 4, 2026
Merged via the queue into microsoft:main with commit 35ad9f0 Jun 4, 2026
52 checks passed
@rlundeen2
rlundeen2 deleted the rlundeen2/urban-waddle branch June 4, 2026 19:44
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.

2 participants