fix missing import of ImproperlyConfigured exception