[Python-Dev] iso8601 parsing
tritium-list at sdamon.com
Wed Oct 25 15:47:28 EDT 2017
> -----Original Message-----
> From: Alexander Belopolsky [mailto:alexander.belopolsky at gmail.com]
> Sent: Wednesday, October 25, 2017 12:07 PM
> To: Alex Walters <tritium-list at sdamon.com>
> Cc: Chris Barker <chris.barker at noaa.gov>; Python-Dev <python-
> dev at python.org>
> Subject: Re: [Python-Dev] iso8601 parsing
> > On Oct 25, 2017, at 11:45 AM, Alex Walters <tritium-list at sdamon.com>
> > it means
> > the type of the first argument changes the semantic meaning of
> > arguments, and that just adds a level of confusion to any api.
> No, it does not. Passing a string a the first of three arguments will
still be a
> type error.
And that is a confusing api. The problem has already been solved by
classmethod alternate constructors - they are already used widely in the
datetime api. NOT using classmethod constructors is new and confusing for
the SINGLE use case of parsing iso formatted dates and times. Why is that
special? Why isn't ordinal time special to get into __init__?
More information about the Python-Dev