Opened 13 years ago
Last modified 13 years ago
#10544 new enhancement
Support better readable date/time format instead of/in addition to strict ISO 8601
Reported by: | Owned by: | ||
---|---|---|---|
Priority: | normal | Milestone: | unscheduled |
Component: | general | Version: | 0.13dev |
Severity: | normal | Keywords: | datetime iso8601 |
Cc: | Branch: | ||
Release Notes: | |||
API Changes: | |||
Internal Changes: |
Description
I like the new ISO 8601 date/time format in Trac 0.13, e.g. in the revision log:
@7207 2008-06-13T10:49:32+02:00 cboos 0.10.5dev: merged [7205:7206] from 0.11-stable (escaping issue #7332)
IMHO, this is difficult to read. It would be nice to support a less strict format, e.g.:
@7207 2008-06-13 10:49:32 cboos 0.10.5dev: merged [7205:7206] from 0.11-stable (escaping issue #7332)
I.e. replace the T
with a space and maybe leave out the time zone. This format is widely used, I think.
Attachments (0)
Change History (2)
follow-up: 2 comment:1 by , 13 years ago
Keywords: | datetime iso8601 added |
---|---|
Milestone: | 0.13 → unscheduled |
comment:2 by , 13 years ago
Replying to cboos:
Well, if you leave out the timezone, you could as well leave out the time itself, as it become meaningless. No, what would be needed is to convert the time in a given timezone to the corresponding UTC time, and indicate that with a Z.
Yes, I like your idea to normalise all time indications to the same timezone. Having a list of e.g. commits with different hours and timezones is indeed useless, because nobody likes to do all the calculations in their head.
IMHO, this should be either UTC or the current users timezone (at the users choice, if possible). However, if all times are normalised, any indication of timezone (Z
or whatever) becomes redundant and I would prefer not to see it.
Remember that while Trac is used in international projects, other Trac users are local SMEs with all developers in the same timezone/office. At least, I know some companies using Trac internally. If the timezone for all users is always the same, and known, the indication of timezone is not necessary, not even the Z
. (Yes, I know, it's the standard, but after twelve years in telco industry I have a somewhat cynical position towards standards or any sacred books.)
Maybe there should be a admin and/or user provided format string? "%Y-%m-%d %H:%MZ"
for you, "%Y-%m-%d %H:%M:%S"
for me, "%Y-%m-%dT%H:%M:%S%z"
for others?
Well, if you leave out the timezone, you could as well leave out the time itself, as it become meaningless. No, what would be needed is to convert the time in a given timezone to the corresponding UTC time, and indicate that with a Z.
The Wikipedia:ISO_8601 page shows the following format as an example:
I'd suggest the ability to select between two flavors of iso8601 format, ISO 8601 (timezone) and ISO 8601 (UTC).
PatchWelcome.