﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
26324	DurationField stores certain values incorrectly in sqlite	chausner	nobody	"When encoding certain timedelta values in a DurationField, saving the object to a sqlite database and then reading it again, DurationField returns None.
{{{#!python
class Foo(models.Model):
    bar = models.DurationField()

Foo.objects.create(bar=timedelta(seconds=2.05))
Foo.objects.create(bar=timedelta(seconds=3.05))

print str(Foo.objects.all()[0].bar) # 'None'
print str(Foo.objects.all()[1].bar) # '3.05'
}}}
I can reproduce this bug with Django 1.8.5 and 1.9.3 using sqlite as database backend. It does not occur with MySQL, so it seems to be related to how sqlite stores bigints. It renders DurationField essentially useless with sqlite."	Bug	closed	Database layer (models, ORM)	1.8	Release blocker	fixed	sqlite, DurationField		Ready for checkin	1	0	0	0	0	0
