EtherLeaF / nonebot-plugin-colab-novelai

解放你的双手,让Colab持续给你提供算力生产色图!
MIT License
29 stars 1 forks source link

运行插件保存:unsupported operand type(s) for |: '_GenericAlias' and 'type' #4

Closed xi-yue-233 closed 1 year ago

xi-yue-233 commented 1 year ago

11-20 01:42:27 [ERROR] nonebot | Failed to import "nonebot_plugin_colab_novelai" Traceback (most recent call last): File "E:\qqbot-nonebot\Nonebot\nb2\bot.py", line 28, in nonebot.load_from_toml("pyproject.toml") File "D:\python-software\lib\site-packages\nonebot\plugin\load.py", line 122, in load_from_toml return load_all_plugins(plugins, plugin_dirs) File "D:\python-software\lib\site-packages\nonebot\plugin\load.py", line 59, in load_all_plugins return manager.load_all_plugins() File "D:\python-software\lib\site-packages\nonebot\plugin\manager.py", line 168, in load_all_plugins return set( File "D:\python-software\lib\site-packages\nonebot\plugin\manager.py", line 169, in filter(None, (self.load_plugin(name) for name in self.available_plugins)) File "D:\python-software\lib\site-packages\nonebot\plugin\manager.py", line 141, in load_plugin module = importlib.import_module(name) File "D:\python-software\lib\importlib__init.py", line 127, in import_module return _bootstrap._gcd_import(name[level:], package, level) File "", line 1030, in _gcd_import File "", line 1007, in _find_and_load File "", line 986, in _find_and_load_unlocked File "", line 680, in _load_unlocked File "D:\python-software\lib\site-packages\nonebot\plugin\manager.py", line 233, in exec_module super().exec_module(module) File "", line 855, in exec_module File "", line 228, in _call_with_frames_removed File "D:\python-software\lib\site-packages\nonebot_plugin_colab_novelai__init__.py", line 16, in from .utils import chrome_driver, inject_image_to_state File "D:\python-software\lib\site-packages\nonebot_plugin_colab_novelai\utils\init__.py", line 1, in from .webdriver import ( File "D:\python-software\lib\site-packages\nonebot_plugin_colab_novelai\utils\webdriver.py", line 14, in from .distributed import PLUGIN_DIR File "D:\python-software\lib\site-packages\nonebot_plugin_colab_novelai\utils\distributed.py", line 13, in from ..config import plugin_config File "D:\python-software\lib\site-packages\nonebot_plugin_colab_novelai\config.py", line 7, in class Config(BaseModel, extra=Extra.ignore): File "D:\python-software\lib\site-packages\nonebot_plugin_colab_novelai\config.py", line 22, in Config nai_nsfw_tags: Optional[List[str] | str] = None TypeError: unsupported operand type(s) for |: '_GenericAlias' and 'type'

image

EtherLeaF commented 1 year ago

Python版本的问题 下个更新会修复