Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

貌似Pydantic v2没有适配好 #17

Open
ChangMenQAQ opened this issue Oct 26, 2024 · 1 comment
Open

貌似Pydantic v2没有适配好 #17

ChangMenQAQ opened this issue Oct 26, 2024 · 1 comment

Comments

@ChangMenQAQ
Copy link

10-26 10:37:43 [ERROR] nonebot | Failed to import "nonebot_plugin_mahjong_scoreboard"
Traceback (most recent call last):
File "", line 14, in
File "C:\Users\Administrator\Desktop\YPBot.venv\Lib\site-packages\nonebot\plugin\load.py", line 131, in load_from_toml
return load_all_plugins(plugins, plugin_dirs)
File "C:\Users\Administrator\Desktop\YPBot.venv\Lib\site-packages\nonebot\plugin\load.py", line 65, in load_all_plugins
return manager.load_all_plugins()
File "C:\Users\Administrator\Desktop\YPBot.venv\Lib\site-packages\nonebot\plugin\manager.py", line 203, in load_all_plugins
return set(
File "C:\Users\Administrator\Desktop\YPBot.venv\Lib\site-packages\nonebot\plugin\manager.py", line 204, in
filter(None, (self.load_plugin(name) for name in self.available_plugins))

File "C:\Users\Administrator\Desktop\YPBot.venv\Lib\site-packages\nonebot\plugin\manager.py", line 169, in load_plugin
module = importlib.import_module(self.searched_plugin_ids[name])
File "C:\Users\Administrator\AppData\Local\Programs\Python\Python312\Lib\importlib_init
.py", line 90, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 1387, in _gcd_import
File "", line 1360, in find_and_load
File "", line 1331, in find_and_load_unlocked
File "", line 935, in load_unlocked
File "C:\Users\Administrator\Desktop\YPBot.venv\Lib\site-packages\nonebot\plugin\manager.py", line 255, in exec_module
super().exec_module(module)
File "", line 995, in exec_module
File "", line 488, in call_with_frames_removed
File "C:\Users\Administrator\Desktop\YPBot\YPBot\plugins\nonebot_plugin_mahjong_scoreboard_init
.py", line 17, in
from .controller import game_record, game_query, game_export, season_query, season_manage, season_user_point_query,
File "C:\Users\Administrator\Desktop\YPBot\YPBot\plugins\nonebot_plugin_mahjong_scoreboard\controller_init
.py", line 1, in
from . import game_export
File "C:\Users\Administrator\Desktop\YPBot\YPBot\plugins\nonebot_plugin_mahjong_scoreboard\controller\game_export.py", line 9, in
from .mapper.game_csv_mapper import write_games_csv
File "C:\Users\Administrator\Desktop\YPBot\YPBot\plugins\nonebot_plugin_mahjong_scoreboard\controller\mapper_init.py", line 7, in
from ...model import PlayerAndWind, GameState, SeasonState, Wind
File "C:\Users\Administrator\Desktop\YPBot\YPBot\plugins\nonebot_plugin_mahjong_scoreboard\model_init.py", line 1, in
from .business import *
File "C:\Users\Administrator\Desktop\YPBot\YPBot\plugins\nonebot_plugin_mahjong_scoreboard\model\business.py", line 153, in
class Game(BaseModel):
File "C:\Users\Administrator\Desktop\YPBot\YPBot\plugins\nonebot_plugin_mahjong_scoreboard\model\business.py", line 161, in Game
records: conlist(GameRecord, max_items=4)
TypeError: conlist() got an unexpected keyword argument 'max_items'

@ssttkkl
Copy link
Collaborator

ssttkkl commented Oct 26, 2024

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants