Code Monkey home page Code Monkey logo

melody's Introduction

Melody

项目介绍

大家好,我叫 Melody,你的音乐精灵,旨在帮助你更好地管理音乐。目前的主要能力是帮助你将喜欢的歌曲或者音频上传到音乐平台的云盘。

为了避免不必要的纠纷和账号安全问题,本项目不会以任何形式提供在线 demo 服务,也请大家不要使用公共服务。本地部署很简单。

Feature

  • 支持在各大音乐和视频网站检索歌曲。目前支持 咪咕、网易云、QQ 音乐、酷狗、bilibili、抖音等站点。详情可以在我的 media-get 项目中查看
  • 支持一键下载到本地,一键上传到云盘
  • 用链接搜索歌曲(例如使用 b站或抖音的视频链接进行搜索,可以将对应的音频自动上传到音乐云盘)
  • 一键“解锁”无法播放的歌曲(一键检测变灰的歌曲,自动从公共资源搜索最佳资源,自动上传到云盘,自动匹配歌曲信息。代替繁琐的人工操作,实现可播放)(实验性功能,目前仅支持网易云)
  • PC 端、移动端适配良好(支持 PWA)
  • 部署简单,支持 docker

安装和启动

方式一:Docker 安装

  1. 在你的宿主机创建一个目录,例如: ~/melody-profile
  2. 创建镜像,有两种方式选择(注意修改下面的宿主机目录为你实际的):
    • 从 hub.docker.com 拉取
      docker run -d -p 5566:5566  -v ~/melody-profile:/app/backend/.profile foamzou/melody:latest
      
    • 从代码编译镜像(若你的 docker 不支持 DOCKER_BUILDKIT,则去掉)
      DOCKER_BUILDKIT=1 docker build -t melody .
      docker run -d -p 5566:5566  -v ~/melody-profile:/app/backend/.profile melody
      
  3. 后续更新(以从 hub.docker.com 更新为例)
    docker pull docker.io/foamzou/melody:latest
    docker kill <CONTAINER ID>
    docker run -d -p 5566:5566  -v ~/melody-profile:/app/backend/.profile foamzou/melody:latest
    

方式二:源码安装

  1. 依赖

    确保以下两个依赖是安装好的

    1. node.js (官网下载)
    2. FFmpeg (windows 安装介绍)
  2. 下载源码、初始化服务、运行服务

    git clone https://github.com/foamzou/melody.git
    cd melody && npm run init && npm run app
    
  3. 若后面代码有更新,下次执行该命令即可更新

    npm run update && npm run app
    

配置你的账号(可选)

默认的 melody key 为: melody,若你的服务部署在私有网络,则可以不用修改(网易云账号、密码可以在 web 页面设置)。

若需要修改或添加新账号,则编辑 backend/.profile/accounts.json (安装方式为 docker 的则为:你的宿主机目录/accounts.json ) 。

  1. 该 JSON 中的 key 是 Melody Key,是你在网页访问该服务的唯一凭证
  2. 网易云账号信息: accountpassword 可以后续在网页修改
  3. 该 JSON 是个数组,支持配置多个账号

Q: 更新了 accounts.json 如何生效?

A: 两种方式。1: 重启服务。2: 网页端 我的音乐账号 tab 下,随便修改点账号,密码,然后点击 更新账号密码,这样会从 accounts.json 更新信息到内存(我后面优化下这块)

浏览器访问

最后,在浏览器访问 http://127.0.0.1:5566 就可以使用啦~

功能介绍

关键词搜索歌曲

如果试听后是你想要的,点击上传按钮会将该歌曲上传到你的网易云音乐云盘

链接搜索

有时候我们在 b 站 听到好听的歌,也可以上传到云盘

一键解锁歌单

点击 解锁全部(实验性功能) 后,服务会自动匹配每首歌,并把歌曲上传到云盘,最后做个 match,以保证你还能看到歌词、评论

手动搜索匹配

当某首歌自动解锁失败后,还可以手动点击搜索按钮,找到符合的歌曲后,手动点击上传按钮

移动端适配

Roadmap

