Ticket #1796: modpython.patch

File modpython.patch, 765 bytes (added by Ben Slavin <benjamin.slavin@…>, 18 years ago)

Patch to fix this in the modpython handler.

  • django/core/handlers/modpython.py

     
    139139        # now that the environ works we can see the correct settings, so imports
    140140        # that use settings now can work
    141141        from django.conf import settings
     142       
     143        # XXX: (Temporary) workaround for ticket #1796: force early loading of all
     144        # models from installed apps.
     145        from django.db.models.loading import get_models
     146        loaded_models = get_models()
    142147
    143148        # if we need to set up middleware, now that settings works we can do it now.
    144149        if self._request_middleware is None:
Back to Top