diff --git a/__init__.py b/__init__.py index 1467ba4..bfed725 100644 --- a/__init__.py +++ b/__init__.py @@ -30,7 +30,7 @@ except: print(f"[WARN] ComfyUI-Manager: Your ComfyUI version is outdated. Please update to the latest version.") -version = [2, 13] +version = [2, 13, 1] version_str = f"V{version[0]}.{version[1]}" + (f'.{version[2]}' if len(version) > 2 else '') print(f"### Loading: ComfyUI-Manager ({version_str})") diff --git a/prestartup_script.py b/prestartup_script.py index cd32358..b3fba3f 100644 --- a/prestartup_script.py +++ b/prestartup_script.py @@ -7,9 +7,15 @@ import threading import re import locale import platform -from distutils.version import StrictVersion +try: + from distutils.version import StrictVersion +except: + print(f"[ComfyUI-Manager] Missing `distutils`. Try install...") + subprocess.check_output([sys.executable, '-m', 'pip', 'install', 'distutils']) + from distutils.version import StrictVersion + glob_path = os.path.join(os.path.dirname(__file__), "glob") sys.path.append(glob_path) diff --git a/requirements.txt b/requirements.txt index 08c31a6..70a430f 100644 --- a/requirements.txt +++ b/requirements.txt @@ -2,5 +2,4 @@ GitPython PyGithub matrix-client==0.4.0 transformers -huggingface-hub>0.20 -distutils \ No newline at end of file +huggingface-hub>0.20 \ No newline at end of file