Skip to content

migration bug in SplitField in 5.0.0 #637

@jingrandev

Description

@jingrandev
class Article(BaseModel):

    StatusChoice = Choices(
        ("draft", "DRAFT", _("Draft")),
        ("published", "PUBLISHED", _("Published")),
        ("archived", "ARCHIVED", _("Archived")),
    )

    id = models.CharField(max_length=36, primary_key=True)
    status = StatusField(choices_name="StatusChoice", default=StatusChoice.DRAFT)
    title = models.CharField(_("Title"), max_length=128)
    content = SplitField()
    published_at = MonitorField(monitor="status", when=["published"], null=True)
    archived_at = MonitorField(monitor="status", when=["archived"], null=True)

in 5.0.0 there is a bug in SplitField when I use migrate command

django.db.utils.ProgrammingError: column "_content_excerpt" specified more than once

when I switched the version to 4.5.0, there was no error

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions