Django 1.7 compatibility

More info: https://docs.djangoproject.com/en/dev/releases/1.7/#standalone-scripts