Opened 8 years ago

Last modified 8 years ago

#26586 closed Bug

makemigrations does not detect custom field subclassing change — at Initial Version

Reported by: Phil Krylov Owned by: nobody
Component: Migrations Version: 1.9
Severity: Normal Keywords: migrations, custom fields
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Example:

class MyLongTextField(models.CharField):
    def __init__(self, *args, **kwargs):
        kwargs["max_length"] = 2000
        super(MyLongTextField, self).__init__(*args, **kwargs)

After changing this to

class MyLongTextField(models.TextField):
    def __init__(self, *args, **kwargs):
        kwargs["max_length"] = 2000
        super(MyLongTextField, self).__init__(*args, **kwargs)

manage.py makemigrations detects no changes.

Change History (0)

Note: See TracTickets for help on using tickets.
Back to Top