On 07/31/2015 09:22 AM, Alexander Walters wrote:
...
> "Is this instance of time DST?  Oh, it has a member attribute 'is_dst',
> let me print that and see..."

That's a great reason _not_ to name the proposed attribute `is_dst`,
because it does not answer the question "is this datetime DST?", and
isn't intended to.

The intent is to disambiguate times within the overlap resulting from a
UTC-offset fallback, whether from DST or any other change in a
timezone's UTC offset.

> "I need to tell python this time I am inputting is DST.  ...I will pass
> True to the is_dst argument"
> 
> "I am in the northern hemisphere and need to construct a date in the
> middle of july.  My nation-state observes DST.  ...what the hell do i do
> with a 'first' argument?"

If you are constructing a datetime in the middle of July, you have no
need to set this attribute, because there are no ambiguous times in the
middle of July.

Your tzinfo (if it's useful) already knows that July is DST in your
timezone, it doesn't need you to set any attribute manually.

Carl

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
Datetime-SIG mailing list
[email protected]
https://mail.python.org/mailman/listinfo/datetime-sig
The PSF Code of Conduct applies to this mailing list: 
https://www.python.org/psf/codeofconduct/

Reply via email to