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

[BUG]一运行就闪退 #428

Closed
coder-movers opened this issue May 8, 2023 · 5 comments
Closed

[BUG]一运行就闪退 #428

coder-movers opened this issue May 8, 2023 · 5 comments
Assignees
Labels
故障(bug) 代码问题导致的错误(Bugs caused by code problems) 额外求助(help wanted) 非项目代码错误的求助(Extra attention is needed) 无效(invalid) 非代码故障导致错误或异常(Non-code faults causing errors or anomalies)

Comments

@coder-movers
Copy link

配置文件:config.ini

[uid]
# 用户主页(非视频链接)
# 单视频请用TikTokDownload或TikTokWeb
uid = https://www.douyin.com/user/MS4wLjABAAAAgRo6dotWqsHTdPq6LBDJM2pK64k23Shy7xEHKYGKQaSTYpYRuL2Yu45S0rAoVJGU

[music]
# 视频原声保存(yes|no)
music = no

[mode]
# 下载模式(post|like)
# 下载喜欢页视频请确保开放所有人可见
mode = post

[cookie]
cookie = 此处是我的全部cookie,且删除了所有分号后的换行符
# 收藏、历史、好友、推荐等需要登录后的cookie
# 下载发布作品和点赞只需填写'odin_tt;passport_csrf_token;'即可
# 下载个人收藏、好友作品、主页推荐等还需填写'sessionid_ss;'(32位)即可
# 如何填写?网页登录后在开发者工具(F12)里查看,嫌弃麻烦直接填写所有cookie值
# 粘贴的时候要删掉所有分号后的换行符

[interval]
# 根据作品发布日期区间下载作品
# 例如2022-01-01|2023-01-01下载的是2022年所有作品
# 格式不要填错
# 填0即是全部时间下载
interval = 0

[update]
# 选择是否自动更新(yes|no)
# 由于抖音频繁更新推荐开启此项
update = no

日志:
[2023-05-08 17:17:53,133] - Log.py] - INFO: Windows
[2023-05-08 17:17:53,294] - Log.py] - INFO: [ 提示 ]:批量获取所有视频中!
[2023-05-08 17:17:53,295] - Log.py] - INFO: [ 提示 ]:用户的sec_id=MS4wLjABAAAAgRo6dotWqsHTdPq6LBDJM2pK64k23Shy7xEHKYGKQaSTYpYRuL2Yu45S0rAoVJGU

@coder-movers coder-movers added 故障(bug) 代码问题导致的错误(Bugs caused by code problems) 额外求助(help wanted) 非项目代码错误的求助(Extra attention is needed) 无效(invalid) 非代码故障导致错误或异常(Non-code faults causing errors or anomalies) labels May 8, 2023
@coder-movers
Copy link
Author

又尝试了使用web版,页面正常打开运行,cookie信息填入以后解析会进404页面,控制台报错

