Invalid template name in 'extends' tag: ''. Got this from the 'baseX.html' variable.
The first line in index.html is: {% extends baseX.html %} I got this error when trying out a new template package I bought. I thought it was telling me something was wrong with the name of the base template being extended, but changing the name numerous times always brings the same error. I tried using a functional view instead, but I still got the same error. Debug Toolbar says: Templates > > index.html > /home/malikarumi/Projects/cannon/jamf/static/index.html > ▶ Toggle context > None > <unknown source> > That's when I figured out that the error was with baseX itself. The traceback points to line 141 in loader_tags.py, which is the get_parent function: def get_parent(self, context): parent = self.parent_name.resolve(context) if not parent: error_msg = "Invalid template name in 'extends' tag: %r." % parent if self.parent_name.filters or\ isinstance(self.parent_name.var, Variable): error_msg += " Got this from the '%s' variable." %\ self.parent_name.token raise TemplateSyntaxError(error_msg) if isinstance(parent, Template): # parent is a django.template.Template return parent if isinstance(getattr(parent, 'template', None), Template): # parent is a django.template.backends.django.Template return parent.template return self.find_template(parent, context) Both baseX and index are in the same folder. Somehow Django has decided my baseX is not a django.template.django.Template. I don't know what makes a template qualify as a django.Template, and wasn't able to find anything on that. baseX is a pre-made template I liked and bought online. The designer doesn't know anything about Django. As far as I can tell, it is just html, css, and javascript, like any other template. It is bootstrap, just like the template I was using before. I have searched around, there's lots of stuff about templates in general, but I haven't found anything on this particular issue. I did come across django-bootstrap3, but I see no reason why that's required to use bootstrap. I didn't have it with the previous bootstrap theme I was using and that worked. Your insights appreciated. ubuntu 15.10, Python 2.7.10, Django 1.9.1, Bootstrap 3.3.6 -- 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 post to this group, send email to django-users@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/6c528bab-c13e-4a37-8fab-eb6bfd11c263%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.