networknt / json-schema-validator

A fast Java JSON schema validator that supports draft V4, V6, V7, V2019-09 and V2020-12
Apache License 2.0
822 stars 323 forks source link

Custom Formats are not allowed for types other than Strings #957

Closed gopichandch closed 7 months ago

gopichandch commented 7 months ago

https://github.com/networknt/json-schema-validator/blame/51fd82b420c3abde014f180ea109155de0d36480/src/main/java/com/networknt/schema/FormatValidator.java#L51

I'm trying to implement a custom Format for an integer type. But it doesn't validate if its not of String Type. Is there any reason not to support other types. Or am I missing something? Please let me know if we can remove that check.

gopichandch commented 7 months ago

Thanks a lot @justin-tay @stevehu . May I know when can we get the updated version.

stevehu commented 7 months ago

@gopichandch We usually wait for @justin-tay to update the pom.xml to indicate the next version is ready, as he is actively working on issues and enhancements in his forked repo. I see massive changes since the last release, so let's cut a tag 1.3.2.

@justin-tay, you can create new branches in this repo, and it would be easier to merge between branches. Thanks a lot for your contributions.

https://github.com/networknt/json-schema-validator/releases/tag/1.3.2