mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
clean up python errors
This commit is contained in:
parent
ee77abb4fe
commit
90340a39c7
@ -29,7 +29,6 @@ from invokeai.backend.model_manager.config import (
|
|||||||
ModelType,
|
ModelType,
|
||||||
SubModelType,
|
SubModelType,
|
||||||
)
|
)
|
||||||
from invokeai.backend.model_manager.metadata.metadata_base import RemoteModelFile
|
|
||||||
from invokeai.backend.model_manager.search import ModelSearch
|
from invokeai.backend.model_manager.search import ModelSearch
|
||||||
|
|
||||||
from ..dependencies import ApiDependencies
|
from ..dependencies import ApiDependencies
|
||||||
|
@ -20,7 +20,6 @@ from invokeai.app.services.model_records import ModelRecordServiceBase
|
|||||||
from invokeai.backend.model_manager import AnyModelConfig, ModelRepoVariant
|
from invokeai.backend.model_manager import AnyModelConfig, ModelRepoVariant
|
||||||
from invokeai.backend.model_manager.config import ModelSourceType
|
from invokeai.backend.model_manager.config import ModelSourceType
|
||||||
from invokeai.backend.model_manager.metadata import AnyModelRepoMetadata
|
from invokeai.backend.model_manager.metadata import AnyModelRepoMetadata
|
||||||
from invokeai.backend.model_manager.metadata.metadata_base import RemoteModelFile
|
|
||||||
|
|
||||||
|
|
||||||
class InstallStatus(str, Enum):
|
class InstallStatus(str, Enum):
|
||||||
|
@ -38,7 +38,7 @@ from invokeai.backend.model_manager.metadata import (
|
|||||||
ModelMetadataWithFiles,
|
ModelMetadataWithFiles,
|
||||||
RemoteModelFile,
|
RemoteModelFile,
|
||||||
)
|
)
|
||||||
from invokeai.backend.model_manager.metadata.metadata_base import HuggingFaceMetadata
|
from invokeai.backend.model_manager.metadata.metadata_base import HuggingFaceMetadata, UnknownMetadataException
|
||||||
from invokeai.backend.model_manager.probe import ModelProbe
|
from invokeai.backend.model_manager.probe import ModelProbe
|
||||||
from invokeai.backend.model_manager.search import ModelSearch
|
from invokeai.backend.model_manager.search import ModelSearch
|
||||||
from invokeai.backend.util import Chdir, InvokeAILogger
|
from invokeai.backend.util import Chdir, InvokeAILogger
|
||||||
@ -241,7 +241,7 @@ class ModelInstallService(ModelInstallServiceBase):
|
|||||||
|
|
||||||
try:
|
try:
|
||||||
metadata = HuggingFaceMetadataFetch(self._session).from_id(source)
|
metadata = HuggingFaceMetadataFetch(self._session).from_id(source)
|
||||||
except:
|
except UnknownMetadataException:
|
||||||
raise ValueError("No HuggingFace repository found")
|
raise ValueError("No HuggingFace repository found")
|
||||||
|
|
||||||
assert isinstance(metadata, ModelMetadataWithFiles)
|
assert isinstance(metadata, ModelMetadataWithFiles)
|
||||||
|
Loading…
Reference in New Issue
Block a user