def to_uni(obj):
    if isinstance(obj, bytes):
        try:
            return obj.decode('utf-8')
        except __HOLE__:
            return obj.decode('gbk')
    elif isinstance(obj, (int, long)):
        return unicode(obj)
    elif isinstance(obj, (datetime.date, datetime.datetime)):
        return unicode(obj)
    else:
        return obj
dataset/ETHPy150Open shuge/Qt-Python-Binding-Examples/common_widgets/webview/brower_eval_custom_js.py/to_uni