#29843: Create permissions using migration operations rather than using the
post_migrate signal
-------------------------------------+-------------------------------------
     Reporter:  Petter Strandmark    |                    Owner:  Arthur
         Type:                       |  Rio
  Cleanup/optimization               |                   Status:  assigned
    Component:  contrib.auth         |                  Version:  dev
     Severity:  Normal               |               Resolution:
     Keywords:  contenttypes         |             Triage Stage:  Accepted
  permissions post_migrate           |
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------

Comment (by Taylor H):

 Hi everyone 👋🏻

 Copying the following from the mailing list for cross-reference (Arthur
 and I are working together). Hoping to get some feedback from everyone .

 > After some experiments and discussions it felt like while the
 implementation might solve the initial problem, it's a bit under the hood
 and will be hard to debug if something goes wrong. The idea was to inject
 operations at the time of running `migrate`.
 >
 > So... we went back to the idea of having hooks during the
 `makemigrations` process instead, so that the operations would be written
 to the migration files, which would make it more explicit and less risky.
 Here is a first draft of how it would look like:
 https://github.com/django/django/pull/14229.
 >
 > 1. We know that the `makemigrations` process is complicated, so before
 we invest more time down that path, is there something obvious we might be
 missing?
 > 2. What do you think of this approach with hooks (pre and post
 "add_operation")?
 > 3. Do you think it would be a useful feature for other third party apps
 as well (not just content types and permissions)?

-- 
Ticket URL: <https://code.djangoproject.com/ticket/29843#comment:13>
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 view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/065.86dda4d76c77ee9aa031f7a476ba7831%40djangoproject.com.

Reply via email to