From 0e100304a7ade61a648afb3ce73f75222609d3e7 Mon Sep 17 00:00:00 2001 From: Sean McGinnis Date: Wed, 10 Apr 2019 07:34:29 -0500 Subject: [PATCH] Switch from oslosphinx to openstackdocstheme The oslosphinx package is not compatible with the current Sphinx 2.0 release. Migration has been happening to openstackdocstheme for some time. To fix build failures for docs and releasenotes jobs, this switches masakari jobs to use openstackdocstheme. Uncapping jsonschema to pass requirements check so it matches global requirements. Change-Id: Ic74e8b075aa67d410617dac3346bf1c903995da7 Signed-off-by: Sean McGinnis --- doc/requirements.txt | 10 ++++++++++ doc/source/conf.py | 7 +++++-- releasenotes/source/conf.py | 6 ++++-- requirements.txt | 2 +- test-requirements.txt | 5 ----- tox.ini | 3 +++ 6 files changed, 23 insertions(+), 10 deletions(-) create mode 100644 doc/requirements.txt diff --git a/doc/requirements.txt b/doc/requirements.txt new file mode 100644 index 00000000..2a03ed65 --- /dev/null +++ b/doc/requirements.txt @@ -0,0 +1,10 @@ +# The order of packages is significant, because pip processes them in the order +# of appearance. Changing the order has an impact on the overall integration +# process, which may cause wedges in the gate later. +sphinx!=1.6.6,!=1.6.7,>=1.6.2 # BSD +openstackdocstheme>=1.24.0 # Apache-2.0 +os-api-ref>=1.4.0 # Apache-2.0 +sphinxcontrib-apidoc>=0.2.0 # BSD + +# releasenotes +reno>=2.5.0 # Apache-2.0 diff --git a/doc/source/conf.py b/doc/source/conf.py index 0e3cc54a..70d4e194 100755 --- a/doc/source/conf.py +++ b/doc/source/conf.py @@ -22,9 +22,8 @@ sys.path.insert(0, os.path.abspath('../')) # Add any Sphinx extension module names here, as strings. They can be # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom ones. extensions = [ + 'openstackdocstheme', 'sphinx.ext.autodoc', - #'sphinx.ext.intersphinx', - 'oslosphinx', 'ext.versioned_notifications' ] @@ -59,6 +58,10 @@ pygments_style = 'sphinx' # html_theme_path = ["."] # html_theme = '_theme' # html_static_path = ['static'] +html_theme = 'openstackdocs' + +# openstackdocstheme optionns +repository_name = 'openstack/masakari' # Output file base name for HTML help builder. htmlhelp_basename = '%sdoc' % project diff --git a/releasenotes/source/conf.py b/releasenotes/source/conf.py index 25b98cd1..38aa8e22 100644 --- a/releasenotes/source/conf.py +++ b/releasenotes/source/conf.py @@ -38,7 +38,7 @@ # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom # ones. extensions = [ - 'oslosphinx', + 'openstackdocstheme', 'reno.sphinxext', ] @@ -102,12 +102,14 @@ pygments_style = 'sphinx' # If true, keep warnings as "system message" paragraphs in the built documents. # keep_warnings = False +# openstackdocstheme options +repository_name = 'openstack/masakari' # -- Options for HTML output ---------------------------------------------- # The theme to use for HTML and HTML Help pages. See the documentation for # a list of builtin themes. -html_theme = 'default' +html_theme = 'openstackdocs' # Theme options are theme-specific and customize the look and feel of a theme # further. For a list of options available for each theme, see the diff --git a/requirements.txt b/requirements.txt index aff54b3d..f3613419 100644 --- a/requirements.txt +++ b/requirements.txt @@ -4,7 +4,7 @@ Babel!=2.4.0,>=2.3.4 # BSD iso8601>=0.1.11 # MIT -jsonschema<3.0.0,>=2.6.0 # MIT +jsonschema>=2.6.0 # MIT keystoneauth1>=3.4.0 # Apache-2.0 keystonemiddleware>=4.17.0 # Apache-2.0 WebOb>=1.7.1 # MIT diff --git a/test-requirements.txt b/test-requirements.txt index 15450923..ae23692a 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -10,10 +10,7 @@ pep8>=1.5.7 psycopg2>=2.6.2 # LGPL/ZPL PyMySQL>=0.7.6 # MIT License python-subunit>=1.0.0 # Apache-2.0/BSD -sphinx!=1.6.6,!=1.6.7,>=1.6.2 # BSD -openstackdocstheme>=1.18.1 # Apache-2.0 os-api-ref>=1.4.0 # Apache-2.0 -oslosphinx>=4.7.0 # Apache-2.0 oslotest>=3.2.0 # Apache-2.0 stestr>=1.0.0 # Apache-2.0 SQLAlchemy-Utils>=0.33.10 # Apache-2.0 @@ -21,5 +18,3 @@ requests-mock>=1.2.0 # Apache-2.0 testresources>=2.0.0 # Apache-2.0/BSD testscenarios>=0.4 # Apache-2.0/BSD testtools>=2.2.0 # MIT -# releasenotes -reno>=2.5.0 # Apache-2.0 diff --git a/tox.ini b/tox.ini index defb9863..83e303e2 100644 --- a/tox.ini +++ b/tox.ini @@ -73,13 +73,16 @@ commands = coverage xml -o cover/coverage.xml [testenv:docs] +deps = -r{toxinidir}/doc/requirements.txt basepython = python3 commands = python setup.py build_sphinx [testenv:releasenotes] +deps = -r{toxinidir}/doc/requirements.txt basepython = python3 commands = + rm -fr releasenotes/build sphinx-build -a -E -W -d releasenotes/build/doctrees -b html releasenotes/source releasenotes/build/html [testenv:debug]