Update to Tutorial 4 - Generic Views

31 views
Skip to first unread message

Dan Cox

unread,
Mar 11, 2022, 9:19:17 AM3/11/22
to Django users
Hi I've been searching on how I might contribute to the tutorials but I can't seem to find a way. If you could help me there I could take this question to a potentially more useful place.

Anyway; I am pretty new to Django but I've been following the tutorials and in the Generic Views section here: https://docs.djangoproject.com/en/4.0/intro/tutorial04/

I beleive that there is a missing import statement in the urls.py file:
from django.views.generic import TemplateView

I was scratching my head trying to work out why I was getting errors and upon adding that (which I found in the more general documentation on Views) everything worked.

Cheers,

Dan.

Antonis Christofides

unread,
Mar 11, 2022, 10:48:20 AM3/11/22
to django...@googlegroups.com

Hello,

why do you say that importing of TemplateView is missing? I don't see TemplateView being used anywhere in that page.

Regards,

Antonis

Antonis Christofides
+30-6979924665 (mobile)
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/9869e767-7255-40e4-839e-fdcb6d834257n%40googlegroups.com.

Heman Okumbo

unread,
Mar 11, 2022, 11:43:53 AM3/11/22
to django...@googlegroups.com
on your way towards becoming a great developer.

Reply all
Reply to author
Forward
0 new messages