Re: while going through the django tutorial i commited a error and because of which i cannot execute the python manage.py runserver. The errors are attached below

2018-05-08 Thread Avitab Ayan Sarmah
Sure On Tue 8 May, 2018, 12:08 AM Jani Tiainen, wrote: > Also next time please post exceptions as a text. Images are really hard to > read specially on mobile device. > > ma 7. toukokuuta 2018 klo 20.34 Avitab Ayan Sarmah > kirjoitti: > >> i got the error thank you. It was a simple error i forg

M2M Magic Accessors without explicit ManyToMany Field

2018-05-08 Thread Clayton D
I posted a question on SO (https://stackoverflow.com/q/50222402/1978687), but it's been viewed very few times so I'm hoping this is the right place to get attention from those "in the know". The complete question (and progress so far) is documented on SO so that's probably the best place to an

can you check what is wrong with def vote(request, question_id), i am not able to run server. The exceptions and my views.py code are wrriten below:

2018-05-08 Thread Avitab Ayan Sarmah
Views.py: from django.shortcuts import get_object_or_404, render from django.http import HttpResponseRedirect from django.urls import reverse from django.views import generic from . models import Choice, Question class IndexView(generic.ListView): template_name = 'polls/index.html' context_obje

RE: can you check what is wrong with def vote(request, question_id), i am not able to run server. The exceptions and my views.py code are wrriten below:

2018-05-08 Thread Matthew Pava
Hi Avitab, The exception message tries to explain it to you. “IndentationError: unindent does not match any outer indentation level” Python expects perfect whitespace with your code, and you can’t mix spaces with tabs. In your view function, you are indenting with 4 spaces most of the time, but y

While going through Django tutorial i commited an error because of which i am not able to execute python manage.py runserver. The exceptions and codes are mentioned below: In exception it is mentioned

2018-05-08 Thread Avitab Ayan Sarmah
Exceptions: PS C:\Users\AVITABAYAN\mysite> python manage.py runserver Performing system checks... System check identified no issues (0 silenced). May 08, 2018 - 22:00:28 Django version 2.0.1, using settings 'mysite.settings' Starting development server at http://127.0.0.1:8000/ Quit the server wi

Re: While going through Django tutorial i commited an error because of which i am not able to execute python manage.py runserver. The exceptions and codes are mentioned below: In exception it is menti

2018-05-08 Thread Julio Biason
Your problem is your urls.py: django.urls.exceptions.NoReverseMatch: Reverse for 'detail' with arguments '(1,)' not found. 1 pattern(s) tried: ['\\ wrote: > Exceptions: > > PS C:\Users\AVITABAYAN\mysite> python manage.py runserver > Performing system checks... > > System check identified no issue

Re: While going through Django tutorial i commited an error because of which i am not able to execute python manage.py runserver. The exceptions and codes are mentioned below: In exception it is menti

2018-05-08 Thread Avitab Ayan Sarmah
Wait I am sharing my URLs.py On Tue 8 May, 2018, 10:09 PM Julio Biason, wrote: > Your problem is your urls.py: > > django.urls.exceptions.NoReverseMatch: Reverse for 'detail' with arguments > '(1,)' not found. 1 pattern(s) tried: ['\\ > You are looking for a URL named "details" which accepts 1 n

Re: While going through Django tutorial i commited an error because of which i am not able to execute python manage.py runserver. The exceptions and codes are mentioned below: In exception it is menti

2018-05-08 Thread Avitab Ayan Sarmah
polls/urls.py: from django.urls import path from . import views app_name = 'polls' urlpatterns = [ # ex: /polls/ path('', views.IndexView.as_view(), name='index'), path('/results/', views.ResultsView.as_view(), name='results'), path('/vote/', views.vote, name='vote'), ] On Tuesday, May 8, 2018

Re: While going through Django tutorial i commited an error because of which i am not able to execute python manage.py runserver. The exceptions and codes are mentioned below: In exception it is menti

2018-05-08 Thread C. Kirby
You are missing a closing '>' in your detail url On Tuesday, May 8, 2018 at 12:42:20 PM UTC-4, Avitab Ayan Sarmah wrote: > > polls/urls.py: > > from django.urls import path > > from . import views > > app_name = 'polls' > urlpatterns = [ > # ex: /polls/ > path('', views.IndexView.as_view(), name='

Re: While going through Django tutorial i commited an error because of which i am not able to execute python manage.py runserver. The exceptions and codes are mentioned below: In exception it is menti

2018-05-08 Thread Avitab Ayan Sarmah
Please mention where exactly I missed > On Tue 8 May, 2018, 10:19 PM C. Kirby, wrote: > You are missing a closing '>' in your detail url > > On Tuesday, May 8, 2018 at 12:42:20 PM UTC-4, Avitab Ayan Sarmah wrote: >> >> polls/urls.py: >> >> from django.urls import path >> >> from . import views

Re: While going through Django tutorial i commited an error because of which i am not able to execute python manage.py runserver. The exceptions and codes are mentioned below: In exception it is menti

2018-05-08 Thread Avitab Ayan Sarmah
please mention where exactly i am missing >? On Tuesday, May 8, 2018 at 10:18:43 PM UTC+5:30, C. Kirby wrote: > > You are missing a closing '>' in your detail url > > On Tuesday, May 8, 2018 at 12:42:20 PM UTC-4, Avitab Ayan Sarmah wrote: >> >> polls/urls.py: >> >> from django.urls import path >>

Re: While going through Django tutorial i commited an error because of which i am not able to execute python manage.py runserver. The exceptions and codes are mentioned below: In exception it is menti

2018-05-08 Thread C. Kirby
Seriously? path('/', views.DetailView.as_view(), name='detail'), You have posted several time in the last two days and every issue you have had has been a typo. People on this board are happy to help with django issues, but you should be really using an IDE that will catch at least some of the

Re: While going through Django tutorial i commited an error because of which i am not able to execute python manage.py runserver. The exceptions and codes are mentioned below: In exception it is menti

2018-05-08 Thread Avitab Ayan Sarmah
Thank you Kirby I found the error and now my code is running fine. Thanks again On Tue 8 May, 2018, 10:26 PM C. Kirby, wrote: > Seriously? > > path(' Should be > path('/', views.DetailView.as_view(), name='detail'), > > You have posted several time in the last two days and every issue you have >

Re: M2M Magic Accessors without explicit ManyToMany Field

2018-05-08 Thread Vijay Khemlani
Why would it be a muti table inheritance? I would just inherit Car (class MyCar) and add the m2m field there, seems way more explicit and easy to understand too. On Tue, May 8, 2018 at 12:18 PM Clayton D wrote: > I posted a question on SO (https://stackoverflow.com/q/50222402/1978687), > but it

Re: Upgrading from 1.11 to 2.0: "sqlite3.OperationalError: no such table"

2018-05-08 Thread Informatico Neurodesarrollo
Check 1.11 to 2.0 upgrade. You already checked the project configuration and make migrations ?, it could be changed with the upgrade!!! I will hope help you. PD I'm a beginner in Django. El 06/05/18 a las 23:38, Michael Gauland escribió: Just in case anyone else runs into this, I fixed it by s

@mark_safe decorator and filters & tags

2018-05-08 Thread Torsten Bronger
Hallöchen! Up to Django 1.11, I had the following pattern frequently in my code: @register.filter @mark_safe def myfilter(value): ... Smilarly for tags. This has worked for years, however, with Django 2.0, this leads to the TemplateError saying that "myfilter requires 0 argu

Re: sphinx is showing the django base views instead of my own views.py

2018-05-08 Thread Anthony Petrillo
Solved. Thank you again Tony for pointing me in the right direction. Jens Hedegaard Nielsen gave the answer (indirectly) at https://github.com/sphinx-doc/sphinx/issues/4182. There he pointed to autodoc_mock_imports = ["django"] in the Sphinx documentation http://www.sphinx-doc.org/en/stabl