Skip to content

Formats raise error for other types #66

Closed
@p1c2u

Description

@p1c2u

Given:

schema = {"format": "byte"}

or

schema = {"format": "binary"}

Then:

from openapi_schema_validator import validate
from openapi_schema_validator import OAS30Validator

validate(1.23, schema, cls=OAS30Validator, format_checker=OAS30Validator.FORMAT_CHECKER)

Result:

ValidationError: 1.23 is not a 'byte'

Expected:
It should ignore other types and pass

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions