[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#6132: bug in date: --rfc-3339=TIMESPEC option doesn't print 'T'

From: F. Alexander Njemz
Subject: bug#6132: bug in date: --rfc-3339=TIMESPEC option doesn't print 'T'
Date: Sat, 08 May 2010 10:33:08 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv: Gecko/20100217 Shredder/3.0.3pre

On 05/07/2010 05:55 PM, Eric Blake wrote:
On 05/07/2010 07:25 AM, F. Alexander Njemz wrote:

as evidenced here [1] the slightly ambiguous wording in the RFC 3339 [2]
seems to be the reason that the date utility using the
--rfc3339=TIMESPEC switch formats the date with a space instead of a 'T'.

I was confused as well, so I took the liberty to mail the authors of the
RFC in question. I attached the reply from Mr. Klyne.

There is also a patch attached.
Thanks for the report, and also for the patch.  However, I'm reluctant
to create a date format that we cannot then reparse.  So before we apply
this patch, we would first need a patch to gnulib's getdate.y that
allows parsing of an rfc3339 style with a 'T' instead of a space.

Hi Mr. Blake, hi mailing list,

I'm looking into getdate.y.
Mr. Newman has replied as well (see attachment).

I don't think Mr. Newman's mail applies to the date command, since IMHO date returns a
single field.

What do you think?


F. Alexander Njemz
--- Begin Message --- Subject: Re: rfc3339 is the T mandatory? Date: Fri, 07 May 2010 14:53:27 -0700 If you're representing the date and time as a single field, then the "T" is necessary for compliance with RFC 3339 as Graham stated.

If you're using a multi-field representation where date and time are separate fields, then the field delimiter depends on your higher level field-encoding format. In this case you would reference the full-date and full-time syntax elements from section 5.6 separately (instead of referencing the date-time syntax) and would be compliant with RFC 3339 if you were compliant with those elements.

                - Chris

--On May 7, 2010 13:05:41 +0100 Graham Klyne <address@hidden> wrote:
In short: "yes"

Per section 5.5, the intent in this draft was to specify a timestamp
format using elements from and compatible with 8601, but eliminating as
far as reasonable any variations that could make timestamp data harder to
process. This includes making the 'T' mandatory in date+time values.

# g

F. Alexander Njemz wrote:
Dear Sirs,

there seems to be some confusion about the interpretation of the
following passages
of RFC 3339:
    in section 5.6:
        NOTE: ISO 8601 defines date and time separated by "T".
        Applications using this syntax may choose, for the sake of
        readability, to specify a full-date and full-time separated by
        (say) a space character.
    and in Appendix A:
        ISO 8601 states that the "T" may be omitted under some
        circumstances.  This grammar requires the "T" to avoid ambiguity.

So, what I would like to ask is if the "T" is mandatory for RFC 3339
conformance or not?

Thanks in advance.


F. Alexander Njemz

--- End Message ---

reply via email to

[Prev in Thread] Current Thread [Next in Thread]