My Apache config includes the following line:
WSGIScriptAlias /testing /var/www/testing/django.wsgi
and my django.wsgi looks like this:
import os, sys
path = '/var/www'
if path not in sys.path:
sys.path.append(path)
os.environ['DJANGO_SETTINGS_MODULE'] = 'testing.settings'
import django.core.handlers.wsgi
application = django.core.handlers.wsgi.WSGIHandler()
http://example.com/testing/ displays correctly, but http://example.com/testing (without the trailing slash) produces the following error:
Traceback:
File "/usr/lib/python2.5/site-packages/django/core/handlers/base.py" in get_response
78. request.path_info)
Exception Type: TypeError at /testing
Exception Value: 'NoneType' object is not iterable