feat: notice in node list

update DB
This commit is contained in:
dr.lt.data
2023-12-13 09:55:55 +09:00
parent 3d39819527
commit 28c7ef95b8
8 changed files with 150 additions and 93 deletions

View File

@@ -20,8 +20,9 @@ import nodes
import torch
version = "V1.12.1"
print(f"### Loading: ComfyUI-Manager ({version})")
version = [1, 13]
version_str = f"V{version[0]}.{version[1]}" + ('.' + version[2] if len(version) > 2 else '')
print(f"### Loading: ComfyUI-Manager ({version_str})")
required_comfyui_revision = 1793
@@ -783,6 +784,21 @@ async def fetch_customnode_list(request):
json_obj = await get_data_by_mode(request.rel_url.query["mode"], 'custom-node-list.json')
def is_ignored_notice(code):
global version
if code is not None and code.startswith('#NOTICE_'):
try:
notice_version = [int(x) for x in code[8:].split('.')]
return notice_version[0] < version[0] or (notice_version[0] == version[0] and notice_version[1] <= version[1])
except Exception:
return False
else:
False
json_obj['custom_nodes'] = [record for record in json_obj['custom_nodes'] if not is_ignored_notice(record.get('author'))]
check_custom_nodes_installed(json_obj, False, not skip_update)
for x in json_obj['custom_nodes']: