Examples:
2014-08-06T11:00:00.000Z
2014-08-06T11:00:00,000Z
ISO 8601:2004 states that parsers should support both delineators, with a
preference for commas. https://www.iso.org/standard/40874.html
A decimal mark, either a comma or a dot (without any preference as stated
in resolution 10 of the 22nd General Conference CGPM in 2003,[16] but with
a preference for a comma according to ISO 8601:2004)
Github Pull Request: https://github.com/django/django/pull/11818
--
Ticket URL: <https://code.djangoproject.com/ticket/30803>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
* type: Uncategorized => Bug
* version: 2.2 => master
* component: Uncategorized => Utilities
--
Ticket URL: <https://code.djangoproject.com/ticket/30803#comment:1>
* has_patch: 0 => 1
* type: Bug => New feature
* stage: Unreviewed => Accepted
Comment:
I don't see much harm in supporting comma separators but I couldn't get my
hand on a copy of `ISO 8601:2004` to confirm the report. Tentatively
accepting.
Are you aware in any changes in `ISO 8601-1:2019` and `ISO 8601-2:2019`
given they supersede the now withdrawn `ISO 8601:2004`?
It might be worth adding a mention in the release notes about this change
even if it's minor.
--
Ticket URL: <https://code.djangoproject.com/ticket/30803#comment:2>
Comment (by Ben Wilber):
Replying to [comment:2 Simon Charette]:
> I don't see much harm in supporting comma separators but I couldn't get
my hand on a copy of `ISO 8601:2004` to confirm the report. Tentatively
accepting.
>
> Are you aware in any changes in `ISO 8601-1:2019` and `ISO 8601-2:2019`
given they supersede the now withdrawn `ISO 8601:2004`?
>
> It might be worth adding a mention in the release notes about this
change even if it's minor.
I'm not aware of anything in the 2019 revisions that has changed regarding
periods vs commas for separating milliseconds. Unfortunately the full
specs are not publicly available to confirm. I can add a note to the
release notes. Which would be the appropriate release notes document to
mention this?
--
Ticket URL: <https://code.djangoproject.com/ticket/30803#comment:3>
* status: new => assigned
* owner: nobody => Ben Wilber
* needs_tests: 0 => 1
* needs_docs: 0 => 1
--
Ticket URL: <https://code.djangoproject.com/ticket/30803#comment:4>
Comment (by Farhaan Bukhsh):
Hey, I would love to complete this PR, what can be the next steps? I see
writing tests as one of them. Thanks a ton in advance. :)
--
Ticket URL: <https://code.djangoproject.com/ticket/30803#comment:5>
* owner: Ben Wilber => Farhaan Bukhsh
* needs_tests: 1 => 0
Comment:
[https://github.com/django/django/pull/12141 PR]
--
Ticket URL: <https://code.djangoproject.com/ticket/30803#comment:6>
* needs_docs: 1 => 0
* stage: Accepted => Ready for checkin
--
Ticket URL: <https://code.djangoproject.com/ticket/30803#comment:7>
Comment (by Mariusz Felisiak <felisiak.mariusz@…>):
In [changeset:"42b23d1e79b21ddd8abd7216a6771f105dd7062c" 42b23d1e]:
{{{
#!CommitTicketReference repository=""
revision="42b23d1e79b21ddd8abd7216a6771f105dd7062c"
Refs #30803 -- Allowed comma separators for decimal fractions in
parse_duration().
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/30803#comment:8>
* status: assigned => closed
* resolution: => fixed
Comment:
In [changeset:"1f817daa20110987bf155fc6c942a8a14720a66b" 1f817daa]:
{{{
#!CommitTicketReference repository=""
revision="1f817daa20110987bf155fc6c942a8a14720a66b"
Fixed #30803 -- Allowed comma separators for milliseconds in
django.utils.dateparse functions.
Co-Authored-By: Ben Wilber <benw...@gmail.com>
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/30803#comment:9>