﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
16109	Inconsistency in docs: Leading zero of numbers in URLconf	wegener92@…	nobody	"In [https://docs.djangoproject.com/en/1.3/topics/http/urls/#example], the suggested regex for an article / numbers in a url is

{{{
r'^articles/(\d{4})/(\d{2})/(\d+)/$'
}}}

But in [https://docs.djangoproject.com/en/1.3/ref/models/instances/#django.db.models.permalink], it says

{{{
r'/archive/(?P<year>\d{4})/(?P<month>\d{1,2})/(?P<day>\d{1,2})/$'
}}}

In particular, the first expression allows only 05 for a month, the second 05 and 5, which leads to multiple urls for the same content. Additionally, the example get_absolute_url method wouldn't match the first expression (\d{2}) for dates with month or day below 10.

I first thought this is a ""support issue"", not a bug, so you may want to read my post on [http://stackoverflow.com/questions/6098371/zero-fill-numbers-in-djangos-urlconf stackoverflow.com]. It was recommended to me to submit bug report because of this inconsistency in the docs."	Bug	closed	Documentation	1.3	Normal	fixed			Ready for checkin	1	0	0	0	0	0
