Opened 4 years ago

Closed 4 years ago

Last modified 4 years ago

#31303 closed Bug (fixed)

Remove outdated note about symmetrical with m2m relationship from a model to itself.

Reported by: Matheus Cunha Motta Owned by: Matheus Cunha Motta
Component: Documentation Version: 3.0
Severity: Release blocker Keywords: m2m symmetrical to self
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

The "Extra fields on many-to-many relationships" section of the documentation (link: https://docs.djangoproject.com/en/3.0/topics/db/models/#extra-fields-on-many-to-many-relationships) mentions this:

"When defining a many-to-many relationship from a model to itself, using an intermediary model, you must use symmetrical=False (see the model field reference)."

Which I believe is wrong, i.e. you can set it to symmetrical=True. According to version 3.0 release notes: "Allowed symmetrical intermediate table for self-referential ManyToManyField.". Also according to model field reference (link: https://docs.djangoproject.com/en/3.0/ref/models/fields/#django.db.models.ManyToManyField.symmetrical).

So I would suggest removing that item from the ul.

Change History (4)

comment:1 by Matheus Cunha Motta, 4 years ago

If the suggestion to remove is accepted, heres a pull request: https://github.com/django/django/pull/12487

comment:2 by Mariusz Felisiak, 4 years ago

Has patch: set
Owner: changed from nobody to Matheus Cunha Motta
Severity: NormalRelease blocker
Status: newassigned
Summary: Invalid documentation regarding m2m symmetrical with intermediate tableRemove outdated note about symmetrical with m2m relationship from a model to itself.
Triage Stage: UnreviewedAccepted
Type: UncategorizedBug

comment:3 by Mariusz Felisiak <felisiak.mariusz@…>, 4 years ago

Resolution: fixed
Status: assignedclosed

In 0352a44d:

Fixed #31303 -- Removed outdated note about symmetrical intermediate table for self-referential ManyToManyField.

Follow up to 87b1ad6e7351464c60e751b483d9dfce3a2d3382.

comment:4 by Mariusz Felisiak <felisiak.mariusz@…>, 4 years ago

In 0193a163:

[3.0.x] Fixed #31303 -- Removed outdated note about symmetrical intermediate table for self-referential ManyToManyField.

Follow up to 87b1ad6e7351464c60e751b483d9dfce3a2d3382.

Backport of 0352a44dd61c19bebf0c0b305dbbc3f710ff9945 from master

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