https://docs.djangoproject.com/en/1.8/ref/class-based-views/generic-
display/
Under myapps/urls.py in the DetailView
...
{{{
urlpatterns = [
url(r'^(?P<slug>[-_\w]+)/$', ArticleDetailView.as_view(), name
='article-detail'),
]
}}}
The _ is unnecessary, as it's already in \w
The regex should read
{{{
?P<slug>[-\w]+
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/24695>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.
* needs_docs: => 0
* has_patch: 0 => 1
* needs_better_patch: => 0
* needs_tests: => 0
* stage: Unreviewed => Accepted
Comment:
Pull request https://github.com/django/django/pull/4551
--
Ticket URL: <https://code.djangoproject.com/ticket/24695#comment:1>
* status: new => closed
* resolution: => fixed
Comment:
In [changeset:"b9e972b96171236c40a8a922c62d36b49854ee52" b9e972b]:
{{{
#!CommitTicketReference repository=""
revision="b9e972b96171236c40a8a922c62d36b49854ee52"
Fixed #24695 -- Tidied up a couple of regexes in the CBV docs
Thanks datakid for the report
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/24695#comment:2>
Comment (by Tim Graham <timograham@…>):
In [changeset:"415a65fc0ce2bef0dc0f5fa9867005be1baf7961" 415a65fc]:
{{{
#!CommitTicketReference repository=""
revision="415a65fc0ce2bef0dc0f5fa9867005be1baf7961"
[1.8.x] Fixed #24695 -- Tidied up a couple of regexes in the CBV docs
Thanks datakid for the report
Backport of b9e972b96171236c40a8a922c62d36b49854ee52 from master
}}}
--
Ticket URL: <https://code.djangoproject.com/ticket/24695#comment:3>