MeetWq / meme-generator

表情包生成器,用于制作各种沙雕表情包
MIT License
508 stars 72 forks source link

pip安装 报错 ‘dataclass() got an unexpected keyword argument 'match_args'’ #135

Open lowendplayer opened 2 months ago

lowendplayer commented 2 months ago

系统 Windows Server 2022 python 3.12.5 报错: PS C:\meme> meme download Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "C:\Python\Python312\Scripts\meme.exe__main.py", line 4, in File "C:\Python\Python312\Lib\site-packages\meme_generator__init__.py", line 4, in from meme_generator.manager import add_meme as add_meme File "C:\Python\Python312\Lib\site-packages\meme_generator\manager.py", line 11, in from .meme import CommandShortcut, Meme, MemeArgsType, MemeFunction, MemeParamsType File "C:\Python\Python312\Lib\site-packages\meme_generator\meme.py", line 50, in class ParserOption(BaseModel): File "C:\Python\Python312\Lib\site-packages\pydantic\main.py", line 205, in new fields[ann_name] = ModelField.infer( ^^^^^^^^^^^^^^^^^ File "C:\Python\Python312\Lib\site-packages\pydantic\fields.py", line 491, in infer return cls( ^^^^ File "C:\Python\Python312\Lib\site-packages\pydantic\fields.py", line 421, in init self.prepare() File "C:\Python\Python312\Lib\site-packages\pydantic\fields.py", line 542, in prepare self.populate_validators() File "C:\Python\Python312\Lib\site-packages\pydantic\fields.py", line 804, in populate_validators *(get_validators() if get_validators else list(findvalidators(self.type, self.model_config))), ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Python\Python312\Lib\site-packages\pydantic\validators.py", line 683, in find_validators yield from make_dataclassvalidator(type, config) File "C:\Python\Python312\Lib\site-packages\pydantic\dataclasses.py", line 276, in make_dataclass_validator cls = dataclass(_cls, config=config, **stdlib_dataclass_parameters) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ TypeError: dataclass() got an unexpected keyword argument 'match_args' PS C:\meme> meme -h Traceback (most recent call last): File "", line 198, in _run_module_as_main File "", line 88, in _run_code File "C:\Python\Python312\Scripts\meme.exe__main__.py", line 4, in File "C:\Python\Python312\Lib\site-packages\meme_generator__init__.py", line 4, in from meme_generator.manager import add_meme as add_meme File "C:\Python\Python312\Lib\site-packages\meme_generator\manager.py", line 11, in from .meme import CommandShortcut, Meme, MemeArgsType, MemeFunction, MemeParamsType File "C:\Python\Python312\Lib\site-packages\meme_generator\meme.py", line 50, in class ParserOption(BaseModel): File "C:\Python\Python312\Lib\site-packages\pydantic\main.py", line 205, in new__ fields[ann_name] = ModelField.infer( ^^^^^^^^^^^^^^^^^ File "C:\Python\Python312\Lib\site-packages\pydantic\fields.py", line 491, in infer return cls( ^^^^ File "C:\Python\Python312\Lib\site-packages\pydantic\fields.py", line 421, in init self.prepare() File "C:\Python\Python312\Lib\site-packages\pydantic\fields.py", line 542, in prepare self.populate_validators() File "C:\Python\Python312\Lib\site-packages\pydantic\fields.py", line 804, in populate_validators *(get_validators() if get_validators else list(findvalidators(self.type, self.model_config))), ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Python\Python312\Lib\site-packages\pydantic\validators.py", line 683, in find_validators yield from make_dataclassvalidator(type, config) File "C:\Python\Python312\Lib\site-packages\pydantic\dataclasses.py", line 276, in make_dataclass_validator cls = dataclass(_cls, config=config, **stdlib_dataclass_parameters) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ TypeError: dataclass() got an unexpected keyword argument 'match_args'