Opened 11 years ago
Last modified 10 months ago
#22288 closed Bug
F() expression not compatible with __range field look up — at Initial Version
Reported by: | Owned by: | nobody | |
---|---|---|---|
Component: | Database layer (models, ORM) | Version: | dev |
Severity: | Normal | Keywords: | |
Cc: | github@…, josh.smeaton@…, matthew@… | Triage Stage: | Accepted |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | yes |
Easy pickings: | no | UI/UX: | no |
Description
class TestModel(models.Model):
a = models.SmallIntegerField()
b = models.SmallIntegerField()
TestModel.objects.filter(arange=(F('b')-1, F('b')+1)
TypeError: int() argument must be a string or a number, not 'ExpressionNode'
Note:
See TracTickets
for help on using tickets.