﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
23473	Django prompts to create new migrations when none are needed when a class is used in a field declaration	Dan Loewenherz	Markus Holtermann	"Create a model like so:

{{{
from django.db import models
from django.utils.deconstruct import deconstructible

@deconstructible
class IgnoreFormatString(object):
    def __init__(self, s):
        self.s = s

    def __str__(self):
        return self.s

    def __mod__(self, k):
        return self

class Product(models.Model):
    name = models.CharField(max_length=32, blank=True, null=True, error_messages={'invalid': IgnoreFormatString('Err, this is invalid.')})
}}}

Create a migration, and then run it. If you run ""./manage.py migrate"" once again, you'll get prompted with 

{{{
  Your models have changes that are not yet reflected in a migration, and so won't be applied.
  Run 'manage.py makemigrations' to make new migrations, and then re-run 'manage.py migrate' to apply them.
}}}

Running makemigrations will create another migration, yet this message will continue to appear if the migration has already been applied."	Bug	closed	Migrations	1.7	Normal	fixed		info+coding@…	Accepted	1	0	0	0	0	0
