Gi60s / openapi-enforcer

Apache License 2.0
94 stars 22 forks source link

Using example with a byte field causes exception #128

Closed phillim1 closed 2 years ago

phillim1 commented 2 years ago

Firstly, Thanks for resolving the previous issue I logged. This issue does not look as if it is a similar syntax issue.

When validating the attached attached OAS3 file using openapi-enforcer 1.15.4 we receive an exception as:

Note that if the example in the last line of the attached file is removed then the exception does not occur during validation.

Similarly, if the format: byte is removed and the example is retained then the exception does not occur during validation.

Attached file: openapi.yaml.txt

Gi60s commented 2 years ago

Nice catch. Thank you for providing all of the necessary information to replicate the error. I've published a fix to npm as version 1.15.5.

Also, I'm glad I could help with the previous issue too. 😃