TDK1969 / nonebot_plugin_bilibilibot

基于Nonebot的bilibili通知插件,可将up主,主播以及番剧的更新/直播动态推送到QQ
GNU General Public License v3.0
99 stars 7 forks source link

nonebot.adapters.onebot.v11.exception.ActionFailed #46

Closed d448153274 closed 1 year ago

d448153274 commented 1 year ago

05-24 23:45:15 [SUCCESS] nonebot | OneBot V11 2332846978 | [message.group.normal]: Message 2084791699 from 448153274@[群: 797717129] "/bilihelp" 05-24 23:45:15 [DEBUG] nonebot | Checking for matchers in priority 1... 05-24 23:45:15 [INFO] nonebot | Event will be handled by Matcher(type='message', module=nonebot_plugin_bilibilibot) 05-24 23:45:15 [DEBUG] nonebot | Running Matcher(type='message', module=nonebot_plugin_bilibilibot) 05-24 23:45:15 [DEBUG] nonebot | Running handler Dependent(call=sendHelpMsg) 05-24 23:45:15 [DEBUG] nonebot | OneBot V11 | Calling API send_msg 05-24 23:45:21 [INFO] nonebot | Matcher(type='message', module=nonebot_plugin_bilibilibot) running complete 05-24 23:45:21 [ERROR] nonebot | Running Matcher(type='message', module=nonebot_plugin_bilibilibot) failed. Traceback (most recent call last): File "", line 1, in File "/root/anaconda3/envs/kamijo/lib/python3.9/multiprocessing/spawn.py", line 116, in spawn_main exitcode = _main(fd, parent_sentinel) File "/root/anaconda3/envs/kamijo/lib/python3.9/multiprocessing/spawn.py", line 129, in _main return self._bootstrap(parent_sentinel) File "/root/anaconda3/envs/kamijo/lib/python3.9/multiprocessing/process.py", line 315, in _bootstrap self.run() File "/root/anaconda3/envs/kamijo/lib/python3.9/multiprocessing/process.py", line 108, in run self._target(*self._args, **self._kwargs) File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/uvicorn/_subprocess.py", line 76, in subprocess_started target(sockets=sockets) File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/uvicorn/server.py", line 60, in run return asyncio.run(self.serve(sockets=sockets)) File "/root/anaconda3/envs/kamijo/lib/python3.9/asyncio/runners.py", line 44, in run return loop.run_until_complete(main) File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/nonebot/message.py", line 142, in _check_matcher await _run_matcher(Matcher, bot, event, state, stack, dependency_cache)

File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/nonebot/message.py", line 188, in _run_matcher await matcher.run(bot, event, state, stack, dependency_cache) File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/nonebot/internal/matcher/matcher.py", line 727, in run await self.simple_run(bot, event, state, stack, dependency_cache) File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/nonebot/internal/matcher/matcher.py", line 702, in simpl$_run await handler( File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/nonebot/dependencies/init.py", line 108, in call return await cast(Callable[..., Awaitable[R]], self.call)(values) File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/nonebot_plugin_bilibilibot/init.py", line 360, in sen dHelpMsg await helpCommand.finish(helpMsg) File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/nonebot/internal/matcher/matcher.py", line 476, in finish await cls.send(message, kwargs) File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/nonebot/internal/matcher/matcher.py", line 461, in send return await bot.send(event=event, message=_message, kwargs) File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/nonebot/adapters/onebot/v11/bot.py", line 219, in send return await self.class.send_handler(self, event, message, kwargs) File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/nonebot/adapters/onebot/v11/bot.py", line 174, in send return await bot.send_msg(params) File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/nonebot/internal/adapter/bot.py", line 120, in call_api raise exception File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/nonebot/internal/adapter/bot.py", line 98, in call_api result = await self.adapter._call_api(self, api, data) File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/nonebot/adapters/onebot/v11/adapter.py", line 132, in _ca ll_api return handle_api_result( File "/root/anaconda3/envs/kamijo/lib/python3.9/site-packages/nonebot/adapters/onebot/v11/utils.py", line 58, in handle _api_result raise ActionFailed(**result) nonebot.adapters.onebot.v11.exception.ActionFailed

运行环境:ubuntu18.04 Python:3.9.12

安装了nb plugin install nonebot-plugin-apscheduler 再安装nb plugin install nonebot-plugin-bilibilibot .env配置了SUPERSUSERS = ["XXXX"] 目前私聊bot /bilihelp这些命令是正常的,但是在群里使用/bilihelp和其他命令都没有回应 使用/关注up 能从后台看到报错:权限不足 403

网上查了下说可能是cqhttp的问题,不过我之前有用其他插件,能正常使用,感觉不是cqhttp的事,不知道是啥原因。。。

TDK1969 commented 1 year ago

权限不足 403的错误正在修改,见https://github.com/TDK1969/nonebot_plugin_bilibilibot/issues/44 /bilihelp命令失效的问题我没有复现,请提供更多信息

d448153274 commented 1 year ago

权限不足 403的错误正在修改,见#44 /bilihelp命令失效的问题我没有复现,请提供更多信息

抱歉我刚玩nonebot,不是非常懂,我说一下我操作步骤 我大概是重新创建的一个bot nb create,选择的是OneBot V11 然后nb plugin install nonebot_plugin_apscheduler 然后nb plugin install nonebot-plugin-bilibilibot 接着编辑.env加上SUPERSUSERS = ["XXXX"] 最后nb run

这时候在群里/bilihelp 后台就报我上述错误了

。。不知道我这边能提供哪些有用的信息呢?

TDK1969 commented 1 year ago

你的adapter用的是哪个,可以更新一下