-
Notifications
You must be signed in to change notification settings - Fork 43
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: introduce simple migration framework #202
Conversation
benfdking
commented
Jan 13, 2025
- introduces simple migration framework to make it possible to change tables later down the lline
saq/queue/postgres.py
Outdated
jobs_table=self.jobs_table, | ||
stats_table=self.stats_table, | ||
) | ||
target_number = len(migrations) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
target_version
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
don't use len(...), let's use the file number
ba27441
to
a9b90a1
Compare
saq/queue/postgres.py
Outdated
jobs_table=self.jobs_table, | ||
stats_table=self.stats_table, | ||
) | ||
target_version = len(migrations) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
let's get the last one, and infer the version from the file name
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we make this either a hash value or something less error prone? or perhaps like manual tagging of versions
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we can do hash cause we need to have total order
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
he's gonna change it to be manual indices
a9b90a1
to
9a3ba91
Compare