module documentation
(source)

Functions to match and parse dates in wiki pages

The following unambigous date forms are supported: * Day by date using: yyyy-mm-dd for example 2017-02-16 * Month using: yyyy-mm for example 2017-02 * Week using: (yy)yyWww or (yy)yy-Www, for example 2017W07, 17W07 or 17-W07 * Day by week using (yy)yyWww(D) or (yy)yy-Www(-D) for example 17-W07-2 for Tuesday * Week and day by week notation can also use Wkyyww(.D) for example wk1707

To avoid confusion between mm/dd, dd/mm and yy-mm notations neither of these is supported and the year should always be given in 4 digits.

When the year is shortened to two digits ("yy") it is always prefixed by "20", so "01" becomes 2001 and "99" becomes 2099. For years starting with 19 (or any other century) the ful four digit year needs to be used.

Notation is based on https://en.wikipedia.org/wiki/ISO_8601. Truncating the year is not supported except for the week notation and separators ("-") are required to avoid matching random other numbers. The "Wkyyww" notation is supported as non-standard alternative.

Weeknumbers follow the iso calendar. However depending on locale Sunday can either be the first day of the starting week or the last day of the ending week. In the weekday notation this is made explicit by using "0" for sunday at the start of the week and "7" for sunday at the end of the week. Thus the dates "W1707.7" and "W1708.0" are the same day.

Class DateRange Undocumented
Class Day No class docstring; 0/2 property, 2/2 methods, 0/1 class method documented
Class Month Undocumented
Class Week Undocumented
Function parse_date Undocumented
Variable date_re Undocumented
def parse_date(date): (source)

Undocumented

date_re = (source)

Undocumented