#23422: Cannot add Permission to Group in data migration
----------------------------+--------------------------------------
     Reporter:  tjwalch     |                    Owner:  nobody
         Type:  Bug         |                   Status:  closed
    Component:  Migrations  |                  Version:  1.7
     Severity:  Normal      |               Resolution:  wontfix
     Keywords:              |             Triage Stage:  Unreviewed
    Has patch:  0           |      Needs documentation:  1
  Needs tests:  0           |  Patch needs improvement:  0
Easy pickings:  0           |                    UI/UX:  0
----------------------------+--------------------------------------

Comment (by theoden-dd):

 Replying to [comment:20 alanjds]:

 I've failed with Django 1.9, even after adapting emit_post_migrate_signal
 to its new signature:
 {{{
     db_alias = schema_editor.connection.alias
     try:
         # Django 1.9
         emit_post_migrate_signal(2, False, db_alias)
     except TypeError:
         # Django < 1.9
         try:
             # Django 1.8
             emit_post_migrate_signal(2, False, 'default', db_alias)
         except TypeError:  # Django < 1.8
             emit_post_migrate_signal([], 2, False, 'default', db_alias)
 }}}

 This led me to this most significant part of stack trace and error:
 {{{
 ...
   File "<venv>/local/lib/python2.7/site-
 packages/django/core/management/sql.py", line 50, in
 emit_post_migrate_signal
     using=db)
   File "<venv>/local/lib/python2.7/site-
 packages/django/dispatch/dispatcher.py", line 192, in send
     response = receiver(signal=self, sender=sender, **named)
   File "<venv>/olivia/local/lib/python2.7/site-
 packages/django/contrib/sites/management.py", line 20, in
 create_default_site
     if not Site.objects.using(using).exists():
 ...
 django.db.utils.OperationalError: no such table: django_site
 }}}

 Has anyone got the success with 1.9?

--
Ticket URL: <https://code.djangoproject.com/ticket/23422#comment:25>
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/065.e9f2180a3869781dfbf70ccc8809fa1b%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to