From d6eabef4deeb4632d39aec91a1a83ce9fbe0853a Mon Sep 17 00:00:00 2001 From: Michael Johnson Date: Wed, 12 Oct 2022 16:50:57 +0000 Subject: [PATCH] Fixes compatibility with jsonschema >= 4.16.0 Jsonschema has changed the type of a parameter from a simple tuple to a pyrsistent map object. Since we were passing in the defaults anyway, this patch removes those parameters from the jsonschema call. This makes designate compatible with jsonschema >= 4.16.0. Closes-Bug: #1992677 Change-Id: I9cc94506a63371ad78b204030e5e87339982e9e7 --- designate/schema/resolvers.py | 2 +- .../Fix-jsonschema-4.16.0-compatibility-aa65062bc55552f2.yaml | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) create mode 100644 releasenotes/notes/Fix-jsonschema-4.16.0-compatibility-aa65062bc55552f2.yaml diff --git a/designate/schema/resolvers.py b/designate/schema/resolvers.py index 1b6f453a2..1b5c1ee25 100644 --- a/designate/schema/resolvers.py +++ b/designate/schema/resolvers.py @@ -24,7 +24,7 @@ LOG = logging.getLogger(__name__) class LocalResolver(jsonschema.RefResolver): def __init__(self, base_uri, referrer): - super(LocalResolver, self).__init__(base_uri, referrer, (), True) + super(LocalResolver, self).__init__(base_uri, referrer) self.api_version = None @classmethod diff --git a/releasenotes/notes/Fix-jsonschema-4.16.0-compatibility-aa65062bc55552f2.yaml b/releasenotes/notes/Fix-jsonschema-4.16.0-compatibility-aa65062bc55552f2.yaml new file mode 100644 index 000000000..00d91d485 --- /dev/null +++ b/releasenotes/notes/Fix-jsonschema-4.16.0-compatibility-aa65062bc55552f2.yaml @@ -0,0 +1,4 @@ +--- +fixes: + - | + Fixed designate compatibility with jsonschema >= 4.16.0.