xjbeta / iina-plus

Extra danmaku support for iina. (iina 弹幕支持
GNU General Public License v3.0
1.14k stars 69 forks source link

b站直播和斗鱼直播均无法解析出地址诶 #1

Closed CookieJaySJ closed 6 years ago

CookieJaySJ commented 6 years ago

提示:oops something wrong

xjbeta commented 6 years ago

下载最新版 设置里打开log 重启软件 重新操作一遍 然后把log 发过来

murongchenxing commented 6 years ago

同样也是这个情况,下面是log里的内容。

11:01:43.795 [iina+][d] App did finish launch 11:01:43.795 [iina+][d] App Version 0.2 (Build 2) 11:01:43.795 [iina+][d] macOS Version 10.13.6 (Build 17G65) 11:01:45.346 [iina+][d] Get bilibili dynamicList error: Key not found: data.mid 11:01:57.556 [iina+][d] JSON decode error: Error Domain=NSCocoaErrorDomain Code=3840 "No value." UserInfo={NSDebugDescription=No value.} 11:01:57.558 [iina+][d] JSON string:

xjbeta commented 6 years ago

打开终端输入 you-get "https://live.bilibili.com/3" --json 或者 ykdl "https://live.bilibili.com/3" --json

正确的json 输出 (ykdl 输出的略有不同

{
    "extra": {
        "referer": "https://live.bilibili.com/3",
        "ua": "Mozilla/5.0 (Windows NT 10.0; WOW64; rv:51.0) Gecko/20100101 Firefox/51.0"
    },
    "site": "Bilibili",
    "streams": {
        "live": {
            "container": "flv",
            "size": 0,
            "src": [
                "http://58.222.35.206/live-bvc/727656/live_11153765_9369560.flv?expires=1534390722&ssig=mQRzzirFRDgr4fkGlCCjwQ&oi=2045566214"
            ]
        }
    },
    "title": "哔哩哔哩音悦台",
    "url": "https://live.bilibili.com/3"
}

(未开播的直播 只会显示error

murongchenxing commented 6 years ago

image 你好,试了两个网站,输出分别如图,确定直播都是在开着的,网页可以看。

xjbeta commented 6 years ago

你安装的you-get 的问题 you-get --version you-get: version 0.4.1099, a tiny downloader that scrapes the web.

斗鱼用ykdl you-get 不能输出标准的json 数据

murongchenxing commented 6 years ago

you-get --version you-get: version 0.4.1128, a tiny downloader that scrapes the web. 这是you-get的版本,下边是ykdl输出的斗鱼链接。

ykdl "http://www.douyu.com/110" --json Traceback (most recent call last): File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 1317, in do_open encode_chunked=req.has_header('Transfer-encoding')) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 1229, in request self._send_request(method, url, body, headers, encode_chunked) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 1275, in _send_request self.endheaders(body, encode_chunked=encode_chunked) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 1224, in endheaders self._send_output(message_body, encode_chunked=encode_chunked) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 1016, in _send_output self.send(msg) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 956, in send self.connect() File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/http/client.py", line 1392, in connect server_hostname=server_hostname) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/ssl.py", line 412, in wrap_socket session=session File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/ssl.py", line 850, in _create self.do_handshake() File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/ssl.py", line 1108, in do_handshake self._sslobj.do_handshake() ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1045)

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "/Library/Frameworks/Python.framework/Versions/3.7/bin/ykdl", line 11, in load_entry_point('ykdl==1.6.2', 'console_scripts', 'ykdl')() File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/cykdl/main.py", line 173, in main info = parser(u) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/ykdl/extractor.py", line 24, in parser info = self.prepare() File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/ykdl/extractors/douyu/live.py", line 39, in prepare html_content = get_content(api_url) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/ykdl/util/html.py", line 67, in get_content response = urlopen(req) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 222, in urlopen return opener.open(url, data, timeout) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 525, in open response = self._open(req, data) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 543, in _open '_open', req) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 503, in _call_chain result = func(*args) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 1360, in https_open context=self._context, check_hostname=self._check_hostname) File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/urllib/request.py", line 1319, in do_open raise URLError(err) urllib.error.URLError: <urlopen error [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate (_ssl.c:1045)>

xjbeta commented 6 years ago

我用虚拟机测试了一下you-get 和ykdl 也并没有这样的问题 ykdl 可以去找作者反馈一下 接下来的版本我会考虑内置you-get 和ykdl

xjbeta commented 6 years ago

最新版内置了一个ykdl DMG ZIP