tango_with_django_19 icon indicating copy to clipboard operation
tango_with_django_19 copied to clipboard

Chapter8 Reverse for 'show_category' with arguments..

Open libincla opened this issue 6 years ago • 6 comments

here is my code(btw, i was completed fork by your digital book ) and it occured the error like the bottom

django.core.urlresolvers.NoReverseMatch: Reverse for 'show_category' with arguments '('',)' and keyword arguments '{}' not found. 1 pattern(s) tried: ['rango/category/(?P<category_name_slug>[\w\-]+)/$']

it confused me three days, i don't know why it happend, and i hope the writer can see it. thanks anyway

libincla avatar Apr 16 '18 03:04 libincla

hi Libincia, what version of Django are you using?

Also, what is the url that was entered to trigger this error? i.e http://127.0.0.1:8000/rango/category/broken/ ??

L

leifos avatar Apr 17 '18 08:04 leifos

my django version is : 1.9.10 and i've already followed your django's version and when i added the rango_template_tags.py and rango/cats.html and added the template tags at the head of base.html , e.x

{% block sidebar_block %} {% get_category_list %} {% endblock %}

when i entered http://127.0.0.1:8000/rango/about ==> it occured the error Reverse for 'show_category' with arguments/..

libincla avatar Apr 17 '18 10:04 libincla

Ok, so it is not the version (as Django 2 changed the package to import for reverse).

Do you have a link to your git repository?

On 17 Apr 2018, at 11:02, libincla [email protected] wrote:

my django version is : 1.9.10 and i've already followed your django's version and when i added the rango_template_tags.py and rango/cats.html and added the template tags at the head of base.html , e.x

{% block sidebar_block %} {% get_category_list %} {% endblock %} when i entered http://127.0.0.1:8000/rango/about http://127.0.0.1:8000/rango/about ==> it occured the error Reverse for 'show_category' with arguments/..

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/leifos/tango_with_django_19/issues/61#issuecomment-381931289, or mute the thread https://github.com/notifications/unsubscribe-auth/AB02B-BbPJpVUFHrC0Cuypzx0ckZtYJdks5tpb3TgaJpZM4TV0Mn.

leifos avatar Apr 17 '18 10:04 leifos

i'll push in two days, thanks any way

libincla avatar Apr 17 '18 10:04 libincla

hi, leifos, sorry for delay , this is the git repo https://github.com/libincla/tango.git btw. my python version is Python 3.6.1 use the virtualenv

libincla avatar Apr 19 '18 00:04 libincla

The same here.

SnorlaxYum avatar Jun 02 '18 16:06 SnorlaxYum