Opened 8 years ago
Last modified 6 years ago
#26891 closed Bug
ForeignObject/ForeignKey does not obey lookup registration API — at Version 1
Reported by: | Ryan P Kilby | Owned by: | nobody |
---|---|---|---|
Component: | Database layer (models, ORM) | Version: | 1.9 |
Severity: | Normal | Keywords: | |
Cc: | rpkilby@… | Triage Stage: | Accepted |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description (last modified by )
ForeignObject
's implementation of get_lookup
and get_transform
causes register_lookup
to essentially have no effect.
The PR should allow users to successfully register lookups while ignoring the default lookups registered to Field
. This works by duplicating RegisterLookupMixin._get_lookup
, but stopping mro walking at ForeignObject
.
https://github.com/django/django/pull/6906
Note:
See TracTickets
for help on using tickets.