Author Andreas.Pelme
Recipients Andreas.Pelme, Lakin.Wecker, belopolsky, eric.araujo, georg.brandl, gwrtheyrn, lemburg, r.david.murray, shai, tim.peters
Date 2014-03-04.20:14:17
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1393964057.99.0.814567478828.issue13936@psf.upfronthosting.co.za>
In-reply-to
Content
I agree with Danilo and Shai -- this behavior very surprising. I deal with datetimes a lot, and this bug has bitten me a number of times.

I cannot really think of a single case where "if timeobj:" is useful with the current behavior. It results in a check for "is timeobj midnight or false?"

Would that ever be useful in practice? If you are indeed checking for midnight, surely "if timeobj == time(0, 0):" would be the most explicit and obvious way to do it?
History
Date User Action Args
2014-03-04 20:14:18Andreas.Pelmesetrecipients: + Andreas.Pelme, lemburg, tim.peters, georg.brandl, belopolsky, eric.araujo, r.david.murray, gwrtheyrn, Lakin.Wecker, shai
2014-03-04 20:14:17Andreas.Pelmesetmessageid: <1393964057.99.0.814567478828.issue13936@psf.upfronthosting.co.za>
2014-03-04 20:14:17Andreas.Pelmelinkissue13936 messages
2014-03-04 20:14:17Andreas.Pelmecreate