Skip to content

Not support validating fields with the format: email in JSON Schema. #1727

Open
@cobolbaby

Description

@cobolbaby

Description

if self._are_references_provided:
named_schemas = _resolve_named_schema(self._schema, self._registry)
validate(instance=value, schema=self._parsed_schema,
resolver=RefResolver(self._parsed_schema.get('$id'),
self._parsed_schema,
store=named_schemas))
else:
validate(instance=value, schema=self._parsed_schema)

When validating certain special types, modifications to the 'validate' method are required, as shown below:

from jsonschema import validate, ValidationError, RefResolver, Draft202012Validator

validate(instance=value, schema=self._parsed_schema, format_checker=Draft202012Validator.FORMAT_CHECKER)

How to reproduce

Checklist

Please provide the following information:

  • confluent-kafka-python and librdkafka version (v2.3.0 and confluent_kafka.libversion()):
  • Apache Kafka broker version: 5.5.11
  • Client configuration: {'auto.register.schemas': False, 'subject.name.strategy': record_subject_name_strategy}
  • Operating system:
  • Provide client logs (with 'debug': '..' as necessary)
  • Provide broker log excerpts
  • Critical issue

Metadata

Metadata

Assignees

No one assigned

    Labels

    component:schema-registryAny schema registry related isues rather than kafka isolated onesenhancementRequesting a feature change

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions