[Django] #25554: Django permissions cause data migration depending on permissions to fail

8 views
Skip to first unread message

Django

unread,
Oct 14, 2015, 2:46:01 PM10/14/15
to django-...@googlegroups.com
#25554: Django permissions cause data migration depending on permissions to fail
-------------------------------+--------------------
Reporter: dirkcuys | Owner: nobody
Type: Uncategorized | Status: new
Component: Migrations | Version: 1.8
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------+--------------------
I'm using a data migration to create a Group. Later I'm adding some
permissions to a model and in a next migration I wish to assign those
permissions to the group I created in another data migration.

Since permissions are only added to the database using the post_migrate
signal, my migrations fail when trying to apply all of them at once. If I
apply them 1 for 1, it doesn't fail since the permissions are created
before running the next migrations

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

Django

unread,
Oct 14, 2015, 3:49:55 PM10/14/15
to django-...@googlegroups.com
#25554: Django permissions cause data migration depending on permissions to fail
-------------------------------+--------------------------------------
Reporter: dirkcuys | Owner: nobody
Type: Uncategorized | Status: closed
Component: Migrations | Version: 1.8
Severity: Normal | Resolution: duplicate
Keywords: | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0

Easy pickings: 0 | UI/UX: 0
-------------------------------+--------------------------------------
Changes (by timgraham):

* status: new => closed
* needs_better_patch: => 0
* resolution: => duplicate
* needs_tests: => 0
* needs_docs: => 0


Comment:

Duplicate of #23422

--
Ticket URL: <https://code.djangoproject.com/ticket/25554#comment:1>

Reply all
Reply to author
Forward
0 new messages