mirror of
https://github.com/invoke-ai/InvokeAI.git
synced 2026-04-23 03:00:31 -04:00
fix(mm): pop base/type/format when creating unknown model config
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
from copy import deepcopy
|
||||
from typing import Any, Literal, Self
|
||||
|
||||
from pydantic import Field
|
||||
@@ -32,6 +33,11 @@ class Unknown_Config(Config_Base):
|
||||
if not app_config.allow_unknown_models:
|
||||
raise NotAMatchError("unknown models are not allowed by configuration")
|
||||
|
||||
cloned_override_fields = deepcopy(override_fields)
|
||||
cloned_override_fields.pop("base", None)
|
||||
cloned_override_fields.pop("type", None)
|
||||
cloned_override_fields.pop("format", None)
|
||||
|
||||
return cls(
|
||||
**override_fields,
|
||||
# Override the type/format/base to ensure it's marked as unknown.
|
||||
|
||||
Reference in New Issue
Block a user