File tree 4 files changed +79
-104
lines changed
4 files changed +79
-104
lines changed Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ def handle_discriminator(
53
53
return
54
54
55
55
try :
56
- validator .resolver . resolve (ref )
56
+ validator ._validate_reference (ref = ref , instance = instance )
57
57
except :
58
58
yield ValidationError (
59
59
f"{ instance !r} reference { ref !r} could not be resolved" ,
Original file line number Diff line number Diff line change 3
3
from typing import Type
4
4
5
5
from jsonschema import _legacy_validators
6
- from jsonschema import _utils
7
6
from jsonschema import _validators
8
- from jsonschema .protocols import Validator
9
7
from jsonschema .validators import Draft202012Validator
10
8
from jsonschema .validators import create
11
9
from jsonschema .validators import extend
10
+ from jsonschema_specifications import REGISTRY as SPECIFICATIONS
12
11
13
12
from openapi_schema_validator import _format as oas_format
14
13
from openapi_schema_validator import _types as oas_types
15
14
from openapi_schema_validator import _validators as oas_validators
16
15
from openapi_schema_validator ._types import oas31_type_checker
17
16
18
17
OAS30Validator = create (
19
- meta_schema = _utils .load_schema ("draft4" ),
18
+ meta_schema = SPECIFICATIONS .contents (
19
+ "http://json-schema.org/draft-04/schema#" ,
20
+ ),
20
21
validators = {
21
22
"multipleOf" : _validators .multipleOf ,
22
23
# exclusiveMaximum supported inside maximum_draft3_draft4
You can’t perform that action at this time.
0 commit comments