#22204: migrations yield CircularDependencyError for simple model
---------------------------------+------------------------
     Reporter:  gabejackson      |      Owner:  nobody
         Type:  Bug              |     Status:  new
    Component:  Migrations       |    Version:  master
     Severity:  Release blocker  |   Keywords:  migrations
 Triage Stage:  Unreviewed       |  Has patch:  0
Easy pickings:  0                |      UI/UX:  0
---------------------------------+------------------------
 Here is a simple test project to reproduce the
 django.db.migrations.graph.CircularDependencyError error:
 [https://github.com/gabejackson/django-migration-testproject/]

 Steps to reproduce:
 {{{
 cd simple_circular_dependency
 # Cleanup (note this stuff isn't in the repo)
 rm -rf */migrations/*.pyc
 rm -rf */migrations/00*
 rm db.sqlite3

 # Migrations
 ./manage.py makemigrations
 }}}

 Yields:
 {{{
 Migrations for 'a':
   0001_initial.py:
     - Create model Contact
     - Create model Person
     - Create model Address
     - Create model ShopUserAddress
     - Create model ShopUserContact
     - Create model ShopUserPerson
 Migrations for 'b':
   0001_initial.py:
     - Create model DeliveryCountry
     - Create model Package
 }}}

 now run:
 {{{
 ./manage.py migrate --list
 }}}
 yields:
 {{{
 django.db.migrations.graph.CircularDependencyError: [('a',
 '0001_initial'), ('b', '0001_initial'), ('a', '0001_initial')]
 }}}

-- 
Ticket URL: <https://code.djangoproject.com/ticket/22204>
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 django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/054.8ce14227d882f28dd91c685feb761590%40djangoproject.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to