计划在后面支持以下功能

  • 页面适配移动端
  • 浏览器油猴脚本
  • 云盘歌曲 match 手动纠错
  • 支持播放列表
  • 支持播放云盘的歌曲
  • 支持 docker 部署
  • 支持 youtube-dl,you-dl 等工具作为输入源
  • 支持 酷狗、qq 音乐等音乐平台的云盘作为输出
  • 偏好设置
  • 版本更新提示

Q & A

  1. Q:移动端版本,为什么点击下载歌曲,会跳新的页面?

    A:有的浏览器不支持嗅探的,会有这个问题。因为外部资源文件都不允许跨域,无法用常规下载方式 save as。考虑后续 hack

  2. Q:移动端版本,为什么在数据网络无法播放歌曲?

    A:发现某些网络下,没有触发 canplaythrough 事件,wifi 环境下一般是没有问题的。

  3. Q:为什么移动端 PWA,点击跳转到其他页面时,无法返回到原来页面?

    A:PWA 在移动端不支持使用外部浏览器打开外链,只能在应用内打开,因此会有各种奇怪问题。此时,只能先杀死应用。

  4. Q:为什么我部署的服务,PWA 始终出不了?

    A:PWA 要求服务必须是 HTTPS。

  5. Q: 为什么更新 media-get 组件后,搜索报错

    A: 目前存在 bug,更新完 media-get 组件之后,请务必重启 docker 容器或服务,否则将无法继续使用

Change log

Release

致谢

赞赏

如果我的任何开源项目帮助到了你,都可以考虑请我喝杯奶茶呀~

感谢以下支持的朋友

  • 2024年6月19日 kiohang: 5元(附言:干的漂亮,期望加入夜景模式) foam: 后面考虑下
  • 2024年6月18日 许昊南: 5元(附言:请您喝。。。绿豆汤)
  • 2024年6月17日 Nanosaki:10元(附言:感谢为音乐自由做的贡献!)
  • 2024年6月14日 蛋蛋: 10元(附言:加油,早点把nas下载或者aria2导出搞定) foam: 好的,立个 flag,7月末之前。
  • 2024年6月10日 猫猫贩卖机: 5元 (附言: Melody很棒!)
  • 2023年6月12日 hosea: 5元(附言: 谢谢你的开源项目解决了我听歌的)
  • 2023年5月11日 十三三: 5元(附言:加油)
  • 2022年12月19日 Jameszz: 10元(附言: melody 有帮助)
  • 2022年8月16日 匿名网友: 8.77元(附言: 峰哥牛逼,微信钱包里所有的零钱全部赞赏给你👍)
  • 2022年8月8日 锐勇: 1元
  • 2022年5月19日 哥: 10元(附言: 大神恰瓶可乐)
  • 2022年5月7日 WWW: 3元(附言: 感谢项目望日后op能docker)
  • 2022年5月5日.: 5元

melody's People

Contributors

e5u avatar foamzou avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

melody's Issues

Cannot GET /

开始执行...
检查 media-get
当前 media-get 版本已经是最新版本
检查 media-get 是否更新成功
安装 node_module
����: �Ҳ������޷��������� install

����: �Ҳ������޷��������� install

编译前端
����: �Ҳ������޷��������� run

删除老目录
拷贝前端目录
执行完毕,执行以下命令启动服务:

npm run app
(node:11068) [DEP0147] DeprecationWarning: In future versions of Node.js, fs.rmdir(path, { recursive: true }) will be removed. Use fs.rm(path, { recursive: true }) instead
(Use node --trace-deprecation ... to show where the warning was created)

[email protected] app
node backend/src/index.js

D:\develop\other\melody\backend\src\service\media_fetcher/../../../bin/media-get.exe [ '-h' ]
i [media-get] Version: 0.2.6 18:12:49
i [tmp path] use C:\Users\Jios\AppData\Local\Temp\melody-tmp-songs 18:12:49
i Express server is listening on :::5566! 18:12:50

安装到最后,浏览器输入http://127.0.0.1:5566/,页面就是这个提示Cannot GET /,F12出来这页面是404,这个怎么处理。

填写你的 Melody Key

问个很蠢的问题,docker启动后,“填写你的 Melody Key”,这个Melody Key在哪里找,我设置了accounts.json中的account和password,依然无法进入,提示我Melody不正确?

