Re: [elixir-core:10047] ISO 8601 ordinal dates

2021-02-03 Thread José Valim
To complement what Kip says, the ISO standard also focuses a lot on what is agreed between parties. For example, ISO says you can submit a date as 2021-01, as long as both parties agree on that. Does it mean we should support 2021-01 on Elixir out of the box? There is also the argument in that,

Re: [elixir-core:10047] ISO 8601 ordinal dates

2021-02-03 Thread Christopher Keele
> I think it's important to be careful on the scope. The ISO8601 spec is vast (I am implementing a new lib that implements the whole thing and its a huge task). This is a good point. I'm carefully pulling this particular thread, trying not to unweave the whole tapestry, because it does seem

Re: [elixir-core:10046] ISO 8601 ordinal dates

2021-02-03 Thread Kip
I think its important to be careful on the scope. The ISO8601 spec is vast (I am implementing a new lib that implements the whole thing and its a huge task) . > "I think we should probably consider this a bug, and fix functions which parse ISO-8601 dates so that they support what's allowed in

Re: [elixir-core:10045] ISO 8601 ordinal dates

2021-02-03 Thread Christopher Keele
WIP PR available here: https://github.com/elixir-lang/elixir/pull/10687 I've proved the concept, but want to step back and solicit feedback, get some discussion going on explicit points I call out in the PR, and think of ways to clean the implementation up a little. On Wednesday, February 3,

Re: [elixir-core:10043] ISO 8601 ordinal dates

2021-02-03 Thread Bruce Tate
+1 On Wed, Feb 3, 2021 at 2:54 PM Christopher Keele wrote: > As observed by @ryanbigg on Twitter > , *"2021-034"* > is a valid ISO 8601 date. > > Specifically, it is an ordinal date >

Re: [elixir-core:10042] ISO 8601 ordinal dates

2021-02-03 Thread Paul Schoenfelder
I think the gotcha here is that there are various "profiles" of ISO-8601, and the one we typically think of as ISO-8601 in practice is the W3C profile used on the web (see https://www.w3.org/TR/NOTE-datetime for a description of what that profile includes). The other common profile is RFC-3339

[elixir-core:10042] ISO 8601 ordinal dates

2021-02-03 Thread Christopher Keele
As observed by @ryanbigg on Twitter , *"2021-034"* is a valid ISO 8601 date. Specifically, it is an ordinal date descriptor of the format -DDD. Unlike some