Skip to content

[Rust] Release 0.58.0

Choose a tag to compare

@github-actions github-actions released this 25 Sep 13:47
· 88 commits to master since this release
ad33f36

Added

  • backend = Pyo3 on #[jsonschema::validator], generating a validator that reads Python objects in place.
  • backend = Magnus on #[jsonschema::validator], generating a validator that reads Ruby objects in place.
  • jsonschema::meta::pyo3, the bundled meta-schema validators for a schema held as a Python object.
  • jsonschema::meta::magnus, the bundled meta-schema validators for a schema held as a Ruby object.
  • methods = { ... } on #[jsonschema::validator], selecting which of is_valid, validate, and iter_errors are generated.
  • json::Jsonb, validating a Postgres jsonb value in place, behind the jsonb feature.

Performance

  • oneOf and anyOf whose branches each require a property fixed to a distinct string validate only the branch matching the instance's value.
  • Generated validate checks required in the same pass over an object as properties, instead of looking up each required name.

Fixed

  • A oneOf over $ref branches beside a sibling none of them admits, which canonicalized to an allOf instead of false.
  • multipleOf incorrectly accepted 1e-400 and other magnitudes below the smallest f64 subnormal with arbitrary-precision (they are not zero).
  • Numeric keywords panicked on a custom representation holding a number past f64 without arbitrary-precision.