forthelulz.py 文件源码

python
阅读 20 收藏 0 点赞 0 评论 0

项目:forthelulz 作者: munchycool 项目源码 文件源码
def resolve_url(url):
    duration=7500   
    try:
        stream_url = urlresolver.HostedMediaFile(url=url).resolve()
        # If urlresolver returns false then the video url was not resolved.
        if not stream_url or not isinstance(stream_url, basestring):
            try: msg = stream_url.msg
            except: msg = url
            xbmc.executebuiltin('Notification(%s, %s, %d, %s)'%('URL Resolver',msg, duration, addon_icon))
            return False
    except Exception as e:
        try: msg = str(e)
        except: msg = url
        xbmc.executebuiltin('Notification(%s, %s, %d, %s)'%('URL Resolver',msg, duration, addon_icon))
        return False

    return stream_url
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号