Opened 11 years ago

Closed 11 years ago

#21020 closed New feature (invalid)

Allow Migrations to use parent classes migration profile

Reported by: anonymous Owned by: nobody
Component: Database layer (models, ORM) Version: dev
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

I'm unsure as to how Django is implementing South internally, but one thing that has always caused me pain is when I need to create myself a SubClass of Charfield and suddenly require to redefine all of the south migration profile. It would be better to be able to point to your parent class for the migration profile.

Example of desired ability:

class CharField2(CharField):
    
    .........
    .........

    class Meta:
        migration = super(CharField, self)._meta.migration


Change History (2)

comment:1 by Giggaflop, 11 years ago

comment:2 by Marc Tamlyn, 11 years ago

Resolution: invalid
Status: newclosed

django.db.migrations is not just South pulled in. It's actually a rewrite of the entire concept to make it better.

Fields now require a deconstruct method to be used in migrations. As this is a simple method, it is automatically transferred onto subclasses. See the release notes for the current skeleton docs: https://docs.djangoproject.com/en/dev/releases/1.7/#new-method-on-field-subclasses

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