01-27 21:37:03 [SUCCESS] nonebot | mirai2 3440174624 | [FriendMessage]: {'self_id': 3440174624, 'type': 'FriendMessage', 'message_chain': [{'type': 'Plain', 'data': {'text': '天气上海'}}], 'source': {'id': 26487, 'time': '2023-01-27T13:37:03+00:00'}, 'sender': {'id': 1397749594, 'nickname': '地铁dixiatielu', 'remark': '地铁dixiatielu'}, 'quote': None}
01-27 21:37:03 [INFO] nonebot | Event will be handled by Matcher(type='message', module=nonebot_plugin_heweather)
01-27 21:37:03 [INFO] nonebot_plugin_heweather | 使用个人开发版API
01-27 21:37:05 [INFO] nonebot | Matcher(type='message', module=nonebot_plugin_heweather) running complete
01-27 21:37:05 [ERROR] nonebot | Running Matcher(type='message', module=nonebot_plugin_heweather) failed.
Traceback (most recent call last):
File "<string>", line 33, in <module>
File "D:\QQBot\Nonebot\dxtlBot\.venv\lib\site-packages\nonebot\__init__.py", line 273, in run
get_driver().run(*args, **kwargs)
File "D:\QQBot\Nonebot\dxtlBot\.venv\lib\site-packages\nonebot\drivers\fastapi.py", line 187, in run
uvicorn.run(
File "D:\QQBot\Nonebot\dxtlBot\.venv\lib\site-packages\uvicorn\main.py", line 569, in run
server.run()
File "D:\QQBot\Nonebot\dxtlBot\.venv\lib\site-packages\uvicorn\server.py", line 60, in run
return asyncio.run(self.serve(sockets=sockets))
File "C:\Python310\lib\asyncio\runners.py", line 44, in run
return loop.run_until_complete(main)
File "C:\Python310\lib\asyncio\base_events.py", line 636, in run_until_complete
self.run_forever()
File "C:\Python310\lib\asyncio\windows_events.py", line 321, in run_forever
super().run_forever()
File "C:\Python310\lib\asyncio\base_events.py", line 603, in run_forever
self._run_once()
File "C:\Python310\lib\asyncio\base_events.py", line 1899, in _run_once
handle._run()
File "C:\Python310\lib\asyncio\events.py", line 80, in _run
self._context.run(self._callback, *self._args)
File "D:\QQBot\Nonebot\dxtlBot\.venv\lib\site-packages\nonebot\message.py", line 141, in _check_matcher
await _run_matcher(Matcher, bot, event, state, stack, dependency_cache)
> File "D:\QQBot\Nonebot\dxtlBot\.venv\lib\site-packages\nonebot\message.py", line 187, in _run_matcher
await matcher.run(bot, event, state, stack, dependency_cache)
File "D:\QQBot\Nonebot\dxtlBot\.venv\lib\site-packages\nonebot\internal\matcher\matcher.py", line 732, in run
await self.simple_run(bot, event, state, stack, dependency_cache)
File "D:\QQBot\Nonebot\dxtlBot\.venv\lib\site-packages\nonebot\internal\matcher\matcher.py", line 707, in simple_run
await handler(
File "D:\QQBot\Nonebot\dxtlBot\.venv\lib\site-packages\nonebot\dependencies\__init__.py", line 108, in __call__
return await cast(Callable[..., Awaitable[R]], self.call)(**values)
File "D:\QQBot\Nonebot\dxtlBot\.venv\lib\site-packages\nonebot_plugin_heweather\__init__.py", line 49, in _
await weather.finish(MessageSegment.image(img))
File "D:\QQBot\Nonebot\dxtlBot\.venv\lib\site-packages\nonebot\internal\matcher\matcher.py", line 481, in finish
await cls.send(message, **kwargs)
File "D:\QQBot\Nonebot\dxtlBot\.venv\lib\site-packages\nonebot\internal\matcher\matcher.py", line 466, in send
return await bot.send(event=event, message=_message, **kwargs)
File "D:\QQBot\Nonebot\dxtlBot\.venv\lib\site-packages\nonebot\adapters\mirai2\bot.py", line 35, in send
message = MessageChain(message)
File "D:\QQBot\Nonebot\dxtlBot\.venv\lib\site-packages\nonebot\adapters\mirai2\message.py", line 403, in __init__
raise ValueError(
ValueError: Type MessageSegment is not supported in mirai adapter.
或许是使用mirai http适配器的原因?