Skip to content
This repository has been archived by the owner on Oct 10, 2024. It is now read-only.

Go-cqhttp 升级到 beta7-fix1后无法输出b40图片 #7

Closed
ghost opened this issue Sep 17, 2021 · 3 comments
Closed

Go-cqhttp 升级到 beta7-fix1后无法输出b40图片 #7

ghost opened this issue Sep 17, 2021 · 3 comments
Labels
bug Something isn't working

Comments

@ghost
Copy link

ghost commented Sep 17, 2021

Centos8 Stream w/ Python 3.9.7
更新时未变更已有配置文件

Maibot Log:
09-17 20:31:54 [ERROR] nonebot | Running matcher <Matcher from maimaidx, type=message, priority=1, temp=False> failed.
Traceback (most recent call last):
File "/root/mai-bot/bot.py", line 37, in
nonebot.run(app="bot:app")
File "/usr/local/lib/python3.9/site-packages/nonebot/init.py", line 227, in run
get_driver().run(host, port, *args, **kwargs)
File "/usr/local/lib/python3.9/site-packages/nonebot/drivers/fastapi.py", line 170, in run
uvicorn.run(app or self.server_app,
File "/usr/local/lib/python3.9/site-packages/uvicorn/main.py", line 386, in run
server.run()
File "/usr/local/lib/python3.9/site-packages/uvicorn/server.py", line 49, in run
loop.run_until_complete(self.serve(sockets=sockets))
File "/usr/local/lib/python3.9/site-packages/nonebot/message.py", line 126, in _check_matcher
await _run_matcher(Matcher, bot, event, state)

File "/usr/local/lib/python3.9/site-packages/nonebot/message.py", line 154, in run_matcher
await matcher.run(bot, event, state)
File "/usr/local/lib/python3.9/site-packages/nonebot/matcher.py", line 544, in run
await handler(self, bot, event, state
)
File "/usr/local/lib/python3.9/site-packages/nonebot/handler.py", line 81, in call
await self.func(
File "/root/mai-bot/src/plugins/maimaidx.py", line 347, in _
await best_40_pic.send(Message([
File "/usr/local/lib/python3.9/site-packages/nonebot/matcher.py", line 459, in send
return await bot.send(event=event, message=message, **kwargs)
File "/usr/local/lib/python3.9/site-packages/nonebot/adapters/cqhttp/bot.py", line 456, in send
return await self.send_msg(**params)
File "/usr/local/lib/python3.9/site-packages/nonebot/adapters/cqhttp/bot.py", line 400, in call_api
return await super().call_api(api, **data)
File "/usr/local/lib/python3.9/site-packages/nonebot/adapters/_base.py", line 200, in call_api
raise exception
File "/usr/local/lib/python3.9/site-packages/nonebot/adapters/_base.py", line 183, in call_api
result = await self._call_api(api, **data)
File "/usr/local/lib/python3.9/site-packages/nonebot/adapters/cqhttp/bot.py", line 347, in _call_api
return _handle_api_result(await ResultStore.fetch(
File "/usr/local/lib/python3.9/site-packages/nonebot/adapters/cqhttp/bot.py", line 188, in _handle_api_result
raise ActionFailed(**result)
nonebot.adapters.cqhttp.exception.ActionFailed: <ActionFailed data=None, echo={'seq': 1}, msg=SEND_MSG_API_ERROR, retcode=100, status=failed, wording=请参考 go-cqhttp 端输出>

Go-cqhttp Log:
[2021-09-17 20:31:54] [WARNING]: 警告: 群 abcdefghi 消息图片上传失败: upload failed: upload failed: 82
[2021-09-17 20:31:54] [WARNING]: 群消息发送失败: 消息为空.

@Diving-Fish Diving-Fish added the bug Something isn't working label Sep 18, 2021
@ghost
Copy link
Author

ghost commented Sep 18, 2021

新增: [CQ:image] 类型增加 subType 字段, 用于获取或设置图片子类型. by @Mrs4s
https://github.com/Mrs4s/go-cqhttp/blob/master/docs/cqhttp.md#%E5%9B%BE%E7%89%87

也许是少了subType字段的原因?

@Diving-Fish
Copy link
Owner

我猜你可以看看这个:
Mrs4s/go-cqhttp#1063
开发者应该已经修复了。看看beta7-fix2

@ghost
Copy link
Author

ghost commented Sep 19, 2021

beta7-fix2已修复,感谢。
Closing issue.

@ghost ghost closed this as completed Sep 19, 2021
This issue was closed.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant