Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

斗鱼获取链接有问题 #200

Closed
AlterGu opened this issue Jun 11, 2021 · 5 comments
Closed

斗鱼获取链接有问题 #200

AlterGu opened this issue Jun 11, 2021 · 5 comments
Labels
duplicate This issue or pull request already exists fixed 👌

Comments

@AlterGu
Copy link

AlterGu commented Jun 11, 2021

Traceback (most recent call last):
File ".\douyu.py", line 116, in
print(s.get_real_url())
File ".\douyu.py", line 105, in get_real_url
ret.append(self.get_pre())
File ".\douyu.py", line 51, in get_pre
return data['rtmp_url'] + '/' + data['rtmp_live']
KeyError: 'rtmp_url'

@AlterGu
Copy link
Author

AlterGu commented Jun 11, 2021

使用的是最新版本的仓库代码

@gtrvirgo
Copy link

#196 在douyu.py51行return之前添加
data = res['data']

@wbt5 wbt5 added the duplicate This issue or pull request already exists label Jun 12, 2021
wbt5 added a commit that referenced this issue Jun 12, 2021
@AlterGu
Copy link
Author

AlterGu commented Jun 12, 2021

添加后又有报错

image

输入斗鱼直播间号:
787747
输入画质(1流畅;2高清;3超清;4蓝光4M;0蓝光8M或10M):
4
Traceback (most recent call last):
File "g:/Project/Pyhton/real-url/douyu.py", line 116, in
print(s.get_real_url())
File "g:/Project/Pyhton/real-url/douyu.py", line 106, in get_real_url
ret.append(self.get_js())
File "g:/Project/Pyhton/real-url/douyu.py", line 70, in get_js
return res['url']
TypeError: string indices must be integers

@wbt5
Copy link
Owner

wbt5 commented Jun 12, 2021

建议拉取最新代码

合并问题 Duplicate of #185

@AlterGu
Copy link
Author

AlterGu commented Jun 12, 2021

谢谢, 已解决

@AlterGu AlterGu closed this as completed Jun 12, 2021
rain-dl pushed a commit to rain-dl/real-url that referenced this issue Jun 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists fixed 👌
Projects
None yet
Development

No branches or pull requests

3 participants