diff --git a/docs/build.py b/docs/build.py index 661c0e28c36..3a1914dfebf 100755 --- a/docs/build.py +++ b/docs/build.py @@ -118,11 +118,16 @@ def do_test(self): def do_strict(self): self.do(['test'], because_of='strict') - self.sphinx_build('dummy', '-W') + self.sphinx_build('dummy', + '--nitpicky', + '--fail-on-warning', + '--keep-going', + '--show-traceback', + ) return None def do_linkcheck(self): - self.sphinx_build('linkcheck', defines=['gen_all_omg_spec_links=False']) + self.sphinx_build('linkcheck', defines=['gen_all_omg_spec_links=0']) return None def do_html(self): diff --git a/docs/sphinx_extensions/links.py b/docs/sphinx_extensions/links.py index 63d321f39c8..dd9e08a3a89 100644 --- a/docs/sphinx_extensions/links.py +++ b/docs/sphinx_extensions/links.py @@ -365,6 +365,7 @@ def spec_sections(self, spec, node, sections): node += section_list def run(self): + debug_links = 'debug-links' in self.options and self.env.app.config.gen_all_omg_spec_links specs_node = nodes.bullet_list() for spec_name, spec in self.env.app.config.omg_specs.items(): spec_node = nodes.list_item() @@ -375,7 +376,7 @@ def run(self): p += nodes.literal('', spec_name) p += nodes.inline('', ')') spec_node += p - if 'debug-links' in self.options and not self.env.app.config.gen_all_omg_spec_links: + if debug_links: self.spec_sections(spec, spec_node, spec['sections']) specs_node += spec_node return [specs_node]