Fix doc build
Starting in Django 1.7, standalone scripts, such as a sphinx build require that django.setup() be called first. See: https://docs.djangoproject.com/en/1.8/releases/1.7/#standalone-scripts This should be added to the horizon/docs/source/conf.py setenv DJANGO_SETTINGS_MODULE for docs env in tox.ini is no longer needed as it is configured in doc/source/conf.py. Change-Id: I910dae37770ab9767689918a0c61b78d9c56115a
This commit is contained in:
parent
525b76dc32
commit
b0a2a39508
|
@ -13,8 +13,12 @@
|
||||||
|
|
||||||
import os
|
import os
|
||||||
|
|
||||||
|
import django
|
||||||
|
|
||||||
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'openstack_auth.tests.settings')
|
os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'openstack_auth.tests.settings')
|
||||||
|
|
||||||
|
django.setup()
|
||||||
|
|
||||||
# If extensions (or modules to document with autodoc) are in another directory,
|
# If extensions (or modules to document with autodoc) are in another directory,
|
||||||
# add these directories to sys.path here. If the directory is relative to the
|
# add these directories to sys.path here. If the directory is relative to the
|
||||||
# documentation root, use os.path.abspath to make it absolute, like shown here.
|
# documentation root, use os.path.abspath to make it absolute, like shown here.
|
||||||
|
|
Loading…
Reference in New Issue