Opened 18 hours ago

Last modified 96 minutes ago

#36095 assigned Cleanup/optimization

Explicitly introduce lazy references in early sections of the docs before they are used.

Reported by: Clifford Gama Owned by: Clifford Gama
Component: Documentation Version: 5.1
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

While reading https://docs.djangoproject.com/en/dev/topics/db/models/, I noticed two issues:

  1. Lazy relationships are used in the documentation before they are explicitly introduced https://docs.djangoproject.com/en/dev/topics/db/models/#extra-fields-on-many-to-many-relationships
  2. The ManyToManyField.through option does not document that it supports lazy references.

To address these:

For the first issue, I propose explicitly introducing lazy references in the introductory Models across files section.
For the second issue, I propose adding a note to the ManyToManyField.through section, clarifying that it supports both lazy references and direct model classes.

Change History (2)

comment:1 by Clifford Gama, 18 hours ago

Has patch: set

comment:2 by Sarah Boyce, 96 minutes ago

Triage Stage: UnreviewedAccepted
Note: See TracTickets for help on using tickets.
Back to Top