Opened 5 years ago
Closed 5 years ago
#31620 closed New feature (fixed)
Support "%V" format in WeekArchiveView.
Description ¶
#26217 (Docs for WeekArchiveView are misleading about %W) - closed 4 years ago mentioned support for %V week format.
Since python 3.6, %G, %u and %V ISO 8601 formatters were added to strptime
.
WeekArchiveView
should add %V to the list of accepted week formatters. This would require as well the special case to change the year format to %G, or simply ValueError
in _date_from_string
should mention the message passed from datetime.datetime.strptime
:
ISO week directive '%V' is incompatible with the year directive '%Y'. Use the ISO year '%G'.
Change History (7)
comment:1 by , 5 years ago
Summary: | WeekArchiveView '%V' support → Support "%V" format in WeekArchiveView. |
---|---|
Triage Stage: | Unreviewed → Accepted |
Version: | 3.0 → master |
comment:2 by , 5 years ago
Owner: | changed from | to
---|---|
Status: | new → assigned |
follow-up: 4 comment:3 by , 5 years ago
Has patch: | set |
---|---|
Owner: | changed from | to
comment:4 by , 5 years ago
Patch needs improvement: | set |
---|
comment:5 by , 5 years ago
Patch needs improvement: | unset |
---|
comment:6 by , 5 years ago
Triage Stage: | Accepted → Ready for checkin |
---|
Replying to Hasan Ramezani:
Unfortunately the implementation is wrong. ISO weeks start on Monday.
https://en.wikipedia.org/wiki/ISO_week_date