kamikat / bilibili-get Goto Github PK
View Code? Open in Web Editor NEWBilibili video downloader.
License: MIT License
Bilibili video downloader.
License: MIT License
Hello,
Thank you for this tool. However I can't get it to work, I have this error:
bilibili-get https://www.bilibili.com/video/av24796361
extracting video metadata...
[1/1] av24796361: start download "热干面大赛的冠军,带我去吃了另外一家热干面! FINAL"...
[1/1] av24796361: video quality:
[1/1] av24796361: 112 hdflv2 高清 1080P+
[1/1] av24796361: 80 flv 高清 1080P
[1/1] av24796361: 64 flv720 高清 720P
[1/1] av24796361: * 32 flv480 清晰 480P
[1/1] av24796361: 15 flv360 流畅 360P
[1/1] av24796361: output format: flv
[1/1] av24796361: output path:
[1/1] av24796361: /home/arnauld/Desktop/av24796361 热干面大赛的冠军,带我去吃了另外一家热干面!(1) FINAL.flv
[1/1] av24796361: downloading video segment 1/2...
Exception: [AbstractOptionHandler.cc:69] errorCode=28 We encountered a problem while processing the option '--download-result'.
-> [OptionHandlerImpl.cc:444] errorCode=1 download-result must be one of the following:'default' 'full'
Usage:
--download-result=OPT This option changes the way "Download Results"
is formatted. If OPT is 'default', print GID,
status, average download speed and path/URI. If
multiple files are involved, path/URI of first
requested file is printed and remaining ones are
omitted.
If OPT is 'full', print GID, status, average
download speed, percentage of progress and
path/URI. The percentage of progress and
path/URI are printed for each requested file in
each row.Possible Values: default, full Default: default Tags: #advanced
ERROR: download command failed with code 28.
比如 https://www.bilibili.com/video/av25432066/?p=39
只要下载其中的38和39。
即使用带p的链接,也是下载所有的选集。
Hi, bilibili-get was working just fine for me the other day but now I get the following with each link I try (and with links that worked previously):
extracting video metadata...
ERROR: cannot extract part info.
Is this affecting anyone else?
According to 【升级公告】AV号全面升级至BV号,the AV tags have been upgraded into BV tags.
The regular expression in lib/extractor.js
var REGEX_URL_VIDEO = /^https?:\/\/(?:www\.|bangumi\.|)bilibili\.(?:tv|com)\/(?:video\/av(\d+)(?:\/|\/index_(\d+)\.html)?)(?:\?p=(\d+).*)?$/i;
is outdated and the video id cannot be extracted so easily as before.
I just installed and tried to run bilibili-get
and I got this error
user@host:/home/tmp# bilibili-get https://www.bilibili.com/video/av22216245 -l
/usr/local/lib/node_modules/bilibili-get/lib/index.js:25
.map(v => ({ ...location, ...info, ...v }))
^^^
SyntaxError: Unexpected token ...
at Object.exports.runInThisContext (vm.js:76:16)
at Module._compile (module.js:542:28)
at Object.Module._extensions..js (module.js:579:10)
at Module.load (module.js:487:32)
at tryModuleLoad (module.js:446:12)
at Function.Module._load (module.js:438:3)
at Module.require (module.js:497:17)
at require (internal/module.js:20:19)
at Object.<anonymous> (/usr/local/lib/node_modules/bilibili-get/bin/bilibili-get:8:16)
at Module._compile (module.js:570:32)
how can I fix this?
here is my system information
user@host:/home/tmp# npm -v && node -v
3.10.8
v6.9.0
Wondering if it's possible to fetch the download links with a socks proxy, and download it directly, for bypassing the limitation on copyright videos.
bilibili-get https://www.bilibili.com/video/av42878363
extracting video metadata...
[1/1] av42878363: start download "网上那些真实的沙雕图片(第六十五期) CleanBandit-Solo"...
ERROR: cannot get play info, server message: "Invalid appkey parameter."
There's a known issue with depended module axios/axios#1384 which the first release can encounter.
I'd rather submit the changes here than fork and make a pull request.
Had issues downloading "The Leader" the Anime on Karl Marx: https://www.bilibili.com/bangumi/play/ep261461
Appears that the format of the initial pages JSON is slightly different
diff --git a/lib/extractor.js b/lib/extractor.js
index d107332..fcff692 100644
--- a/lib/extractor.js
+++ b/lib/extractor.js
@@ -168,13 +168,14 @@ var findBangumiInfo = function* ({ url, bangumi_id, cookie }) {
var videoInfo = Object.assign({
info: {
title: json.mediaInfo.title,
- creator: json.upInfo && json.upInfo.uname,
- creator_id: json.upInfo && json.upInfo.mid,
- publish_at: (json.pubInfo && json.pubInfo.pub_time) || json.mediaInfo.publish.pub_date,
+ creator: json.epInfo && json.epInfo.from,
+ creator_id: json.epInfo && json.epInfo.id,
+ publish_at: (json.pubInfo && json.pubInfo.pub_time) || (json.mediaInfo.publish && json.mediaInfo.publish.pub_date) || (json.mediaInfo.pub && json.mediaInfo.pub.time),
},
- season_type: json.mediaInfo.season_type || (json.mediaInfo.param && json.mediaInfo.param.season_type),
- parts: (json.epList || json.mediaInfo.episodes).map(({ aid, cid, index_title, ep_id, index }) => ({
- aid, cid, index, index_title, episode_id: ep_id
+ season_type: json.mediaInfo.ssType || (json.mediaInfo.param && json.mediaInfo.param.season_type),
+ parts: (json.epList || json.mediaInfo.episodes).map((
+ { aid, cid, title, i, id }) => ({
+ aid, cid, index: i, index_title: title, episode_id: id
}))
});
debug('extracting bangumi info: success.');
Got the following on my terminal...
Some permission issues perhaps?
npm WARN checkPermissions Missing write access to /usr/local/lib/node_modules
npm ERR! path /usr/local/lib/node_modules
npm ERR! code EACCES
npm ERR! errno -13
npm ERR! syscall access
npm ERR! Error: EACCES: permission denied, access '/usr/local/lib/node_modules'
npm ERR! { [Error: EACCES: permission denied, access '/usr/local/lib/node_modules']
npm ERR! stack:
npm ERR! 'Error: EACCES: permission denied, access \'/usr/local/lib/node_modules\'',
npm ERR! errno: -13,
npm ERR! code: 'EACCES',
npm ERR! syscall: 'access',
npm ERR! path: '/usr/local/lib/node_modules' }
npm ERR!
npm ERR! The operation was rejected by your operating system.
npm ERR! It is likely you do not have the permissions to access this file as the current user
npm ERR!
npm ERR! If you believe this might be a permissions issue, please double-check the
npm ERR! permissions of the file and its containing directories, or try running
npm ERR! the command again as root/Administrator (though this is not recommended).
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/myusername/.npm/_logs/2019-01-08T07_28_45_519Z-debug.log
➜ ~ bilibili-get https://www.bilibili.com/video/av18182135
extracting video metadata...
ERROR: Unexpected token ;
$ bilibili-get https://www.bilibili.com/video/av38063989
02/24 10:38:20 [ERROR] CUID#8 - Download aborted. URI=http://cn-zjwz3-dx-v-05.acgvideo.com/upgcxcode/64/85/66908564/66908564-1-80.flv?expires=1550982900&platform=pc&ssig=NqxsxcynCEFf-86UgsxocQ&oi=1035461785&trid=674d7e50b1494eb78844b6bd71c48766&nfb=maPYqpoel5MI3qOUX6YpRA==&nfc=1
Exception: [SocketCore.cc:874] errorCode=1 接收数据失败,原因:连接被对方重设
-b 或者 -qb
既然已经是 “下载在线视频” 这么个应用场景了,很大一部分情况都会选择下载尽可能清晰的质量吧。
猜想直接选择 quality 值最大那个大概就可以了。
可能还得判断一下大会员状态。
subprocess.spawnSync 看要不要改用簡單的來達成
child_process.execSync(downloadCommand);
或是可以有其他追蹤 download progress 的方法
非常感谢开发这么好用的程序,请问可以自定义保存路径么?如果不支持,能否考虑支持下,谢谢!
C:\Users\Administrator>where aria2c
d:\program files\!cli\aria2c.exe
C:\Users\Administrator>where ffmpeg
C:\ProgramData\chocolatey\bin\ffmpeg.exe
C:\Users\Administrator>bilibili-get https://www.bilibili.com/video/av29332332
extracting video metadata...
[1/1] av29332332: start download "某伊藤姓高颜值特摄女饭庆生活动现场 伊藤美来201
7生日live"...
[1/1] av29332332: video quality:
[1/1] av29332332: 74 flv720_p60 高清 720P60
[1/1] av29332332: 64 flv720 高清 720P
[1/1] av29332332: * 32 flv480 清晰 480P
[1/1] av29332332: 15 flv360 流畅 360P
[1/1] av29332332: output format: flv
[1/1] av29332332: output path:
[1/1] av29332332: C:\Users\Administrator\av29332332 某伊藤姓高颜值特摄女饭庆
生活动现场(1) 伊藤美来2017生日live.flv
[1/1] av29332332: downloading video segment 1/8...
[1/1] av29332332: downloading video segment 2/8...
[1/1] av29332332: downloading video segment 3/8...
[1/1] av29332332: downloading video segment 4/8...
[1/1] av29332332: downloading video segment 5/8...
[1/1] av29332332: downloading video segment 6/8...
[1/1] av29332332: downloading video segment 7/8...
[1/1] av29332332: downloading video segment 8/8...
[1/1] av29332332: merging segment files...
ERROR: ENOENT: no such file or directory, unlink 'C:\Users\Administrator\av29332
332-1.flv'
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.