Switch to using a WSGI middleware for setting up Djangoappengine - this fixes a threading bug where DJANGO_SETTINGS_MODULE would get lost