validate_ipv46_address
Validates that the provided value is either a valid IPv4 or IPv6 address, raising a ValidationError if it fails both checks.
def validate_ipv46_address(
value: string
) - > null
Validates that a value is either a valid IPv4 or IPv6 address.
Parameters
| Name | Type | Description |
|---|---|---|
| value | string | The IP address string to be validated against IPv4 and IPv6 protocols. |
Returns
| Type | Description |
|---|---|
null | Nothing if the value is a valid IP address; otherwise, a ValidationError is raised. |