Code

#18489 closed Uncategorized (invalid)

Unnecessary quotes cause NoReverseMatch Exception

Reported by: sverdlin@… Owned by: nobody
Component: Documentation Version: 1.4
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: yes UI/UX: no

Description

The template for registration/login.html at https://docs.djangoproject.com/en/dev/topics/auth/ has the line:

<form method="post" action="{% url 'django.contrib.auth.views.login' %}">

This causes a NoReverseMatch Exception.

There should be no quotes around django.contrib.auth.views.login to prevent the error.

Attachments (0)

Change History (1)

comment:1 Changed 22 months ago by charettes

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Resolution set to invalid
  • Status changed from new to closed

You are using Django development branch documentation with version 1.4,

The behaviour of the url template tag was changed in the upcoming version. You can read about it here in the Forwards compatibility section.

I'd suggest you add {% load url from future %} at the top of your template, this will ease the migration to 1.5

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.