def is_ip_valid(ip_string: str, port: int) -> bool:
    """Receive ip address and port and return if valid.
    Args:
        ip_string (str): ip address to check.
        port (int): port to check.
    Returns:
        bool: is the string a valid ip address.
    """
    if not isinstance(port, int):
        print('Invalid port type. Must be an integer.')
        return False
    if not isinstance(ip_string, str):
        print('Invalid ip type. Must be an string.')
        return False
    ip_parts = ip_string.split(".")
    if len(ip_parts) < 4 or len(ip_parts) > 4:
        print("IP address should be structured from 4 parts.")
        return False
    if not(bool(ip_parts) and all(map(lambda n: 0 <= int(n) <= 255, ip_parts))):
        print("invalid IP address")
        return False
    return True