Handle removal of WSGIServerException in Django 1.6

``WSGIServerException`` was replaced with ``socket.error`` in Django 1.6.
See https://github.com/django/django/commit/2ca00faa913754cd5860f6e1f23c8da2529c691a

This patch fixes the resulting ImportError and preserves compatibility with older Django versions.