Bug 255511 - Default datetime_fmt ambiguous
Summary: Default datetime_fmt ambiguous
Status: Closed FIXED
Alias: None
Product: Services
Classification: Unclassified
Component: Wiki (show other bugs)
Version: unspecified
Hardware: Any Any
: --- Affects Some People
Assignee: Cluster Admin
Keywords: easy
Depends on:
Reported: 2021-04-30 09:56 UTC by Jethro Nederhof
Modified: 2021-06-28 12:44 UTC (History)
2 users (show)

See Also:


Note You need to log in before you can comment on or make changes to this bug.
Description Jethro Nederhof 2021-04-30 09:56:51 UTC
I made a change to the Office Hours page to use the DateTime() macro, as this is smart enough to translate datetimes into a user's preferred timezone and date format, which I think would be an improvement to just specifying times in UTC.

Unfortunately, for users that don't have a preference configured, the default shows the timestamp in UTC but doesn't indicate which timezone the timestamp is in. This is unintentionally ambiguous.


I propose updating the moin configuration for datetime_fmt (see https://wiki.freebsd.org/HelpOnConfiguration#style) to include the %Z or %z format strings (see https://docs.python.org/2.7/library/datetime.html#strftime-strptime-behavior) so the default behaviour is not ambiguous for users.
Comment 1 Kubilay Kocak freebsd_committer freebsd_triage 2021-05-03 03:54:57 UTC
As discussed on Discord, we'll go with 8601 and include seconds, as moin's default includes it:

Comment 2 Kubilay Kocak freebsd_committer freebsd_triage 2021-05-03 03:58:31 UTC
wikiconfig.py is managed.

@Cluster, please:

 1) Update wiki:wikiconfig.py, appending:

# Override default time format, showing timezone
datetime_fmt = '%Y-%m-%dT%H:%M:%S%z'

 2) Delete wikiconfig.pyc to apply changes
Comment 3 Philip Paeps freebsd_committer 2021-06-28 12:44:31 UTC
Committed to admin-svn in r13204.