NPM 安装后,搜索失败

设备环境:Android 13,ARM64,Termux 0.118
Node 版本:18.4.0

在前端搜索界面输入字符搜索,报错如下:

ERROR  catch error Cannot read properties of null (reading 'map')

  at searchSongFromAllPlatform (backend/src/service/media_fetcher/index.js:120:25)
  at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
  at async searchSongsWithKeyword (backend/src/service/search_songs/index.js:6:24)
  at async search (backend/src/handler/songs.js:22:17)

ℹ searchSong with {"0":{"keyword":"十年"}}
ℹ cmdStr: /data/data/com.termux/files/home/melody/backend/src/service/media_fetcher/../../../bin/media-get -k " 十年" --searchType="song" -m --infoFormat=json -l silence
/data/data/com.termux/files/home/melody/backend/src/service/media_fetcher/../../../bin/media-get [
  '-k',
  '"十年"',
  '--searchType="song"',
  '-m',
  '--infoFormat=json',
  '-l',
  'silence'
]
ℹ -------
ℹ 0
ℹ -------

 ERROR  catch error Cannot read properties of null (reading 'map')

  at searchSongFromAllPlatform (backend/src/service/media_fetcher/index.js:120:25)
  at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
  at async searchSongsWithKeyword (backend/src/service/search_songs/index.js:6:24)
  at async search (backend/src/handler/songs.js:22:17)

此外,在安装时也会出现 media-get 安装失败的提示,即便手动下载到对应目录也会在「检查 media-get 是否安装成功」过程中报错。该问题通过删除 script/setup.js 相关检测可解决。

一直显示没网状态

 ERROR  uid(admin)'s loginType(固定为:phone,目前仅支持手机号+密码登录。下面为示例) does not support now
 ERROR  uid(admin) get cookie failed
 ERROR  request failed. false
ℹ uid(admin)'s cookie not found from .profile
ℹ uid(admin) login...

docker版无法播放音乐

附日志:


ℹ -------
ℹ searchSong with {"0":{"keyword":"光辉岁月"}}
ℹ cmdStr: /app/backend/src/service/media_fetcher/../../../bin/media-get -k "光辉岁月" --searchType="song" -m --infoFormat=json -l silence
ℹ -------
ℹ 0
ℹ -------
ℹ getMetaWithUrl from https://www.kuwo.cn/play_detail/19534401

 ERROR  exec error: Error: Command failed: /app/backend/src/service/media_fetcher/../../../bin/media-get -u "https://www.kuwo.cn/play_detail/19534401" -m --infoFormat=json
panic: invalid character 'æ' looking for beginning of value

goroutine 1 [running]:
main.main()
	command-line-arguments/main.go:24 +0xd0


ℹ -------
ℹ 2
ℹ Command failed: /app/backend/src/service/media_fetcher/../../../bin/media-get -u "https://www.kuwo.cn/play_detail/19534401" -m --infoFormat=json
panic: invalid character 'æ' looking for beginning of value

goroutine 1 [running]:
main.main()
	command-line-arguments/main.go:24 +0xd0

ℹ -------

 ERROR  getMetaWithUrl failed with https://www.kuwo.cn/play_detail/19534401, err: Command failed: /app/backend/src/service/media_fetcher/../../../bin/media-get -u "https://www.kuwo.cn/play_detail/19534401" -m --infoFormat=json
panic: invalid character 'æ' looking for beginning of value

goroutine 1 [running]:
main.main()
	command-line-arguments/main.go:24 +0xd0

b站有一个上传失败

b站有一个上传失败,同up主有成功上传
https://www.bilibili.com/video/BV1BY4y1i777

