From c39e43b714258fc2d3bdb887fd25203810da8f23 Mon Sep 17 00:00:00 2001 From: Jon Duckworth Date: Tue, 22 Feb 2022 10:17:09 -0500 Subject: [PATCH] Suppress extlink warnings --- docs/conf.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/docs/conf.py b/docs/conf.py index 65f2f805c..806900bdc 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -17,6 +17,8 @@ import subprocess from typing import Any, Dict, List +from sphinx.util import logging + sys.path.insert(0, os.path.abspath(".")) sys.path.insert(0, os.path.abspath("../")) from pystac.version import __version__, STACVersion # noqa:E402 @@ -237,3 +239,11 @@ # -- Substutition variables rst_epilog = f".. |stac_version| replace:: {STACVersion.DEFAULT_STAC_VERSION}" + +# -- Suppress warnings from the extlinks extension +# We do this to avoid warnings like the following in our Jupyter notebook tutorials +# where we do not want to use Sphinx constructs: +# WARNING: hardcoded link 'https://github.com/stac-extensions/eo' could be replaced +# by an extlink (try using ':stac-ext:`eo`' instead) +linklogger = logging.getLogger('sphinx.ext.extlinks') +linklogger.setLevel(40) # Ignore messages less severe than ERROR \ No newline at end of file