Releases: Stranger6667/jsonschema
Releases · Stranger6667/jsonschema
[Rust] Release 0.22.2
Fixed
- ECMAScript 262 regex support.
Performance
- Speedup
json-pointer
andrelative-json-pointer
formats validation.
[Python] Release 0.22.2
Fixed
- ECMAScript 262 regex support.
Performance
- Speedup
json-pointer
andrelative-json-pointer
formats validation.
[Rust] Release 0.22.1
Fixed
- Removed
dbg!
macro.
[Rust] Release 0.22.0
Changed
- Extend email validation. #471
- BREAKING: Custom retrievers now receive
&Uri<&str>
instead of&UriRef<&str>
- Bump
once_cell
to1.20
. - Bump
regex
to1.11
.
Fixed
time
format validation (leap seconds and second fractions).duration
format validation.- Panic on root
$id
without base. #547 hostname
format validation (double dot).idn-hostname
format validation. #101
Performance
- Faster building of a validator.
hostname
,date
,time
,date-time
, andduration
formats validation.- Cache regular expressions for
pattern
. #417
[Python] Release 0.22.1
Fixed
- Removed
dbg!
macro.
[Python] Release 0.22.0
Changed
- Extend email validation. #471
Fixed
time
format validation (leap seconds and second fractions).duration
format validation.- Panic on the root
$id
without a base. #547 hostname
format validation (double dot).idn-hostname
format validation. #101
Performance
- Faster building of a validator.
hostname
,date
,time
,date-time
, andduration
formats validation.- Cache regular expressions for
pattern
. #417
[Python] Release 0.21.0
Added
$anchor
support.$recursiveRef
&$recursiveAnchor
support in Draft 2019-09.$dynamicRef
&$dynamicAnchor
support in Draft 2020-12.
Changed
- BREAKING: Treat
$ref
as URI, not URL and additionally normalize them. #454 - BREAKING: Resolve all non-recursive references eagerly.
- BREAKING: Disallow use of fragments in
$id
. #264
Fixed
- Infinite recursion in
unevaluatedProperties
. #420 - Cross-draft validation from newer to older ones.
- Changing base URI in folder.
- Location-independent identifier in remote resource.
- Missing some format validation for Draft 2020-12.
- Incomplete
iri
&iri-reference
validation.
Performance
- Faster validation for
uri
,iri
,uri-reference
, andiri-reference
formats.
[Rust] Release 0.21.0
Important: This release brings a complete rework of reference resolving which deprecates some older APIs.
While backward compatibility is maintained for now, users are encouraged to update their code. See the Migration Guide for details on transitioning to the new API.
Added
$anchor
support.$recursiveRef
&$recursiveAnchor
support in Draft 2019-09.$dynamicRef
&$dynamicAnchor
support in Draft 2020-12.
Changed
- BREAKING: Treat
$ref
as URI, not URL and additionally normalize them. #454 - BREAKING: Resolve all non-recursive references eagerly.
- BREAKING: Disallow use of fragments in
$id
. #264
Deprecated
SchemaResolver
trait andSchemaResolverError
in favor of a simplerRetrieve
that works withBox<dyn std::error::Error>
.
In turn, it also deprecatesValidationOptions::with_resolver
in favor ofValidationOptions::with_retriever
ValidationOptions::with_document
in favor ofValidationOptions::with_resource
.
Fixed
- Infinite recursion in
unevaluatedProperties
. #420 - Cross-draft validation from newer to older ones.
- Changing base URI in folder.
- Location-independent identifier in remote resource.
- Missing some format validation for Draft 2020-12.
- Incomplete
iri
&iri-reference
validation.
Performance
- Faster validation for
uri
,iri
,uri-reference
, andiri-reference
formats.
[Rust] Release 0.20.0
Important: This release includes several deprecations and renames. While backward compatibility is maintained for now, users are encouraged to update their code. See the Migration Guide for details on transitioning to the new API.
Added
- New draft-specific modules for easier version-targeted validation:
jsonschema::draft4
jsonschema::draft6
jsonschema::draft7
jsonschema::draft201909
jsonschema::draft202012
Each module providesnew()
,is_valid()
, andoptions()
functions.
jsonschema::options()
function as a shortcut forjsonschema::Validator::options()
, that allows for customization of the validation process.
Changed
- Make
Debug
implementation forSchemaNode
opaque. - Make
jsonschema::validator_for
and related functions returnValidationError<'static>
in theirErr
variant.
This change makes possible to use the?
operator to return errors from functions where the input schema is defined.
Deprecated
- Rename
CompilationOptions
toValidationOptions
for clarity. - Rename
JSONSchema
toValidator
for clarity. #424 - Rename
JSONPointer
toJsonPointer
for consistency with naming conventions. #424 - Rename
jsonschema::compile
tojsonschema::validator_for
. - Rename
CompilationOptions::compile
toValidationOptions::build
.
Old names are retained for backward compatibility but will be removed in a future release.
Fixed
- Location-independent references in remote schemas on drafts 4, 6, and 7.
[Python] Release 0.20.0
Added
- New draft-specific validator classes:
Draft4Validator
,Draft6Validator
,Draft7Validator
,Draft201909Validator
, andDraft202012Validator
. validator_for
function for automatic draft detection.
Changed
- The
JSONSchema
class has been renamed toValidator
. The old name is retained for backward compatibility but will be removed in a future release.
Deprecated
- The
JSONSchema
class is deprecated. Use thevalidator_for
function or draft-specific validators instead.
You can usevalidator_for
instead ofJSONSchema.from_str
. - Constants
jsonschema_rs.DRAFT4
,jsonschema_rs.DRAFT6
,jsonschema_rs.DRAFT7
,jsonschema_rs.DRAFT201909
, andjsonschema_rs.DRAFT202012
are deprecated in favor of draft-specific validator classes.
Fixed
- Location-independent references in remote schemas on drafts 4, 6, and 7.