附部分日志
ℹ -------
ℹ searchSong with {"0":{"songName":"【萨克斯】转音注入灵魂~《月牙湾》F.I.R. "是谁的心啊,孤单地留下"","artist":"Leon_Music","album":"Bilibili"}}
ℹ cmdStr: /melody/backend/src/service/media_fetcher/../../../bin/media-get --searchSongName "【萨克斯】转音注入灵魂~《月牙湾》F.I.R. "是谁的心啊,孤单地留下"" --searchArtist "Leon_Music" --searchAlbum "Bilibili" --searchType="song" -m --infoFormat=json -l silence
ℹ -------
ℹ 0
ℹ -------
ℹ songName not matched, continue. 【萨克斯】转音注入灵魂~《月牙湾》F.I.R. "是谁的心啊,孤单地留下" vs 【萨克斯】转音注入灵魂~《月牙湾》F.I.R. "是谁的心啊,孤单地留下"
ℹ songName not matched, continue. 月牙湾 (Live) vs 【萨克斯】转音注入灵魂~《月牙湾》F.I.R. "是谁的心啊,孤单地留下"

无法上传解锁歌曲

ℹ fetchWithUrl params: {"0":"https://y.qq.com/n/ryqq/songDetail/004Z8Ihr0JIu5s","1":{"songName":"七里香","addMediaTag":false}} 12:41:22
ℹ start parse and download from https://y.qq.com/n/ryqq/songDetail/004Z8Ihr0JIu5s 12:41:22

ERROR exec error: Error: Command failed: /Users/.../melody/backend/src/service/media_fetcher/../../../bin/media-get -u "https://y.qq.com/n/ryqq/songDetail/004Z8Ihr0JIu5s" --out "/var/folders/5r/ct4_6f8j3zv8sx303l0jlvrc0000gn/T/melody-tmp-songs/d7070ce48106b02b1f4a700cdf000431/七里香.mp3" -t audio
panic: runtime error: index out of range [1] with length 1

goroutine 1 [running]:
github.com/foamzou/audio-get/utils.GetExtFromUrl(0x0, 0x0, 0x9, 0x144efbd)
github.com/foamzou/audio-get/utils/url.go:11 +0x175
github.com/foamzou/audio-get/processor.(*Processor).downloadAudio(0xc0001a1f68, 0xc0001fa000, 0xc0228dd2f1a9fbe7, 0x401d353f7ced9168)
github.com/foamzou/audio-get/processor/download.go:36 +0x55a

[BUG]酷我/QQ不能播放

请至少提供以下信息,帮助排查问题

  1. 后端日志
    ℹ searchSong with {"0":{"keyword":"平凡之路"}}
    ℹ cmdStr: /app/backend/src/service/media_fetcher/../../../bin/media-get -k "平凡之路" --searchType="song" -m --infoFormat=json -l silence
    /app/backend/src/service/media_fetcher/../../../bin/media-get [
    '-k',
    '"平凡之路"',
    '--searchType="song"',
    '-m',
    '--infoFormat=json',
    '-l',
    'silence'
    ]
    ℹ -------
    ℹ 0
    ℹ -------
    ℹ getMetaWithUrl from https://www.kuwo.cn/play_detail/146783118
    /app/backend/src/service/media_fetcher/../../../bin/media-get [
    '-u',
    '"https://www.kuwo.cn/play_detail/146783118"',
    '-m',
    '--infoFormat=json'
    ]
    ℹ -------
    ℹ 2
    ℹ -------

ERROR getMetaWithUrl failed with https://www.kuwo.cn/play_detail/146783118, err: panic: invalid character 'æ' looking for beginning of value

goroutine 1 [running]:
main.main()
./main.go:24 +0xab

ℹ getMetaWithUrl from https://y.qq.com/n/ryqq/songDetail/000T1Ws32MWrUj
/app/backend/src/service/media_fetcher/../../../bin/media-get [
'-u',
'"https://y.qq.com/n/ryqq/songDetail/000T1Ws32MWrUj"',
'-m',
'--infoFormat=json'
]
ℹ -------
ℹ 2
ℹ -------

ERROR getMetaWithUrl failed with https://y.qq.com/n/ryqq/songDetail/000T1Ws32MWrUj, err: panic: can not get song url

goroutine 1 [running]:
main.main()
./main.go:24 +0xab

复现步骤

搜索,播放仅此

我不会看报错,安装过的大佬来帮一帮

