Revert "Remove the django.core.handlers.base.BaseHandler monkeypatch."

This reverts commit 1380e8afbb32d0f35c1f06196ee0404e38440ed5.