Opened 11 years ago

Closed 11 years ago

#19651 closed New feature (wontfix)

Non-reflexive recursive many-to-many relation.

Reported by: irodrigo17@… Owned by: nobody
Component: Database layer (models, ORM) Version: 1.4
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Hi, I have a non reflexive recursive many to many relation in my app, and thought it'd be cool to have some default validation for this, instead of having to roll my own every time.

The relation I'm talking about is a twitter-like 'follow' relation between users, where users shouldn't be able to follow themselves (thus it's non-reflexive).

Change History (1)

comment:1 by Luke Plant, 11 years ago

Resolution: wontfix
Status: newclosed

It's not entirely clear what you are proposing. Since you have categorised this as database layer, it sounds like you are looking for a keyword argument to be added to ManyToManyField to enforce this validation.

I really don't think this specific validation rule, which only applies to many-to-many relations to the same model, is common enough to warrant support at the database level, so I'm going to close as WONTFIX.

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