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

群聊中回复图片消息@机器人时获取到的 url 不正确 #198

Closed
NekoAria opened this issue May 28, 2021 · 1 comment
Closed
Labels
bug Something isn't working

Comments

@NekoAria
Copy link
Contributor

群聊中回复图片消息@机器人时获取到的 url 不正确。


情形如下:
image
image
image
image

上面图中错误的 url :

https://c2cpicdw.qpic.cn/offpic_new/0/0-0-DD953D467F10B7C600FEEC30FD7B20A0/0
https://c2cpicdw.qpic.cn/offpic_new/0/0-0-6E7ABD451C8FA1AC8F6B6C5B8186EE80/0

对应的日志:

05-28 15:09:42 [INFO] nonebot | CQHTTP xxx | [message.group.normal]: Message -2003465364 from xxx@[群:xxx] "[CQ:image,file=dd953d467f10b7c600feec30fd7b20a0.image,url=https://gchat.qpic.cn/gchatpic_new/[发图片的群友 qq ]/747598003-2983752310-DD953D467F10B7C600FEEC30FD7B20A0/0?term=3]"
05-28 15:57:39 [INFO] nonebot | CQHTTP xxx | [message.group.normal]: Message 370583266 from xxx@[群:xxx] "[CQ:image,file=6e7abd451c8fa1ac8f6b6c5b8186ee80.image,url=https://gchat.qpic.cn/gchatpic_new/[发图片的群友 qq ]/747598003-2570598220-6E7ABD451C8FA1AC8F6B6C5B8186EE80/0?term=3]"

运行环境:

  • 系统:Debian GNU/Linux 10 (buster) x86_64
  • Node.js 版本:v14.16.1
  • go-cqhttp 版本:v1.0.0-beta4
  • cq-picsearcher-bot 版本:v2.29.4
@Tsuk1ko Tsuk1ko added the bug Something isn't working label May 28, 2021
@Tsuk1ko
Copy link
Owner

Tsuk1ko commented May 28, 2021

这个其实是修复 #195 时做的一个调整,当日 https://gchat.qpic.cn/gchatpic_new/ 出了问题,被 saucenao 下载时变成防盗链水印了,因此统一替换成 https://c2cpicdw.qpic.cn/offpic_new/,它们是通用的

404 原因是机器人这边获取到的链接 https://gchat.qpic.cn/gchatpic_new/X/Y-Z-HASH/0 中的 Z 好像莫名其妙丢失了,这本应是个合法 qq 号,因此目前干脆直接统一替换成 10000 了,至于 XY 是不关键的因此干脆统一脱敏处理了

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants