import ipaddress


def check_ipaddress(ip_address):
    """
    Check IPv4 or IPv6 address for validity.

    Return `True` if it is valid, `False` if it is invalid.
    """
    try:
        ipaddress.IPv4Address(ipaddress)
    except ValueError:
        try:
            ipaddress.IPv6Address(ipaddress)
        except ValueError:
            return False
    return True