Error: Cannot find module 'consola'
Require stack:

  • C:\Program Files (x86)\melody\backend\src\index.js
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:956:15)
    at Function.Module._load (node:internal/modules/cjs/loader:804:27)
    at Module.require (node:internal/modules/cjs/loader:1028:19)
    at require (node:internal/modules/cjs/helpers:102:18)
    at Object. (C:\Program Files (x86)\melody\backend\src\index.js:7:16)
    at Module._compile (node:internal/modules/cjs/loader:1126:14)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1180:10)
    at Module.load (node:internal/modules/cjs/loader:1004:32)
    at Function.Module._load (node:internal/modules/cjs/loader:839:12)
    at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:81:12) {
    code: 'MODULE_NOT_FOUND',
    requireStack: [ 'C:\Program Files (x86)\melody\backend\src\index.js' ]
    }
    百度了半天也没找到怎么解决,有会的大佬教一教我吧,这个npm我之前只是用过解灰wyy的那一次,后来一直在吃灰
    主要是搜了这个consola和下面的'MODULE_NOT_FOUND'
    consola没搜到啥解决方案,就是让我安装这个依赖(没找到怎么安装,没尝试)
    下面那个解决方案五花八门,没有找到对口的,只能开个贴来问一问了

127.0.0.1:5566 could not be reached

After running: npm run init && npm run app
The following errors appear:

[email protected] init
node scripts/setup.js

开始执行...
检查 media-get
开始下载核心程序 media-get
node:events:505
throw er; // Unhandled 'error' event
^

Error: write EPROTO 4731999744:error:1408F10B:SSL routines:ssl3_get_record:wrong version number:../deps/openssl/openssl/ssl/record/ssl3_record.c:332:

at WriteWrap.onWriteComplete [as oncomplete] (node:internal/stream_base_commons:94:16)

Emitted 'error' event on ClientRequest instance at:
at TLSSocket.socketErrorListener (node:_http_client:454:9)
at TLSSocket.emit (node:events:527:28)
at emitErrorNT (node:internal/streams/destroy:157:8)
at emitErrorCloseNT (node:internal/streams/destroy:122:3)
at processTicksAndRejections (node:internal/process/task_queues:83:21) {
errno: -100,
code: 'EPROTO',
syscall: 'write'
}

And enter http://127.0.0.1:5566/ into the browser, and it says:
127.0.0.1 refused to connect.

[Feature Request] 支持下载MP3到本地

功能描述
现在音乐只是下载到/tmp目录,上传到云盘后就自动删除了。建议支持一键将歌单中所有音乐,下载MP3到本地,用作本地存储。

为什么需要该功能
在版权越来越严格的前提下,很多APP都有自己格式的音乐格式,不再提供通用MP3格式文件,不方便离线听取。

你能想到的解决方案
既然内部已经有获取网易云歌单列表和下载MP3的逻辑,建议增加一个「一键下载MP3到本地」的功能,方便离线存储。

一直登录不成功

ERROR  uid(admin)'s loginType(固定为:phone,目前仅支持手机号+密码登录。下面为示例) does not support now
ERROR  uid(admin) get cookie failed
ERROR  request failed. false
ℹ uid(admin)'s cookie not found from .profile
ℹ uid(admin) login...

独立部署时无法通过验证

我试图将其集成到内网的 nginx ,但是编译出来后,无法验证,没有搞明白 account 要的是什么。试过将.profile里面的东西拿出来用,也没有用。
2022-05-10_21-00

Melody后续功能

Melody,你的音乐精灵,旨在帮助你更好地管理音乐。目前的主要能力是帮助你将喜欢的歌曲或者音频上传到音乐平台的云盘

刚刚出了Docker版,完美跑在openwrt,我觉得Melody完全可以更强大,直接作为本地私人播放器,解锁的音乐可以存在本地.不知道后续发展是否会走向这个功能.

添加处理历史的展示

希望有一个单独的页面,能够展示处理过的历史,不然有一些失败了也看不出来,也不知道哪些成功了

添加更多上传源

这个项目太棒了,但可能是由于开发者个人使用的初衷,只支持上传音乐云盘,多少有些遗憾。
想提议的是,是否能支持更多上传源呢?
例如:
1.本地路径
2.Onedrive
3.GoogleDrive
4.Webdav
5.YouTube 音乐(可以无限制上传)

[BUG] termux本地部署无法正确下载media-get

npm run init ─╯

