0

I am trying to build a chat application using Django and channel. But I am getting not able to get my view file (room.html) My main project name is "techChat" and I have a app called "chat" I ma trying all this code from :- https://channels.readthedocs.io/en/latest/tutorial/part_2.html When i enter the lobby name i get page not found. I also have the asgi file if you take a look at my file structure whose img is below.

Help!

My Code

views.py :-

enter image description here

chat/urls.py (App urls file):-

chat/urls.py (App urls file)

techChat/urls.py (main project urls file)

techChat/urls.py (main project urls file)

My room.html template file:- enter image description here

My index.htm file template enter image description here

This Is How My File Structure Is

My Index Page output :- enter image description here

Now when I Enter the "lobby" in the text box I get Page Not Found Error! enter image description here

rushabh
  • 71
  • 7
  • In techChat/urls.py, have you tried putting "chat/" (with a forward slash) rather than "chat" as the first argument to path() on line 7? – bouteillebleu Sep 04 '20 at 15:24
  • I guess that this is not the error but you should have a template folder and in it you should have your chat folder and there the templates should located. Also please post the code as text and not as pictures. – Ekrem Üçüncü Sep 04 '20 at 17:56

0 Answers0