Getting an error when I try to make an html page on django

27 views
Skip to first unread message

Jose

unread,
Jul 19, 2016, 8:15:54 AM7/19/16
to Django users
I was watching a Django tutorial video and on the video the guy writes the exact same code I have on the picture. In the video whats inside of his curly brackets turns to purple. Mine does not turn purple and there is something wrong since I get an error when I run the code. Why is anything I write inside of the curly brackets not turning purple? I suspect that is why I get an error when I run the server and try to open the webpage.


IMG_1726.JPG

ludovic coues

unread,
Jul 19, 2016, 8:53:31 AM7/19/16
to django...@googlegroups.com
How do you "open the webpage" ?
> --
> 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 post to this group, send email to django...@googlegroups.com.
> Visit this group at https://groups.google.com/group/django-users.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/django-users/fea433be-2b86-4a34-a211-6eb1fa53b6bc%40googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.



--

Cordialement, Coues Ludovic
+336 148 743 42

ludovic coues

unread,
Jul 19, 2016, 8:55:21 AM7/19/16
to django...@googlegroups.com
Also, a copy of the error would help us a lot to help you.

Jose

unread,
Jul 19, 2016, 11:20:09 AM7/19/16
to Django users
Thank you for your quick response. I just run the local server after writing all of the files in visual studio. Somehow when I say /artists/2 I get that error but when I say /artists/3 I get the other artist. I think it may be something about the way I created the artists in the Django shell? I cannot retrieve all of that code because the shell got closed but it seemed to save all of the artists I wrote. I had made an Album object and passed in an artist name, so I would expect to have a third artist object with some album, but this one is not showing up. Thank you in advance!
IMG_1735.JPG
Message has been deleted

Sergiy Khohlov

unread,
Jul 19, 2016, 2:23:12 PM7/19/16
to django-users

Looks like you have deleted artist with Id#2.


19 лип. 2016 18:21 "Jose" <narutogl...@gmail.com> пише:


On Tuesday, July 19, 2016 at 8:15:54 AM UTC-4, Jose wrote:
I was watching a Django tutorial video and on the video the guy writes the exact same code I have on the picture. In the video whats inside of his curly brackets turns to purple. Mine does not turn purple and there is something wrong since I get an error when I run the code. Why is anything I write inside of the curly brackets not turning purple? I suspect that is why I get an error when I run the server and try to open the webpage.


--
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 post to this group, send email to django...@googlegroups.com.
Visit this group at https://groups.google.com/group/django-users.

ludovic coues

unread,
Jul 20, 2016, 7:17:52 AM7/20/16
to django...@googlegroups.com
Like it have been said, it look like there is no object with id 2.
If you want more details, you'll need to share the content of your
view function.
> https://groups.google.com/d/msgid/django-users/CADTRxJPNct_1_W6WBEDKjYTYw7w4W2M4%2BQwSeCF191fVrfnvyQ%40mail.gmail.com.
>
> For more options, visit https://groups.google.com/d/optout.



Reply all
Reply to author
Forward
0 new messages