[email protected] init
node scripts/setup.js

开始执行...
检查 media-get
开始下载核心程序 media-get
开始下载 media-get: https://github.com/foamzou/media-get/releases/download/v0.2.8/media-get-0.2.8-win.exe-arm64
download finished
再次检查 media-get 是否安装成功
media-get 安装失败。请手动从 https://github.com/foamzou/media-get/releases 下载最新版本到 /data/data/com.termux/files/home/melody/backend/bin/media-get

检查路径发现确实生成了media-get文件,但大小不符,只有200k,手动下载Linux-arm并移动到该路径,检查安装失败。

[BUG]使用armbian的docker安装后搜索失败

请至少提供以下信息,帮助排查问题

  1. 后端日志
  2. F12 前端网络请求报文
  3. F12 console 信息

复现步骤

打开网页搜索时的log:

ℹ [media-get] Version: 0.2.7
ℹ [tmp path] use /tmp/melody-tmp-songs
ℹ Express server is listening on :::5566!
ℹ searchSong with {"0":{"keyword":"fade"}}
ℹ cmdStr: /app/backend/src/service/media_fetcher/../../../bin/media-get -k "fade" --searchType="song" -m --infoFormat=json -l silence
/app/backend/src/service/media_fetcher/../../../bin/media-get [
  '-k',
  '"fade"',
  '--searchType="song"',
  '-m',
  '--infoFormat=json',
  '-l',
  'silence'
]
ℹ -------
ℹ 0
ℹ -------
ℹ searchSong with {"0":{"keyword":"fade"}}
ℹ cmdStr: /app/backend/src/service/media_fetcher/../../../bin/media-get -k "fade" --searchType="song" -m --infoFormat=json -l silence
/app/backend/src/service/media_fetcher/../../../bin/media-get [
  '-k',
  '"fade"',
  '--searchType="song"',
  '-m',
  '--infoFormat=json',
  '-l',
  'silence'
]
ℹ -------
ℹ 0
ℹ -------

进入容器后执行 /app/backend/src/service/media_fetcher/../../../bin/media-get -k "fade" --searchType="song" -m --infoFormat=json -l debug 结果为:

