﻿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
22160	TimeField default argument not working.	vlad.dragos.002@…	nobody	"Hello,

The problem is that i have the field definition like this:
{{{pickup_time_from = models.TimeField(default=datetime.time(hour=9))}}}

And when I try to validate the model through a ModelForm it give me the error that the field is required.
I also tried the following:
{{{pickup_time_from = models.TimeField(default=datetime.time(hour=9), blank=True)}}}
But it throws the following exception: 
{{{null value in column ""pickup_time_from"" violates not-null constraint}}}

Hope this helps,
Best regards, 
Vlad


"	Bug	closed	Database layer (models, ORM)	1.6	Normal	needsinfo			Unreviewed	0	0	0	0	0	0
