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

Chris Angelico rosuav at gmail.com
Fri Mar 7 01:13:25 CET 2014


On Fri, Mar 7, 2014 at 11:04 AM, Greg Ewing <greg.ewing at canterbury.ac.nz> wrote:
> Chris Angelico wrote:
>>
>> Which is the earlier time: 18:00:00 Australia/Melbourne, or 03:00:00
>> America/New_York?
>
>
> If you think of times of day as modular, then it doesn't
> make sense to ask whether one is earlier than another.

It should be possible to ask if they're equal, at least. Are they?

> But to clarify my position: It's okay to attach a
> timezone to a *time of day*. It's *not* okay to attach
> a timezone to a *difference* between times of day.

What operations can you do on a time-of-day-with-timezone? Give me
some examples, and I'll show you, with the above two examples, how
quirky that can be.

ChrisA


More information about the Python-ideas mailing list