TODO: ensure that python2 and python3 agree on hashes of the same
    information

    Args:
        hashable_ (hashable): hashables are bytes-like objects
           An object that supports the Buffer Protocol, like bytes, bytearray
           or memoryview. Bytes-like objects can be used for various operations
           that expect binary data, such as compression, saving to a binary
           file or sending over a socket. Some operations need the binary data
           to be mutable, in which case not all bytes-like objects can apply.

    Returns:
        UUID: uuid_

    CommandLine:
        python -m utool.util_hash --test-hashable_to_uuid

    Example:
        >>> # ENABLE_DOCTEST
        >>> from utool.util_hash import *  # NOQA
        >>> import utool as ut
        >>> hashables = [
        >>>     'foobar',
        >>>     'foobar'.encode('utf-8'),
        >>>     u'foobar',
        >>>     10,
        >>>     [1, 2, 3],
        >>> ]
        >>> uuids = []
        >>> for hashable_ in hashables:
        >>>     uuid_ = hashable_to_uuid(hashable_)
        >>>     uuids.append(uuid_)
        >>> result = ut.repr4(ut.lmap(str, uuids), strvals=True, nobr=True)
        >>> print(result)
        8843d7f9-2416-211d-e9eb-b963ff4ce281,
        8843d7f9-2416-211d-e9eb-b963ff4ce281,
        8843d7f9-2416-211d-e9eb-b963ff4ce281,
        e864ece8-8880-43b6-7277-c8b2cefe96ad,
        a01eda32-e4e0-b139-3274-e91d1b3e9ecf,

def hashable_to_uuid(hashable_):
    """
    TODO: ensure that python2 and python3 agree on hashes of the same
    information

    Args:
        hashable_ (hashable): hashables are bytes-like objects
           An object that supports the Buffer Protocol, like bytes, bytearray
           or memoryview. Bytes-like objects can be used for various operations
           that expect binary data, such as compression, saving to a binary
           file or sending over a socket. Some operations need the binary data
           to be mutable, in which case not all bytes-like objects can apply.

    Returns:
        UUID: uuid_

    CommandLine:
        python -m utool.util_hash --test-hashable_to_uuid

    Example:
        >>> # ENABLE_DOCTEST
        >>> from utool.util_hash import *  # NOQA
        >>> import utool as ut
        >>> hashables = [
        >>>     'foobar',
        >>>     'foobar'.encode('utf-8'),
        >>>     u'foobar',
        >>>     10,
        >>>     [1, 2, 3],
        >>> ]
        >>> uuids = []
        >>> for hashable_ in hashables:
        >>>     uuid_ = hashable_to_uuid(hashable_)
        >>>     uuids.append(uuid_)
        >>> result = ut.repr4(ut.lmap(str, uuids), strvals=True, nobr=True)
        >>> print(result)
        8843d7f9-2416-211d-e9eb-b963ff4ce281,
        8843d7f9-2416-211d-e9eb-b963ff4ce281,
        8843d7f9-2416-211d-e9eb-b963ff4ce281,
        e864ece8-8880-43b6-7277-c8b2cefe96ad,
        a01eda32-e4e0-b139-3274-e91d1b3e9ecf,
    """
    bytes_ = _ensure_hashable_bytes(hashable_)
    try:
        bytes_sha1 = hashlib.sha1(bytes_)
    except TypeError:
        print('hashable_ = %r' % (hashable_,))
        print('bytes_ = %r' % (bytes_,))
        raise
    # Digest them into a hash
    hashbytes_20 = bytes_sha1.digest()
    hashbytes_16 = hashbytes_20[0:16]
    uuid_ = uuid.UUID(bytes=hashbytes_16)
    return uuid_