On 03/05/2021 07.34, Doang Mawar wrote:
> Hello Django community,
> 
> I am faced with some error which is preventing me from proceeding with
> learning.
> 
> File "C:\Users\DoangMawarG\Desktop\mysite\book\Bookbank\urls.py", line
> 5, in <module>
>     path('', views.index, name='index'),
> AttributeError: module 'Bookbank.views' has no attribute 'index'
> 
> how can i get around this kind of error?
>

Hi Doang,

First of all, learn how to use a mailing list/forum like this.

Don't highjack unrelated threads like you've done in addition to writing
this (the "Hiring for frontend developer" thread).

Also, try to give your post a relevant subject (not just
django-users@googlegroups.com).

To get to your question, you need to learn how to read error messages
from the python interpreter.

Here it is telling you, that you "views" module doesn't have an "index"
attribute.

What that means is that you most likely have a file called "views.py"
(the module) but there's not a function called "index" there (the
missing attribute).

Look back at your views.py file and at whatever tutorial you are using
for learning and see if that couldn't explain it.

Kind regards,

Kasper Laudrup

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/50d799fc-07d5-0ef2-2e83-9d9fa780fc30%40stacktrace.dk.

Attachment: OpenPGP_signature
Description: OpenPGP digital signature

Reply via email to