def make_id(value):
if isinstance(value, six.string_types):<EOL><INDENT>value = value.encode("<STR_LIT:utf8>", "<STR_LIT:ignore>")<EOL><DEDENT>from hashlib import md5<EOL>val = uuid.UUID(bytes=md5(value).digest(), version=<NUM_LIT:4>)<EOL>return base64.urlsafe_b64encode(val.get_bytes())[:-<NUM_LIT:2>]<EOL>
Build a string id from a value
:param value: a text value
:return: a string