'qr_tags' is not a valid tag library: Template library qr_tags not found
Closed this issue · 2 comments
I installed with
pip install django-qrcode
added 'qrcode' to 'INSTALLED_APPS' in my settings.py
when I try to load {% load qr tags %}, I get the following error:
'qr_tags' is not a valid tag library: Template library qr_tags not found, tried django.templatetags.qr_tags,django.contrib.staticfiles.templatetags.qr_tags,django.contrib.admin.templatetags.qr_tags
Note: I using python 2.7 and django 1.4.22
Thanks
Can't reproduce
Found the solution...but not the reason why...
Hello.
I ran into the same issue. I am reusing some code from another project I had which was using Django 1.96 and Python 3.4.3 and everything was working great. When I tried the same code in Django 1.10 and Python 3.5.2 I got django.template.exceptions.TemplateSyntaxError: 'qr_tags' is not a registered tag library.
.
So, I checked the files in '/home/(my_name)/.virtualenvs/(my_virtualenv)/lib/python3.5/site-packages/qrcode/' , and compared the files to my other project. The folders "templates", and "templatetages" were missing. I copied them from the other project and put them into the new project's qrcode folder and its works.
I used Pip install qrcode to install the app. Not sure why it didn't install those critical folders.
Hope that helps
Great app by the way.