/app# /app/backend/src/service/media_fetcher/../../../bin/media-get -k "fade" --searchType="song" -m --infoFormat=json -l debug
Will search in  [bilibili douyin kugou kuwo migu netease qq youtube qmkg]
http code should be 200, got 412
Get "https://www.youtube.com/results?search_query=fade": dial tcp 172.217.160.78:443: i/o timeout
[
    {
        "Name": "Fade",
        "Artist": "Janji",
        "Album": "Football House",
        "Duration": 0,
        "Url": "https://music.migu.cn/v3/music/song/6999071YMKK",
        "ResourceForbidden": false,
        "Source": "migu",
        "FromMusicPlatform": true,
        "Score": 640.803
    },
    {
        "Name": "Fade",
        "Artist": "Sophie Zelmani",
        "Album": "Decade of dreams 1995-2005",
        "Duration": 0,
        "Url": "https://music.migu.cn/v3/music/song/6005971ASJ3",
        "ResourceForbidden": false,
        "Source": "migu",
        "FromMusicPlatform": true,
        "Score": 429.792
    },
    {
        "Name": "Fade",
        "Artist": "Sophie Zelmani",
        "Album": "Bright Eyes",
        "Duration": 0,
        "Url": "https://music.migu.cn/v3/music/song/6005660D6Y4",
        "ResourceForbidden": false,
        "Source": "migu",
        "FromMusicPlatform": true,
        "Score": 429.792
    },
    {
        "Name": "",
        "Artist": "",
        "Album": "",
        "Duration": 0,
        "Url": "https://www.douyin.com/video/",
        "ResourceForbidden": false,
        "Source": "douyin",
        "FromMusicPlatform": false,
        "Score": 330
    },
    {
        "Name": "Fade",
        "Artist": "Alan Walker",
        "Album": "NCS: Uplifting",
        "Duration": 264,
        "Url": "https://music.163.com/#/song?id=33887932",
        "ResourceForbidden": false,
        "Source": "netease",
        "FromMusicPlatform": true,
        "Score": 46.2
    },
    {
        "Name": "Fade",
        "Artist": "Alan Walker",
        "Album": "Origins",
        "Duration": 264,
        "Url": "https://music.163.com/#/song?id=29947420",
        "ResourceForbidden": false,
        "Source": "netease",
        "FromMusicPlatform": true,
        "Score": 46.2
    },
    {
        "Name": "Fade",
        "Artist": "Alan Walker",
        "Album": "Origins",
        "Duration": 264,
        "Url": "https://y.qq.com/n/ryqq/songDetail/001l8CjG0HDdV6",
        "ResourceForbidden": false,
        "Source": "qq",
        "FromMusicPlatform": true,
        "Score": 46.2
    },
    {
        "Name": "Fade",
        "Artist": "Alan Walker",
        "Album": "Fade",
        "Duration": 264,
        "Url": "https://www.kugou.com/song/#hash=8ef8c2da65712d41d8d507d34578d617\u0026album_id=590859",
        "ResourceForbidden": false,
        "Source": "kugou",
        "FromMusicPlatform": true,
        "Score": 46.2
    },
    {
        "Name": "Fade",
        "Artist": "Alan\u0026nbsp;Walker",
        "Album": "Fade",
        "Duration": 262,
        "Url": "https://www.kuwo.cn/play_detail/6245379",
        "ResourceForbidden": false,
        "Source": "kuwo",
        "FromMusicPlatform": true,
        "Score": 40.612
    },
    {
        "Name": "Fade\u0026nbsp;(cover:\u0026nbsp;Alan\u0026nbsp;Walker)",
        "Artist": "左旺",
        "Album": "",
        "Duration": 1963,
        "Url": "https://www.kuwo.cn/play_detail/151260304",
        "ResourceForbidden": false,
        "Source": "kuwo",
        "FromMusicPlatform": true,
        "Score": 11.936
    },
    {
        "Name": "《Fade》封神之作。现象级电音神作,多少人听了这首神曲而入坑!",
        "Artist": "暮瞳",
        "Album": "",
        "Duration": 268,
        "Url": "https://www.douyin.com/video/6844324142251019527",
        "ResourceForbidden": false,
        "Source": "douyin",
        "FromMusicPlatform": false,
        "Score": 11.543000000000001
    },
    {
        "Name": "11岁男孩用双排键弹奏世界冠军级电子音乐《Fade》高手在民间",
        "Artist": "三度艺术空间-双排键",
        "Album": "",
        "Duration": 388,
        "Url": "https://www.douyin.com/video/7118264710213946658",
        "ResourceForbidden": false,
        "Source": "douyin",
        "FromMusicPlatform": false,
        "Score": 11.448
    },
    {
        "Name": "Faded",
        "Artist": "Alan Walker",
        "Album": "Faded",
        "Duration": 212,
        "Url": "https://music.163.com/#/song?id=36990266",
        "ResourceForbidden": false,
        "Source": "netease",
        "FromMusicPlatform": true,
        "Score": 4.082
    },
    {
        "Name": "Faded",
        "Artist": "Alan Walker",
        "Album": "Different World",
        "Duration": 212,
        "Url": "https://y.qq.com/n/ryqq/songDetail/004XCNCu3tl6fg",
        "ResourceForbidden": false,
        "Source": "qq",
        "FromMusicPlatform": true,
        "Score": 4.082
    },
    {
        "Name": "Faded",
        "Artist": "Alan Walker",
        "Album": "Faded",
        "Duration": 212,
        "Url": "https://www.kugou.com/song/#hash=5605427423a1e89443d11b4afe3c87f2\u0026album_id=2657404",
        "ResourceForbidden": false,
        "Source": "kugou",
        "FromMusicPlatform": true,
        "Score": 4.082
    },
    {
        "Name": "Fade(褪色)",
        "Artist": "Alan Walker",
        "Album": "做好听的电音",
        "Duration": 262,
        "Url": "https://y.qq.com/n/ryqq/songDetail/001onNhB0PFXsY",
        "ResourceForbidden": false,
        "Source": "qq",
        "FromMusicPlatform": true,
        "Score": 3.4640000000000004
    },
    {
        "Name": "Alan Walker-Fade(马里奥赛德 电子交响乐mix)",
        "Artist": "Alan\u0026nbsp;Walker\u0026马里奥赛德",
        "Album": "Fade(Remix)",
        "Duration": 239,
        "Url": "https://www.kuwo.cn/play_detail/28112384",
        "ResourceForbidden": false,
        "Source": "kuwo",
        "FromMusicPlatform": true,
        "Score": 1.463
    },
    {
        "Name": "Faded",
        "Artist": "Alan Walker、Iselin Solheim",
        "Album": "Feel My Collect Song",
        "Duration": 212,
        "Url": "https://www.kugou.com/song/#hash=f13cf985390a07f973d177c14dd832e5\u0026album_id=7536462",
        "ResourceForbidden": true,
        "Source": "kugou",
        "FromMusicPlatform": true,
        "Score": -17.081999999999997
    }
]
---------------------------App end----------------------------
        Alloc = 2 MiB   TotalAlloc = 54 MiB     Sys = 30 MiB    NumGC = 12

