Opened 9 years ago

Closed 9 years ago

#1134 closed defect (fixed)

Incorrect error throw in query parse_lookup

Reported by: freakboy@… Owned by: adrian
Component: contrib.admin Version: master
Severity: critical Keywords: query kwarg exception
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

In the magic-removal branch, django/db/models/query.py, line 216 references _throw_bad_kwarg_error(kwarg).

The underscore should be removed, as the method is now called throw_bad_kwarg_error.

As a result, mistypes of the double underscore query separator (e.g., question_exact="What?") throw unknown method, rather than the expected type error.

This bug was found, and a patch inadvertantly included as part of ticket #1133.

Change History (1)

comment:1 Changed 9 years ago by adrian

  • Resolution set to fixed
  • Status changed from new to closed

Fixed in [1792].

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