I think it would be acceptable to make related name clashes a check Error. I'm guessing you couldn't find any justification for why the check doesn't currently do this?
On Sun, 6 Sep 2020 at 11:31, Shai Berger <s...@platonix.com> wrote: > Hi all, > > When you define a related field on a model -- a ForeignKey etc -- it > usually adds its related-name as a backwards-accessor on the related > model. These related names are checked for clashes against other fields > and other related-names. But they are not checked for clashes against > other attributes of the remote model, like methods and properties. > > A clash with another field (or accessor) is considered an error. I > think a clash with a property should be at least a warning. Currently > it is accepted silently (and AFAICT, the related-name takes > precedence, that is, the property is effectively deleted). > > Does anybody think this is the desired behavior? > > Thanks, > Shai. > > -- > You received this message because you are subscribed to the Google Groups > "Django developers (Contributions to Django itself)" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to django-developers+unsubscr...@googlegroups.com. > To view this discussion on the web visit > https://groups.google.com/d/msgid/django-developers/20200906133146.4449641c.shai%40platonix.com > . > -- Adam -- You received this message because you are subscribed to the Google Groups "Django developers (Contributions to Django itself)" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-developers+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/django-developers/CAMyDDM2ANYnO1j4MsC9LAqik7uXk-2n%3DGXhu0_TmGjkVToQ4ow%40mail.gmail.com.