-
Notifications
You must be signed in to change notification settings - Fork 2
Fix model #33
base: master
Are you sure you want to change the base?
Conversation
garoller
left a comment
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 think it's okay to delete the database and apply the new migrations, and I don't know of a different/better way to do this. But if anyone else does, please let us know.
Most of this looks really good, but I think we should decide what we want to do with the expected_sig field in the Petition model in this PR.
Thanks!
|
I think expected_sig should be kept as is, as opposed to moving it to a global constant. As stated above: What happens if the expected number of signatures changes in the future? In that case, editing the constant would break all of the old petitions. Perhaps you have something else in mind for expected_sig ... ? |
|
Created environment variable DEFAULT_EXPECTED_SIGS: defaults to 300. Implemented in base.py settings file, along with the SECRET_KEY. |
The following changes were made:
These changes completely break the existing database file, because the Petition primary key is changed. All the database migration files are changed. The solution I came up with is to delete the database file and reapply the migrations. Let me know if you see a better way to do this.
The following changes were not made: