#23408: Migrations call callable defaults only once
----------------------------+------------------------------------
     Reporter:  Harper04    |                    Owner:  nobody
         Type:  Bug         |                   Status:  closed
    Component:  Migrations  |                  Version:  1.7
     Severity:  Normal      |               Resolution:  invalid
     Keywords:              |             Triage Stage:  Accepted
    Has patch:  0           |      Needs documentation:  0
  Needs tests:  0           |  Patch needs improvement:  0
Easy pickings:  0           |                    UI/UX:  0
----------------------------+------------------------------------

Comment (by rowanseymour):

 I also ran into this problem with a UUID field. I would have thought that
 this is a sufficiently common use case to be catered for in core. But core
 devs feel that the onus is on people to write custom 3-step migrations
 each time, then makemigrations should at least show a warning. I'd imagine
 that in most cases, a single value for all rows is not what the user is
 expecting. If makemigrations sees unique=True on the field then it knows
 that the migration will fail.

--
Ticket URL: <https://code.djangoproject.com/ticket/23408#comment:9>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/066.18297ce8604efba628fc5d2257205cd1%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to