User: Password:
|
|
Subscribe / Log in / New account

A false midnight

A false midnight

Posted Mar 14, 2014 10:28 UTC (Fri) by khim (subscriber, #9252)
In reply to: A false midnight by m45t3r
Parent article: A false midnight

Yes, it's similar gotcha. But there are a difference: from __future__ import division handlily fixes problems with division, but you count not do anything like that to fix problems with DateTime.


(Log in to post comments)

A false midnight

Posted Mar 14, 2014 16:09 UTC (Fri) by hummassa (subscriber, #307) [Link]

Well, actually... nothing keeps you from doing a pragmatic "fixdatetime" module and "from fixdatetime import fixdatetime" so that DateTime.__notzero__() is redefined to a saner default for the scope of your programa, isn't it?


Copyright © 2017, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds