pcdack / sdmusic Goto Github PK
View Code? Open in Web Editor NEWSearch && Download Music from multi-platform
Search && Download Music from multi-platform
SDMUSIC/src/sd_music/net/kugou_api.py
Line 14 in 0dff767
建议歌曲下载时命名为MusicName-MusicAuthor
。要不然会覆盖。
不选择页码时,搜索结果会漏掉第一首歌;
选择页码为n时,搜索结果会跳过n首歌,而不是显示第n页的结果。
我用conda创建了一个虚拟的py3.6环境,然后下载了网易云下架的周华健-风雨无阻,good!
测试了一下qq音乐,下载只可以下载免费,付费的不知道会不会提供接口。付费的应该是没有解析到真正地址吧
在虾米下载单曲的时候,保存下来的文件名,歌名部分使用的是搜索关键字,而不是实际的歌名。
感觉可以增加个批量下载歌单歌词的功能
[loongson@bogon ~]$ sdmusic
Traceback (most recent call last):
File "/usr/bin/sdmusic", line 9, in <module>
load_entry_point('sdmusic==0.14', 'console_scripts', 'sdmusic')()
File "/usr/lib/python3.4/site-packages/pkg_resources.py", line 348, in load_entry_point
return get_distribution(dist).load_entry_point(group, name)
File "/usr/lib/python3.4/site-packages/pkg_resources.py", line 2311, in load_entry_point
return ep.load()
File "/usr/lib/python3.4/site-packages/pkg_resources.py", line 2025, in load
entry = __import__(self.module_name, globals(),globals(), ['__name__'])
File "/usr/lib/python3.4/site-packages/sd_music/start.py", line 10, in <module>
from .net.qq_flac_api import QQFlacCloud #QQ flac格式音乐
File "/usr/lib/python3.4/site-packages/sd_music/net/qq_flac_api.py", line 31
print(f'正在抓取关键词>>{music_name}<<的基本信息,共有{total_num}首歌')
^
SyntaxError: invalid syntax
Traceback (most recent call last):
File "/usr/local/bin/sdmusic", line 11, in
sys.exit(main())
File "/usr/local/lib/python3.6/dist-packages/sd_music/start.py", line 366, in main
search_or_download(name, offset, platform, False, index - 1, output, args.lyric, args.album)
File "/usr/local/lib/python3.6/dist-packages/sd_music/start.py", line 94, in search_or_download
download_from_url(music_info.download_url, output+song_file_name)
File "/usr/local/lib/python3.6/dist-packages/sd_music/utils/downloader.py", line 44, in download_from_url
file_size = int(urlopen(url).info().get('Content-Length', -1))
File "/usr/lib/python3.6/urllib/request.py", line 223, in urlopen
return opener.open(url, data, timeout)
File "/usr/lib/python3.6/urllib/request.py", line 532, in open
response = meth(req, response)
File "/usr/lib/python3.6/urllib/request.py", line 642, in http_response
'http', request, response, code, msg, hdrs)
File "/usr/lib/python3.6/urllib/request.py", line 570, in error
return self._call_chain(*args)
File "/usr/lib/python3.6/urllib/request.py", line 504, in _call_chain
result = func(*args)
File "/usr/lib/python3.6/urllib/request.py", line 650, in http_error_default
raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 403: Forbidden
网易和qq都正常,唯独xiami报错
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.