Description
When starting up a fresh Python interpreter, merely importing graphene_django
raises an exception:
>>> import graphene_django
Traceback (most recent call last):
...
django.core.exceptions.ImproperlyConfigured: Requested setting DEBUG, but settings are not configured. You must either define the environment variable DJANGO_SETTINGS_MODULE or call settings.configure() before accessing settings.
While this doesn't seem like that big a deal (and in the grand scheme of things, it really isn't), it does break a few unexpected things. For example, when I ran into some confusing things in the documentation (see #499), I tried examining the source using pipenv:
$ pipenv open graphene_django
Module not found!
This was super confusing, and admittedly might really be a bug in pipenv, but I assume it thought the module wasn't found because of the ImproperlyConfigured
exception raised by importing graphene_django
.
Anyways, if it's easy to change the package so that its root can be imported without requiring Django settings to be initialized, that would be helpful, but it's probably not really that big a deal if not.