-
-
Notifications
You must be signed in to change notification settings - Fork 426
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OAS 3 String format validation not working in path #724
Comments
Hi! Thanks for opening a pull request, The OpenAPI spec does not define the uuid format and so handling validation of it out of scope of this lib. Feel free to opt-in to the uuid validation mode though. |
So why having email and not uuid then? |
Indeed you're right, this is a mistake as old as the first commit! b855615#diff-90e14c30c1c7403690a666a976d821851020aa362bf984c3d7a6e8e0b2abcca4R22 Thanks for spotting this. I'd accept a PR that removes that line and mentions this change in the README for the next minor version bump. |
This is technically a breaking change so having it in minor bump seems wrong. I'd personally leave it like so. Maybe refer this issue in the codebase for the |
This is exactly why this exists: https://github.com/getkin/kin-openapi/tree/46e0df8ae84cbb51b7c672a0bb8ebb6995d28c7a#sub-v0-breaking-api-changes |
Seems like the string format validation does not seem to work in
path
In the previous example
/uuid-pattern/foobar
returns properly an error, which can be casted as multierror with 2 errors but theuuid-format/foobar
passes the validation.Seems like the format is handled in the codebase:
kin-openapi/openapi3/schema.go
Lines 373 to 378 in 46e0df8
Is there a miss somewhere?
The text was updated successfully, but these errors were encountered: