QuerySet.in_bulk() should accept a set()
— at Version 2
--- django/db/models/query.py (revision 11751)
+++ django/db/models/query.py (working copy)
@@ -356,7 +356,7 @@
"""
assert self.query.can_filter(), \
"Cannot use 'limit' or 'offset' with in_bulk"
- assert isinstance(id_list, (tuple, list)), \
+ assert isinstance(id_list, (tuple, list, set, frozenset)), \
"in_bulk() must be provided with a list of IDs."
if not id_list:
return {}
Change History
(3)
Component: |
Uncategorized → Database layer (models, ORM)
|
Has patch: |
set
|
Description: |
modified (diff)
|
Triage Stage: |
Unreviewed → Ready for checkin
|
Version: |
1.1 → SVN
|