Add Meta.table_name to all models missing it #72
Labels
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: cal/major-domo-database#72
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Problem
Only 6 of ~25 model classes define
table_namein theirMetaclass. All others rely on Peewee's default lowercasing. This violates the project's own documented convention ("always specifyMeta.table_nameto match PostgreSQL naming").Any future class rename will silently break the table mapping.
Fix
Add explicit
table_nameto all modelMetaclasses inapp/db_engine.py.Severity
High — fragile mapping, violates project convention.