[Python-ideas] Please reconsider the Boolean evaluation of midnight

Chris Angelico rosuav at gmail.com
Wed Mar 5 17:20:08 CET 2014


On Thu, Mar 6, 2014 at 3:05 AM, Shai Berger <shai at platonix.com> wrote:
> On Wednesday 05 March 2014 17:37:14 Paul Moore wrote:
>> On 5 March 2014 15:19, Shai Berger <shai at platonix.com> wrote:
>> > What, other than "bug", do you call behavior that isn't sensible?
>>
>> "Unfortunate".
>
> That's unfortunate. You miss a lot of bugs.

A bug is something where behaviour differs from documentation or
intent. Differing from expectation isn't necessarily a bug (although
in the absence of clear docs or statement of intent, it could be
called one), partly because expectations vary. When the bulk of
programmers expect one thing and the code does another, it's probably
a wart or misfeature, but if it's properly documented, it can't really
be called a bug.

In this case, I would say that it's a wart. The fact that one
timestamp happens to be treated as zero is odd, and I wouldn't
advocate it, but now that it's there and documented, it's not a bug.

ChrisA


More information about the Python-ideas mailing list