summaryrefslogtreecommitdiffstats
path: root/meta/recipes-devtools/python/python3-jsonschema/d71f96a6523875c9694fcdf468c9f458323d07f2.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-devtools/python/python3-jsonschema/d71f96a6523875c9694fcdf468c9f458323d07f2.patch')
-rw-r--r--meta/recipes-devtools/python/python3-jsonschema/d71f96a6523875c9694fcdf468c9f458323d07f2.patch44
1 files changed, 0 insertions, 44 deletions
diff --git a/meta/recipes-devtools/python/python3-jsonschema/d71f96a6523875c9694fcdf468c9f458323d07f2.patch b/meta/recipes-devtools/python/python3-jsonschema/d71f96a6523875c9694fcdf468c9f458323d07f2.patch
deleted file mode 100644
index 65cc2b4cf0..0000000000
--- a/meta/recipes-devtools/python/python3-jsonschema/d71f96a6523875c9694fcdf468c9f458323d07f2.patch
+++ /dev/null
@@ -1,44 +0,0 @@
1From d71f96a6523875c9694fcdf468c9f458323d07f2 Mon Sep 17 00:00:00 2001
2From: Julian Berman <Julian@GrayVines.com>
3Date: Thu, 17 Oct 2024 09:36:35 -0400
4Subject: [PATCH] Fix the annotation for validator_for's default.
5
6This still doesn't seem to satisfy mypy, so tell it to be quiet.
7
8Upstream-Status: Backport [https://github.com/python-jsonschema/jsonschema/commit/d71f96a6523875c9694fcdf468c9f458323d07f2]
9Signed-off-by: Khem Raj <raj.khem@gmail.com>
10---
11 jsonschema/validators.py | 6 +++---
12 1 file changed, 3 insertions(+), 3 deletions(-)
13
14diff --git a/jsonschema/validators.py b/jsonschema/validators.py
15index 85c39160..b8ca3bd4 100644
16--- a/jsonschema/validators.py
17+++ b/jsonschema/validators.py
18@@ -857,7 +857,7 @@ def extend(
19 version="draft2020-12",
20 )
21
22-_LATEST_VERSION = Draft202012Validator
23+_LATEST_VERSION: type[Validator] = Draft202012Validator
24
25
26 class _RefResolver:
27@@ -1334,7 +1334,7 @@ def validate(instance, schema, cls=None, *args, **kwargs): # noqa: D417
28
29 def validator_for(
30 schema,
31- default: Validator | _utils.Unset = _UNSET,
32+ default: type[Validator] | _utils.Unset = _UNSET,
33 ) -> type[Validator]:
34 """
35 Retrieve the validator class appropriate for validating the given schema.
36@@ -1396,7 +1396,7 @@ class is returned:
37 DefaultValidator = _LATEST_VERSION if default is _UNSET else default
38
39 if schema is True or schema is False or "$schema" not in schema:
40- return DefaultValidator
41+ return DefaultValidator # type: ignore[return-value]
42 if schema["$schema"] not in _META_SCHEMAS and default is _UNSET:
43 warn(
44 (