def uuid(*args):
def check_value(v):<EOL><INDENT>if not isinstance(v, str):<EOL><INDENT>raise ValueError("<STR_LIT>" % str(v))<EOL><DEDENT>elif not v:<EOL><INDENT>raise ValueError("<STR_LIT>")<EOL><DEDENT>else:<EOL><INDENT>return v<EOL><DEDENT><DEDENT>s = '<STR_LIT::>'.join(map(check_value, args))<EOL>sha1 = hashlib.sha1(s.encode('<STR_LIT:utf-8>', errors='<STR_LIT>'))<EOL>uuid_sha1 = sha1.hexdigest()<EOL>return uuid_sha1<EOL>
Generate a UUID based on the given parameters.

    The UUID will be the SHA1 of the concatenation of the values
    from the list. The separator bewteedn these values is ':'.
    Each value must be a non-empty string, otherwise, the function
    will raise an exception.

    :param *args: list of arguments used to generate the UUID

    :returns: a universal unique identifier

    :raises ValueError: when anyone of the values is not a string,
        is empty or `None`.