views:

173

answers:

1

I am moving my Django app from v1.1 to v1.2.1

However I am stuck on a TemplateSyntax error as seen below. I have not made any other changes to my app

TemplateSyntaxError at /

Caught ImportError while rendering: No module named urls

None of my url reverses in the template seem to work. Here is the culprit line:

<a href="{% url myapp.views.index %}">{% trans 'Home' %}</a></div>

It looks like the Template context can't find the url resolver. Here is how my settings look like:

    ...

    ROOT_URLCONF = 'myproject.urls'

    TEMPLATE_DIRS = (
               os.path.join(PROJECT_DIR, 'templates'),
    )

    INSTALLED_APPS = (
        'django.contrib.auth',
        'django.contrib.contenttypes',
        'django.contrib.sessions',
        'django.contrib.humanize',
        'django.contrib.sites',
        'django.contrib.admin',
        'django.contrib.sitemaps',
        'myapp',
    )

    ...
A: 

This one I just got myself after making some (fairly sweeping) changes. I suspect I made a mistake somewhere in a form, template, or view, and Django reports a misleading error... (my pages worked pre-change in 1.2.1)

willem