Closed Speechless22 closed 1 year ago
poetry run python main.py
启动后有一个报错 `2023-02-14 09:38:10.708 | ERROR | core:install_modules:258 - Traceback (most recent call last):
File "/home/ubuntu/Production/sagiri-bot/main.py", line 110, in
File "/home/ubuntu/Production/sagiri-bot/core/init.py", line 252, in install_modules saya.require(f"{module_base_path}.{module}") │ └ <function Saya.require at 0xffff7f64d870> └ <graia.saya.Saya object at 0xffff7e672620>
File "/home/ubuntu/.cache/pypoetry/virtualenvs/sagiri-bot-AVwYQ3_2-py3.10/lib/python3.10/site-packages/graia/saya/init.py", line 118, in require
channel = self.require_resolve(module)
│ │ └ 'modules.self_contained.chat_gpt'
│ └ <function Saya.require_resolve at 0xffff7f64d750>
└ <graia.saya.Saya object at 0xffff7e672620>
File "/home/ubuntu/.cache/pypoetry/virtualenvs/sagiri-bot-AVwYQ3_2-py3.10/lib/python3.10/site-packages/graia/saya/init.py", line 76, in require_resolve
imported_module = importlib.import_module(module, module)
│ │ │ └ 'modules.self_contained.chat_gpt'
│ │ └ 'modules.self_contained.chat_gpt'
│ └ <function import_module at 0xffff80650af0>
└ <module 'importlib' from '/usr/lib/python3.10/importlib/init.py'>
File "/usr/lib/python3.10/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
│ │ │ │ │ └ 0
│ │ │ │ └ 'modules.self_contained.chat_gpt'
│ │ │ └ 0
│ │ └ 'modules.self_contained.chat_gpt'
│ └ <function _gcd_import at 0xffff8076f400>
└ <module '_frozen_importlib' (frozen)>
File "
File "/home/ubuntu/Production/sagiri-bot/modules/self_contained/chat_gpt/init.py", line 16, in
File "/home/ubuntu/Production/sagiri-bot/modules/self_contained/chat_gpt/conversation_manager.py", line 17, in
AttributeError: 'NoneType' object has no attribute 'get'` 发出的图片中缺少字体
问题
执行poetry install后出现警告:Warning: poetry.lock is not consistent with pyproject.toml. You may be getting improper dependencies.Run![image](https://user-images.githubusercontent.com/61347609/218672238-00170169-1acb-4b4c-8ff4-f68c107fa990.png)
poetry lock [--no-update]
to fix it. 随后执行poetry lock无警告/报错 最后再执行poetry install提示No dependencies to install or update 随后python3 main.py时提示依赖报错,似乎lock里的依赖项并未安装 附图如何复现
No response
预期行为
No response
使用环境
日志/截图
No response