#31486: Deprecate passing unsaved objects to related filters.
-------------------------------------+-------------------------------------
     Reporter:  Mapiarz              |                    Owner:  Hasan
                                     |  Ramezani
         Type:  Bug                  |                   Status:  assigned
    Component:  Database layer       |                  Version:  master
  (models, ORM)                      |
     Severity:  Normal               |               Resolution:
     Keywords:                       |             Triage Stage:  Accepted
    Has patch:  1                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  1
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------

Comment (by Hasan Ramezani):

 As I [https://github.com/django/django/pull/12768#discussion_r412815335
 commented on PR]:

 I don't know how to distinguish between `p2.choice_set.all()` and
 `Choice.objects.filter(poll=p2)`, It seems `get_normalized_value` receives
 the same (value and lhs) for these both cases.

 I've also tried to implement it in  `RelatedLookupMixin.get_prep_lookup`
 based on
 [https://github.com/django/django/pull/12768#discussion_r412882870 Mariusz
 comment on PR], but still same problem. the `lhs` and `rhs` have the same
 value in `p2.choice_set.all()` and `Choice.objects.filter(poll=p2)` cases.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/31486#comment:4>
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 on the web visit 
https://groups.google.com/d/msgid/django-updates/065.3bdabc98f86ade3877a99344df6297c4%40djangoproject.com.

Reply via email to