Was I supposed to be able to create a question on the website using 'runserver'?

2020-11-11 Thread Carlos Henrique
I'm following this Django tutorial. So far I haven't had an issue so far, but now I'm not really sure if I understood it correctly. We created a shortcut function to create questions, but I thought that it was meant

Re: Was I supposed to be able to create a question on the website using 'runserver'?

2020-11-11 Thread Jorge Gimeno
That's a helper function to get the Question instances you need for testing. It's a way to query for those questions without repeating the same code over and over in tests. -Jorge On Wed, Nov 11, 2020 at 5:56 AM Carlos Henrique < carloshenrique...@poli.ufrj.br> wrote: > I'm following this >

Re: No ID Error

2020-11-11 Thread Jorge Gimeno
Without any more context, a Google search brought up this: https://stackoverflow.com/questions/55834107/django-template-library-invalidtemplatelibrary-invalid-template-library-specifi. Hopefully that is helpful. We would need the full trackback and the file where the error occurred to be able to o

Re: Deploying an app on heroku

2020-11-11 Thread grav...@gmail.com
Please anyone share me material how to deploye application in django On Wednesday, November 4, 2020 at 3:04:10 AM UTC+5:30 achraf1...@gmail.com wrote: > thanks a lot man i already deployed it but thanks i appreciate it > > > Le sam. 31 oct. 2020 à 23:54, Ayser shuhaib a > écrit : > >> pleas

Re: Deploying an app on heroku

2020-11-11 Thread programmer 262
i'm talking that all my static files are been deleted after dynos are asleep Le samedi 31 octobre 2020 à 23:54:22 UTC+1, embedded...@gmail.com a écrit : > please set debug value to True then deploy, that will allow us to see what > is causing the server error > > On Sun, Nov 1, 2020 at 12:46 AM

Re: Deploying an app on heroku

2020-11-11 Thread Kelvin Sajere
Off the bat, what I see is that your domain is not among the allowed hosts in your settings.py file. Do that first and we'll go from there. On Sat, Oct 31, 2020, 6:46 PM programmer 262 wrote: > hy guys i want to deploy my app on heroku and i having a bad time this is > the website that i deploye

django adding element to list

2020-11-11 Thread rssail
I'm confused with how django adds elements to a list. consider the following: def add(request): if request.method == "POST": form = NewTaskForm(request.POST) if form.is_valid(): task = form.cleaned_data["task"] request.sessio

getting 404 page not found on part 3 of the tutorial

2020-11-11 Thread George P. Olson
Hi guys, New here to django. Going through the tutorial, on part 3, I set up the mysite/polls/urls.py file  like this according to the instructions: - from django.urls import path from . import views urlpatterns = [     # ex: /polls/     path('', views.index, name='index'),     # ex: /poll

test

2020-11-11 Thread rssail
message not posting -- 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://

adding element to session list

2020-11-11 Thread rssail
I'm confused with how django adds elements to a list. consider the following: def add(request): if request.method == "POST": form = NewTaskForm(request.POST) if form.is_valid(): task = form.cleaned_data["task"] request.session['tasks'].append(

Re: getting 404 page not found on part 3 of the tutorial

2020-11-11 Thread Clive Bruton
On 11 Nov 2020, at 23:37, George P. Olson wrote: So when I go to this url: http://127.0.0.1:8000/polls/ Although the urlpatterns below shows "# ex: /polls/", the defined path has no path elements, so you just need: http://127.0.0.1:8000/ I think. urlpatterns = [ # ex: /polls/

Re: getting 404 page not found on part 3 of the tutorial

2020-11-11 Thread George Olson
I don't quite follow your note there of just going to: http://127.0.0.1:8000/ without the app name 'polls' following. I believe you have to put the app name following that. It was working before with http://127.0.0.1:8000/polls/, but then I did something and tried to backtrack and the whole syst

Re: getting 404 page not found on part 3 of the tutorial

2020-11-11 Thread Clive Bruton
Sorry, I just checked my version of the tutorial, you load the manage.py through the directory "mysite", and "polls" is in a sub- directory. The way you showed the "/polls/urls.py" implied that was the only file, where in fact the root app/settings are at "/mysite/ settings.py" and urls at "/