From c53041ae3b8ded4ac4c3fc745be6bc695b9f0c78 Mon Sep 17 00:00:00 2001 From: Harry Mellor <19981378+hmellor@users.noreply.github.com> Date: Sat, 27 Jul 2024 05:47:33 +0100 Subject: [PATCH] [Doc] Add missing mock import to docs `conf.py` (#6834) --- .readthedocs.yaml | 1 + docs/source/conf.py | 2 ++ 2 files changed, 3 insertions(+) diff --git a/.readthedocs.yaml b/.readthedocs.yaml index 428e19908858..f1959ad2743f 100644 --- a/.readthedocs.yaml +++ b/.readthedocs.yaml @@ -10,6 +10,7 @@ build: sphinx: configuration: docs/source/conf.py + fail_on_warning: true # If using Sphinx, optionally build your docs in additional formats such as PDF formats: diff --git a/docs/source/conf.py b/docs/source/conf.py index f4cec05663fc..b867bfd89dc1 100644 --- a/docs/source/conf.py +++ b/docs/source/conf.py @@ -94,6 +94,7 @@ def setup(app): # Mock out external dependencies here, otherwise the autodoc pages may be blank. autodoc_mock_imports = [ + "aiohttp", "cpuinfo", "torch", "transformers", @@ -141,5 +142,6 @@ intersphinx_mapping = { } autodoc_preserve_defaults = True +autodoc_warningiserror = True navigation_with_keys = False