mirror of
https://git.datalinker.icu/ltdrdata/ComfyUI-Manager
synced 2025-12-14 00:24:23 +08:00
fixed: crash on desktop version when displaying to print version information
This commit is contained in:
parent
eb41867e04
commit
04fa540a8c
@ -43,7 +43,7 @@ import manager_downloader
|
|||||||
from node_package import InstalledNodePackage
|
from node_package import InstalledNodePackage
|
||||||
|
|
||||||
|
|
||||||
version_code = [3, 30, 2]
|
version_code = [3, 30, 3]
|
||||||
version_str = f"V{version_code[0]}.{version_code[1]}" + (f'.{version_code[2]}' if len(version_code) > 2 else '')
|
version_str = f"V{version_code[0]}.{version_code[1]}" + (f'.{version_code[2]}' if len(version_code) > 2 else '')
|
||||||
|
|
||||||
|
|
||||||
@ -75,8 +75,8 @@ def get_custom_nodes_paths():
|
|||||||
|
|
||||||
|
|
||||||
def get_comfyui_tag():
|
def get_comfyui_tag():
|
||||||
repo = git.Repo(comfy_path)
|
|
||||||
try:
|
try:
|
||||||
|
repo = git.Repo(comfy_path)
|
||||||
return repo.git.describe('--tags')
|
return repo.git.describe('--tags')
|
||||||
except:
|
except:
|
||||||
return None
|
return None
|
||||||
|
|||||||
@ -1545,12 +1545,12 @@ async def get_notice(request):
|
|||||||
|
|
||||||
if match:
|
if match:
|
||||||
markdown_content = match.group(1)
|
markdown_content = match.group(1)
|
||||||
version_tag = core.get_comfyui_tag()
|
|
||||||
if version_tag is None:
|
|
||||||
version_tag = os.environ.get('__COMFYUI_DESKTOP_VERSION__')
|
version_tag = os.environ.get('__COMFYUI_DESKTOP_VERSION__')
|
||||||
if version_tag is not None:
|
if version_tag is not None:
|
||||||
markdown_content += f"<HR>ComfyUI: {version_tag} [Desktop]"
|
markdown_content += f"<HR>ComfyUI: {version_tag} [Desktop]"
|
||||||
else:
|
else:
|
||||||
|
version_tag = core.get_comfyui_tag()
|
||||||
|
if version_tag is None:
|
||||||
markdown_content += f"<HR>ComfyUI: {core.comfy_ui_revision}[{comfy_ui_hash[:6]}]({core.comfy_ui_commit_datetime.date()})"
|
markdown_content += f"<HR>ComfyUI: {core.comfy_ui_revision}[{comfy_ui_hash[:6]}]({core.comfy_ui_commit_datetime.date()})"
|
||||||
else:
|
else:
|
||||||
markdown_content += (f"<HR>ComfyUI: {version_tag}<BR>"
|
markdown_content += (f"<HR>ComfyUI: {version_tag}<BR>"
|
||||||
@ -1561,6 +1561,7 @@ async def get_notice(request):
|
|||||||
markdown_content = add_target_blank(markdown_content)
|
markdown_content = add_target_blank(markdown_content)
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
if '__COMFYUI_DESKTOP_VERSION__' not in os.environ:
|
||||||
if core.comfy_ui_commit_datetime == datetime(1900, 1, 1, 0, 0, 0):
|
if core.comfy_ui_commit_datetime == datetime(1900, 1, 1, 0, 0, 0):
|
||||||
markdown_content = '<P style="text-align: center; color:red; background-color:white; font-weight:bold">Your ComfyUI isn\'t git repo.</P>' + markdown_content
|
markdown_content = '<P style="text-align: center; color:red; background-color:white; font-weight:bold">Your ComfyUI isn\'t git repo.</P>' + markdown_content
|
||||||
elif core.comfy_ui_required_commit_datetime.date() > core.comfy_ui_commit_datetime.date():
|
elif core.comfy_ui_required_commit_datetime.date() > core.comfy_ui_commit_datetime.date():
|
||||||
|
|||||||
@ -1,7 +1,7 @@
|
|||||||
[project]
|
[project]
|
||||||
name = "comfyui-manager"
|
name = "comfyui-manager"
|
||||||
description = "ComfyUI-Manager provides features to install and manage custom nodes for ComfyUI, as well as various functionalities to assist with ComfyUI."
|
description = "ComfyUI-Manager provides features to install and manage custom nodes for ComfyUI, as well as various functionalities to assist with ComfyUI."
|
||||||
version = "3.30.2"
|
version = "3.30.3"
|
||||||
license = { file = "LICENSE.txt" }
|
license = { file = "LICENSE.txt" }
|
||||||
dependencies = ["GitPython", "PyGithub", "matrix-client==0.4.0", "transformers", "huggingface-hub>0.20", "typer", "rich", "typing-extensions", "toml", "uv", "chardet"]
|
dependencies = ["GitPython", "PyGithub", "matrix-client==0.4.0", "transformers", "huggingface-hub>0.20", "typer", "rich", "typing-extensions", "toml", "uv", "chardet"]
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user