{"odin_tt":"0c97e1b16a03cf92adbfc7a77bae96f08ce4ba2a608bd48baa997c3b571a6551cea44dd5a18fff31f794796e7b2fe08cc7696ef7a10aedb45b3edf6ae280f4e1","passport
_csrf_token":"2ffb2ee7e0a1ff8301e469ec743828d6","sessionid_ss":"0fb4535c74b403edc1069f3bce7d2fee","ttwid":"1%7C1PYglNsU--KZjpJnm59Vi6s7iJcKTCGjyesLQg4O
y_I%7C1681843146%7C0e2f1f1b5224f1cfa622eb7268d5126a9b8a241c6c115cbd717753657c303bc7","msToken":"SIywXvEMk9az_a24cDmF1-WU2ER2kQyi3L1eswH45IZ_-L6BcAaxpEK
5u_2ZaaNoFWOm7N9FlWfY-9eqKTjUIc2olc2GOK840boWKwqd4J2sm862pZ188w=="}
open shorturl ok
作品id  7223227038792977721
https://www.douyin.com/aweme/v1/web/aweme/detail/?aweme_id=7223227038792977721&aid=1128&version_name=23.5.0&device_platform=android&os_version=2333&X-B
ogus=DFSzswVu1UtANxXhtCaNVM9WX7nR
open url ok
GetInfo ok
TypeError: response.data.aweme_detail.desc.replaceAll is not a function
    at D:\Program Files\TikTokWeb\routes\api.js:97:68
    at processTicksAndRejections (internal/process/task_queues.js:95:5)
TypeError: response.data.aweme_detail.desc.replaceAll is not a function
    at D:\Program Files\TikTokWeb\routes\api.js:97:68
    at processTicksAndRejections (internal/process/task_queues.js:95:5)
GET /api?url=https://v.douyin.com/Do8Chrr/ 304 748.432 ms - -
(node:131004) UnhandledPromiseRejectionWarning: ReferenceError: reject is not defined
    at GetInfo (D:\Program Files\TikTokWeb\routes\api.js:127:9)
    at processTicksAndRejections (internal/process/task_queues.js:95:5)
(node:131004) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function witho
ut a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the
CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 6)
Error [ERR_HTTP_HEADERS_SENT]: Cannot set headers after they are sent to the client
    at ServerResponse.setHeader (_http_outgoing.js:561:11)
    at ServerResponse.header (D:\Program Files\TikTokWeb\node_modules\express\lib\response.js:794:10)
    at ServerResponse.contentType (D:\Program Files\TikTokWeb\node_modules\express\lib\response.js:624:15)
    at ServerResponse.send (D:\Program Files\TikTokWeb\node_modules\express\lib\response.js:149:14)
    at done (D:\Program Files\TikTokWeb\node_modules\express\lib\response.js:1035:10)
    at tryHandleCache (D:\Program Files\TikTokWeb\node_modules\ejs\lib\ejs.js:280:5)
    at View.exports.renderFile [as engine] (D:\Program Files\TikTokWeb\node_modules\ejs\lib\ejs.js:491:10)
    at View.render (D:\Program Files\TikTokWeb\node_modules\express\lib\view.js:135:8)
    at tryRender (D:\Program Files\TikTokWeb\node_modules\express\lib\application.js:657:10)
    at Function.render (D:\Program Files\TikTokWeb\node_modules\express\lib\application.js:609:3) {
  code: 'ERR_HTTP_HEADERS_SENT'
}
Error [ERR_HTTP_HEADERS_SENT]: Cannot set headers after they are sent to the client
    at ServerResponse.setHeader (_http_outgoing.js:561:11)
    at ServerResponse.header (D:\Program Files\TikTokWeb\node_modules\express\lib\response.js:794:10)
    at ServerResponse.contentType (D:\Program Files\TikTokWeb\node_modules\express\lib\response.js:624:15)
    at ServerResponse.send (D:\Program Files\TikTokWeb\node_modules\express\lib\response.js:149:14)
    at done (D:\Program Files\TikTokWeb\node_modules\express\lib\response.js:1035:10)
    at tryHandleCache (D:\Program Files\TikTokWeb\node_modules\ejs\lib\ejs.js:280:5)
    at View.exports.renderFile [as engine] (D:\Program Files\TikTokWeb\node_modules\ejs\lib\ejs.js:491:10)
    at View.render (D:\Program Files\TikTokWeb\node_modules\express\lib\view.js:135:8)
    at tryRender (D:\Program Files\TikTokWeb\node_modules\express\lib\application.js:657:10)
    at Function.render (D:\Program Files\TikTokWeb\node_modules\express\lib\application.js:609:3)
GET /static/stylesheets/404.css 304 0.460 ms - -

@coder-movers
Copy link
Author

而且cookie中有两个msToken,两个都试了,都不好用

@Johnserf-Seed
Copy link
Owner

image
你的cookie有问题

@Johnserf-Seed
Copy link
Owner

Johnserf-Seed commented May 9, 2023

配置文件:config.ini

[uid]
# 用户主页(非视频链接)
# 单视频请用TikTokDownload或TikTokWeb
uid = https://www.douyin.com/user/MS4wLjABAAAAgRo6dotWqsHTdPq6LBDJM2pK64k23Shy7xEHKYGKQaSTYpYRuL2Yu45S0rAoVJGU

[music]
# 视频原声保存(yes|no)
music = no

[mode]
# 下载模式(post|like)
# 下载喜欢页视频请确保开放所有人可见
mode = post

[cookie]
cookie = 此处是我的全部cookie,且删除了所有分号后的换行符
# 收藏、历史、好友、推荐等需要登录后的cookie
# 下载发布作品和点赞只需填写'odin_tt;passport_csrf_token;'即可
# 下载个人收藏、好友作品、主页推荐等还需填写'sessionid_ss;'(32位)即可
# 如何填写?网页登录后在开发者工具(F12)里查看,嫌弃麻烦直接填写所有cookie值
# 粘贴的时候要删掉所有分号后的换行符

[interval]
# 根据作品发布日期区间下载作品
# 例如2022-01-01|2023-01-01下载的是2022年所有作品
# 格式不要填错
# 填0即是全部时间下载
interval = 0

[update]
# 选择是否自动更新(yes|no)
# 由于抖音频繁更新推荐开启此项
update = no

日志: [2023-05-08 17:17:53,133] - Log.py] - INFO: Windows [2023-05-08 17:17:53,294] - Log.py] - INFO: [ 提示 ]:批量获取所有视频中! [2023-05-08 17:17:53,295] - Log.py] - INFO: [ 提示 ]:用户的sec_id=MS4wLjABAAAAgRo6dotWqsHTdPq6LBDJM2pK64k23Shy7xEHKYGKQaSTYpYRuL2Yu45S0rAoVJGU

cookie没设置,看#311

@coder-movers
Copy link
Author

感谢大佬抽空回复,我再尝试一下

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
故障(bug) 代码问题导致的错误(Bugs caused by code problems) 额外求助(help wanted) 非项目代码错误的求助(Extra attention is needed) 无效(invalid) 非代码故障导致错误或异常(Non-code faults causing errors or anomalies)
Projects
None yet
Development

No branches or pull requests

2 participants