From a8dbce772ce0a0950cee278cc10f839db821a386 Mon Sep 17 00:00:00 2001 From: Doug Hellmann Date: Wed, 17 Jan 2018 13:34:36 -0500 Subject: [PATCH] treat doc build warnings as errors Turn on the flag to cause documentation build warnings to be treated as errors. Change-Id: I0135d905cc77dfe30b06093d18e0883f8227bd85 Signed-off-by: Doug Hellmann --- setup.cfg | 1 + tox.ini | 5 +---- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/setup.cfg b/setup.cfg index ceef51f9..b4bf4652 100644 --- a/setup.cfg +++ b/setup.cfg @@ -43,6 +43,7 @@ storyboard.plugin.scheduler = token-cleaner = storyboard.plugin.token_cleaner.cleaner:TokenCleaner [build_sphinx] +warning-is-error = 1 source-dir = doc/source build-dir = doc/build all_files = 1 diff --git a/tox.ini b/tox.ini index 1136957a..65c73142 100644 --- a/tox.ini +++ b/tox.ini @@ -29,10 +29,7 @@ deps = -r{toxinidir}/doc/requirements.txt commands = rm -rf doc/html doc/build rm -rf doc/source/apidoc doc/source/api - # NOTE(dhellmann): We cannot use -W with sphinx-build because the - # wsme.sphinxext registers a directive that is already registered - # and that warning causes the build to exit. - sphinx-build -b html doc/source doc/build/html + sphinx-build -W -b html doc/source doc/build/html [testenv:cover] commands = python setup.py testr --coverage --testr-args='{posargs}'