[Draft] [Proposal] Reset column information automatically for `MigrationRecord`s
What does this MR do and why?
We recommend developers to reset the column information for the models created in migrations. This information is quite easy to be missed by the author and reviewers. To eliminate the human-error factor, we can automatically reset the column information for the models inherited from the MigrationRecord
base model.
Based on this thread: !87738 (comment 949872051)
PS.1: Specs are left out intentionally to just focus on the functionality itself in the draft stage.
PS.2: As an alternative, we can call the reset_column_information
method for all the models defined under the current migration's namespace in up/down
methods but this would require more logic and computation.
PS.3: Or, we can also force the authors to set the table name explicitly to make sure we always reset the column information.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.