Opened 8 years ago

Closed 8 years ago

#4844 closed (duplicate)

Writing your first Django app, part 4: last part missing information on how to change "return HttpResponseRedirect...."

Reported by: robvdl Owned by: jacob
Component: Documentation Version: master
Severity: Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:


Hi, I am new to Django and I just went all the way through tutorials parts 1 .. 4 of the latest SVN documentation. I also used the latest SVN of Django.

Everything went smoothly, however I think I noticed one thing missing in the documentation.

The last few paragpraphs of part 4 get you to changeover what you have written so far to generic views. Everything works after the changeover, except the HttpResponseRedirect just after you post a poll generates a NoReverseMatch exception, which it did not before the changeover to generic views. I had a real careful look at the documentation, and I believe it may be missing one piece of information, on changing the following line in your poll view in the vote() method:

return HttpResponseRedirect(reverse('mysite.polls.views.results', args=(,)))

As far as I can see, the documentation does not mention changing this line, but I am sure this is where it is going wrong now. It generates a NoReverseMatch exception. I believe this could be a missing piece of information in the documentation

Change History (1)

comment:1 Changed 8 years ago by SmileyChris

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

Thanks for the report, Rob. This is a dupe of #4615.

Note: See TracTickets for help on using tickets.
Back to Top