-
-
Notifications
You must be signed in to change notification settings - Fork 493
IPv6 address matching IPv4 schema #969
Copy link
Copy link
Closed
Description
Given a openapi spec containing the following schema:
type: string
oneOf:
- format: ipv4
- format: ipv6
example: "2001:db8::"Running the validate command against it yields this error:
invalid example: input matches more than one oneOf schemas
The error seems to indicate a bug in the ipv4 format because the IPv6 address should only match ipv6 format, not ipv4.
On a side note, it'll be better to change this to anyOf in any case because IPv4 addresses can be contained in IPv6 addresses, but not the other way around.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels