mirror of
https://github.com/django/django.git
synced 2025-11-01 12:25:37 +00:00
Fixed #4130 -- Added more self-explanatory error message when a typo is made in
a queryset field argument. We may need to fine-tune the error message based on experience down the line, but this stands as an improvement on its own. Thanks, Ned Batchelder. git-svn-id: http://code.djangoproject.com/svn/django/trunk@5133 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
0b2f9e89cd
commit
d943f5ae92
6 changed files with 19 additions and 8 deletions
|
|
@ -32,7 +32,7 @@ __test__ = {'API_TESTS':"""
|
|||
>>> Choice.objects.filter(foo__exact=None)
|
||||
Traceback (most recent call last):
|
||||
...
|
||||
TypeError: Cannot resolve keyword 'foo' into field
|
||||
TypeError: Cannot resolve keyword 'foo' into field, choices are: id, poll, choice
|
||||
|
||||
# Can't use None on anything other than __exact
|
||||
>>> Choice.objects.filter(id__gt=None)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue