DB-GPT
DB-GPT copied to clipboard
[Bug]vllm error,ValueError: mutable default <class 'list'> for field ignore_patterns is not allowed: use default_factory
Search before asking
- [X] I had searched in the issues and found no similar issues.
Operating system information
Linux
Python version information
=3.11
DB-GPT version
main
Related scenes
- [ ] Chat Data
- [ ] Chat Excel
- [ ] Chat DB
- [ ] Chat Knowledge
- [ ] Model Management
- [ ] Dashboard
- [ ] Plugins
Installation Information
-
[ ] AutoDL Image
-
[ ] Other
Device information
使用vllm报错,ValueError: mutable default <class 'list'> for field ignore_patterns is not allowed: use default_factory
Models information
使用vllm报错,ValueError: mutable default <class 'list'> for field ignore_patterns is not allowed: use default_factory
What happened
发生异常: ValueError
mutable default <class 'list'> for field ignore_patterns is not allowed: use default_factory
File "/root/xh-project/DB-GPT/dbgpt/util/parameter_utils.py", line 552, in _build_parameter_class
result_class = dataclass(new_class) # type: ignore
^^^^^^^^^^^^^^^^^^^^
File "/root/xh-project/DB-GPT/dbgpt/model/adapter/vllm_adapter.py", line 58, in model_param_class
return _build_parameter_class(descs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/root/xh-project/DB-GPT/dbgpt/model/cluster/worker/default_worker.py", line 56, in load_worker
self.param_cls = self.llm_adapter.model_param_class(model_type)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/root/xh-project/DB-GPT/dbgpt/model/cluster/worker/manager.py", line 163, in add_worker
worker.load_worker(**asdict(worker_params))
File "/root/xh-project/DB-GPT/dbgpt/model/cluster/worker/manager.py", line 1005, in _start_local_worker
worker_manager.worker_manager.add_worker(worker, worker_params)
File "/root/xh-project/DB-GPT/dbgpt/model/cluster/worker/manager.py", line 1074, in initialize_worker_manager_in_client
_start_local_worker(worker_manager, worker_params)
File "/root/xh-project/DB-GPT/dbgpt/app/dbgpt_server.py", line 184, in initialize_app
initialize_worker_manager_in_client(
File "/root/xh-project/DB-GPT/dbgpt/app/dbgpt_server.py", line 259, in run_webserver
param = initialize_app(param)
^^^^^^^^^^^^^^^^^^^^^
File "/root/xh-project/DB-GPT/dbgpt/app/dbgpt_server.py", line 264, in
What you expected to happen
使用vllm报错,ValueError: mutable default <class 'list'> for field ignore_patterns is not allowed: use default_factory
How to reproduce
使用vllm报错,ValueError: mutable default <class 'list'> for field ignore_patterns is not allowed: use default_factory
Additional context
使用vllm报错,ValueError: mutable default <class 'list'> for field ignore_patterns is not allowed: use default_factory
Are you willing to submit PR?
- [ ] Yes I am willing to submit a PR!
同样的错误 怎么解决呢
+1
/assign @fangyinc
同问,现在解决了吗?
同样的错 按照这个方式改了一下代码解决了https://blog.csdn.net/m0_55387836/article/details/141569256