From fa78d72d222f69a2624dd41e7ab7a9d2722ef0d7 Mon Sep 17 00:00:00 2001 From: Devid <13779643+sevdog@users.noreply.github.com> Date: Tue, 15 Oct 2024 08:53:13 +0200 Subject: [PATCH] Fix #107 Normalize spec before rendering in new httpdomain renderer --- sphinxcontrib/openapi/renderers/_httpdomain.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sphinxcontrib/openapi/renderers/_httpdomain.py b/sphinxcontrib/openapi/renderers/_httpdomain.py index c6a71a2..5118e15 100644 --- a/sphinxcontrib/openapi/renderers/_httpdomain.py +++ b/sphinxcontrib/openapi/renderers/_httpdomain.py @@ -13,7 +13,7 @@ import sphinx.util.logging as logging import sphinx_mdinclude -from sphinxcontrib.openapi import _lib2to3 as lib2to3 +from sphinxcontrib.openapi import _lib2to3 as lib2to3, utils from sphinxcontrib.openapi.renderers import abc from sphinxcontrib.openapi.schema_utils import example_from_schema @@ -235,6 +235,7 @@ def __init__(self, state, options): def render_restructuredtext_markup(self, spec): """Spec render entry point.""" + utils.normalize_spec(spec, **self._options) if spec.get("swagger") == "2.0": spec = lib2to3.convert(spec)