Opened 15 years ago

Closed 15 years ago

#10737 closed (invalid)

Hard to find bug in code created by the tutorial

Reported by: MateusJustino Owned by: nobody
Component: Documentation Version: 1.0
Severity: Keywords: urlpatterns, debug
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


Hi, I just spent hours trying to find a bug. I was in the #django IRC channel and a few people were helping me. We were all stumped. I googled a bit too.

Only after setting up an smtp client was the cause of the bug apparent.

So, I'm asking that the tutorial be updated so that others will not have be so frustrated as I was.
Section: "Write a 404 (page not found) view"

The problem was that my 404.html template was being skipped over and it would throw a 505 error.

This only happened when DEBUG was set to False.

It was caused by the parsing of urlpatterns and no dummy views defined for 'results' and 'vote'.

The views for results and vote were not called, but a 500 error was thrown when they were not defined anywhere and it was actually a 404 for any mistyped URL.
Note: The mistyped URLs that generated the 404s would not match the regexp rules for running the results or vote methods.

Email me if this is not clear.


Change History (1)

comment:1 by Alex Gaynor, 15 years ago

Resolution: invalid
Status: newclosed

This reads like a support request, please use the django-users mailing list for that.

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