def ParseKey(key_string):
 if (not key_string):
  return None
 if (key_string == 'None'):
  return None
 return datastore.Key(encoded=key_string)

def ParseKey ( key_string ) : if ( not key_string ) : return None if ( key_string == 'None' ) : return None return datastore . Key ( encoded = key_string )
turn a key stored in the database into a key or none .