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

CNTV/CCTV 解析问题 #45

Closed
mengmo opened this issue Jan 5, 2017 · 10 comments
Closed

CNTV/CCTV 解析问题 #45

mengmo opened this issue Jan 5, 2017 · 10 comments
Assignees

Comments

@mengmo
Copy link
Collaborator

mengmo commented Jan 5, 2017

现在完全不能解析

ykdl -i http://tv.cntv.cn/video/C15552/2ff20134b3e24db1a936dba14b0546bb
ykdl: Playlist is not supported for GeneralEmbed (通用嵌入视频)with url: http://tv.cntv.cn/video/C15552/2ff20134b3e24db1a936dba14b0546bb

顺带试了下,you-get倒是能把最低清晰度给解析出来

@zhangn1985
Copy link
Collaborator

了解,这个问题本来在我电脑坏掉的时候就准备解了。这周末吧。

@zhangn1985 zhangn1985 self-assigned this Jan 5, 2017
@mengmo
Copy link
Collaborator Author

mengmo commented Jan 7, 2017

@zhangn1985
一个疑问:
extractors目录下的cntv.py看着像个链接,但是实际使用时就是把cctv.py复制一下改个名,同样的还有letv
是就只能这样解决,还是这样做比较好呢?

@zhangn1985
Copy link
Collaborator

据我测试cntv的链接大部分都跳转到cctv,解析必然是一样的,如果只是简单的复制,那么势必要维护两份代码,而且要同步修改,难免会忘记。所以做成链接比较好,但是问题就是git clone的方式就不可移植。
要么就写成一个wrapper。

@zhangn1985
Copy link
Collaborator

pip 安装就没有问题。

@mengmo
Copy link
Collaborator Author

mengmo commented Jan 8, 2017

@zhangn1985
我的描述有问题
你有没有看过pip安装后的目录结构?我这儿letv就是直接原样复制了一份,而修改后的cntv.py也得这样做才能用。

@zhangn1985
Copy link
Collaborator

是的,我看过,pip安装包生成的时候就是原样复制的。
这个你不需要管,由我生成安装包的时候做的。

@zhangn1985
Copy link
Collaborator

支持cntv不仅仅是把cntv链接到cctv,cctv本身也做了修改

@zhangn1985
Copy link
Collaborator

f6a92d2

这个做法更好~~

@mengmo
Copy link
Collaborator Author

mengmo commented Jan 8, 2017

其实我问这个问题的原因是
当某个网站的解析修改后就需要下载相应的解析器替换,而如果是cntv.pycctv.py或者letvle的话那就多了一步操作[相较于you-get(你看这人有多懒)]
ykdl里这么做是不是出于利于开发的角度才这么做的呢?(如果是的话就没问题了)

@zhangn1985
Copy link
Collaborator

是的,有利于开发者,所以新的做法改变了。

zhangn1985 pushed a commit that referenced this issue Apr 27, 2018
close: #45

Signed-off-by: ykdl <zhangn1985@gmail.com>
zhangn1985 pushed a commit that referenced this issue Apr 27, 2018
close: #45

Signed-off-by: ykdl <zhangn1985@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants