Django and Django CMS Error

I just did a fresh install of Django and Django-CMS from scratch (including the new virtual version and python build). I get this bizzarre error. Google did not help. Ideas?

TemplateSyntaxError at / Caught AttributeError while rendering: 'str' object has no attribute 'regex' In template /Users/bdunlay/python/python-2.5/lib/python2.5/site-packages/django_cms2.1.0.beta3-py2.5.egg/cms/templates/cms/new.html, error at line 37 

Here's the line:

 37: <li>Log into <a href="{% url admin:index %}">admin</a> and <a href="{% url pages-root %}admin/cms/page/add/">add</a> some pages.</li> 

more things

 /Users/bdunlay/python/python-2.5/lib/python2.5/site-packages/Django-1.3-py2.5.egg/django/core/urlresolvers.py in _populate return '<%s %s (%s:%s) %s>' % (self.__class__.__name__, self.urlconf_name, self.app_name, self.namespace, self.regex.pattern) def _populate(self): lookups = MultiValueDict() namespaces = {} apps = {} for pattern in reversed(self.url_patterns): --> p_pattern = pattern.regex.pattern ... if p_pattern.startswith('^'): p_pattern = p_pattern[1:] if isinstance(pattern, RegexURLResolver): if pattern.namespace: namespaces[pattern.namespace] = (p_pattern, pattern) if pattern.app_name: 
+4
source share
1 answer

Just this mistake. In my case, this was caused by a triple quoted string (comment) in urls.py templates.
In fact, this was not interpreted as a comment and passed to the function!

+16
source

All Articles