没有log文件,hb run不起来
运行命令:hb run
终端报错:/usr/local/QQbot/bot# hb run
Traceback (most recent call last):
File "/usr/local/bin/hb", line 8, in <module>
sys.exit(main())
File "/usr/local/lib/python3.8/dist-packages/click/core.py", line 1130, in __call__
return self.main(*args, **kwargs)
File "/usr/local/lib/python3.8/dist-packages/click/core.py", line 1055, in main
rv = self.invoke(ctx)
File "/usr/local/lib/python3.8/dist-packages/click/core.py", line 1657, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/usr/local/lib/python3.8/dist-packages/click/core.py", line 1404, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/usr/local/lib/python3.8/dist-packages/click/core.py", line 760, in invoke
return __callback(*args, **kwargs)
File "/usr/local/lib/python3.8/dist-packages/haruka_bot/cli/__init__.py", line 14, in run
from .bot import run
File "/usr/local/lib/python3.8/dist-packages/haruka_bot/cli/bot.py", line 5, in <module>
from nonebot.adapters.onebot.v11 import Adapter
File "/usr/local/lib/python3.8/dist-packages/nonebot/adapters/onebot/__init__.py", line 12, in <module>
from .v11 import Bot as V11Bot
File "/usr/local/lib/python3.8/dist-packages/nonebot/adapters/onebot/v11/__init__.py", line 10, in <module>
from .event import *
File "/usr/local/lib/python3.8/dist-packages/nonebot/adapters/onebot/v11/event.py", line 120, in <module>
class MessageEvent(Event):
File "pydantic/main.py", line 197, in pydantic.main.ModelMetaclass.__new__
File "pydantic/fields.py", line 506, in pydantic.fields.ModelField.infer
File "pydantic/fields.py", line 436, in pydantic.fields.ModelField.__init__
File "pydantic/fields.py", line 552, in pydantic.fields.ModelField.prepare
File "pydantic/fields.py", line 668, in pydantic.fields.ModelField._type_analysis
File "/usr/lib/python3.8/typing.py", line 774, in __subclasscheck__
return issubclass(cls, self.__origin__)
TypeError: issubclass() arg 1 must be a class
运行环境
Ubuntu20.04
HarukaBot 版本
1.5.4
go-cqhttp 版本
1.0.1
错误描述
事情起因说起来还是bot截图会出现验证码的问题,后来想着是不是bot太旧了要升级 运行更新命令之后反而报错了并且我无法解决,最好只得到云服务控制台重置了系统 于是全新Ubuntu系统,阿里云服务器Ubuntu20.04 在安装bot之前只运行过: sudo pip3 install --upgrade pip sudo apt update sudo apt upgrade sudo apt install build-essential curl wget git 然后就创建了bot目录,安装脚手架,运行命令: pip install haruka-bot 安装过程没有报错 但是就是run报错了(准确说是在填写了主人q号之后回车就报错了)
报错日志(如果有)