--------------------------------------------------------------
Cost time: 4.888150742s

账号无法登陆,请稍后再试

ℹ uid(melody)'s cookie not found from .profile
ℹ uid(melody) login with  137省略6 via phone
{
  status: 250,
  body: { loginType: 1, code: 250, message: '当前登录存在安全风险,请稍后再试' },
  cookie: [
    'NMTID=00省略gA; Max-Age=315360000; Expires=Thu, 12 Aug 2032 03:36:09 GMT; Path=/;'
  ]
}

 ERROR  requestWyyApi failed:  {
  status: 250,
  body: {
    loginType: 1,
    code: 250,
    message: '当前登录存在安全风险,请稍后再试'
  },
  cookie: [
    'NMTID=00省略gA; Max-Age=315360000; Expires=Thu, 12 Aug 2032 03:36:09 GMT; Path=/;'
  ]
}


 ERROR  fetch cookie from response failed, uid(melody) login failed false


 ERROR  uid(melody) get cookie failed


 ERROR  request failed. false

尝试用服务器的ip在手机上登录后再尝试,还是不行。这怎么解决呢?
或许可以给个本地获取cookie的办法?然后把cookie填到json里,让melody直接使用,而不是通过登录?

[BUG] 超时导致搜索失败

可能是我的机器配置过低或者网络环境不好,搜索歌曲的时候xhr请求总是超时超过5000ms。将preload-helper-59e8b50d.js中的xhr请求超时时间改大就可以使用了。

[BUG]歌单列表打不开

有个歌单里面的歌曲有6百多首,点击之后打不开,docker部署的
/api/playlists/netease/373977657/songs 这里地址相应26秒之后也还是打不开

image

歌曲质量选择

建议后续可通过修改配置或者页面的形式来选择高质量的音乐格式

翻页

搜索结果只有一页,如果加个翻页功能就更好了。

几乎没有能上传的

i fetchWithUrl params: {"0":"https://music.163.com/#/song?id=209043","1":{"songName":"优先权","addMediaTag":false}}
i start parse and download from https://music.163.com/#/song?id=209043
i C:\Users\garyc\Documents\Tools\Melody\melody\backend\src\service\media_fetcher/../../../bin/media-get.exe -u "https://music.163.com/#/song?id=209043" --out "C:\Users\garyc\AppData\Local\Temp\melody-tmp-songs/7556ca6b9b3772f877305218d7d90d10/优先权.mp3" -t audio
C:\Users\garyc\Documents\Tools\Melody\melody\backend\src\service\media_fetcher/../../../bin/media-get.exe [
'-u',
'"https://music.163.com/#/song?id=209043"',
'--out',
'"C:\Users\garyc\AppData\Local\Temp\melody-tmp-songs/7556ca6b9b3772f877305218d7d90d10/优先权.mp3"',
'-t',
'audio',
''
]
i -------
i 0
i invalid argument for flag `/o, /out' (expected string): invalid syntax

i -------

不能加入歌单?

不能加入到歌单,用起来很不方便啊,就只能搜索了一个个点击播放。

希望有app安装

喜欢听歌的全小白,希望有app可以直接下载安装使用,谢谢你

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.