#37034: Improve writing migrations how-to add through field on a ManyToManyField
-------------------------------------+-------------------------------------
     Reporter:  Clifford Gama        |                    Owner:  Clifford
                                     |  Gama
         Type:  Bug                  |                   Status:  assigned
    Component:  Documentation        |                  Version:  dev
     Severity:  Normal               |               Resolution:
     Keywords:  migrations,          |             Triage Stage:  Accepted
  ManyToManyField, through,          |
  SeparateDatabaseAndState           |
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Changes (by Natalia Bidart):

 * keywords:  migrations, ManyToManyField, through => migrations,
     ManyToManyField, through, SeparateDatabaseAndState
 * stage:  Unreviewed => Accepted

Comment:

 Thank you for the ticket, Clifford. I agree that a more focused how-to is
 the right direction. To keep each topic clear, I suggest splitting this
 into two separate how-to guides: one for `SeparateDatabaseAndState`, and
 another for migrating a m2m to use a `through` model.

 These are distinct goals, and combining them makes the example harder to
 follow and less accurate. This aligns better with the [https://diataxis.fr
 /how-to-guides/ Diataxis definition of how-to guides as goal-oriented
 instructions]:

 > How-to guides are directions that guide the reader through a problem or
 towards a result. How-to guides are goal-oriented.

 Concretely, one guide would show a clean, representative use of
 `SeparateDatabaseAndState` (maybe creating an index on a big table without
 downtime? is there a DB primitive that Django does not support?), and the
 other would demonstrate the correct way to migrate an M2M to a through
 model without relying on it. Even if implemented in a single PR, keeping
 the guides separate would improve clarity and avoid conflating the two
 concerns.
-- 
Ticket URL: <https://code.djangoproject.com/ticket/37034#comment:3>
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 visit 
https://groups.google.com/d/msgid/django-updates/0107019d921bec3b-8b62700b-388b-4862-bb19-4c14d6415ebf-000000%40eu-central-1.amazonses.com.

Reply via email to