mirror of
https://github.com/comfyanonymous/ComfyUI.git
synced 2025-09-14 13:35:05 +00:00
Attempting to simplify node list definition in a python file via NODES_LIST
This commit is contained in:
@@ -46,15 +46,15 @@ class V3TestNode(ComfyNodeV3):
|
||||
|
||||
|
||||
|
||||
NODES: list[ComfyNodeV3] = [
|
||||
NODES_LIST: list[ComfyNodeV3] = [
|
||||
V3TestNode,
|
||||
]
|
||||
|
||||
|
||||
NODE_CLASS_MAPPINGS = {}
|
||||
NODE_DISPLAY_NAME_MAPPINGS = {}
|
||||
for node in NODES:
|
||||
schema = node.GET_SCHEMA()
|
||||
NODE_CLASS_MAPPINGS[schema.node_id] = node
|
||||
if schema.display_name:
|
||||
NODE_DISPLAY_NAME_MAPPINGS[schema.node_id] = schema.display_name
|
||||
# NODE_CLASS_MAPPINGS = {}
|
||||
# NODE_DISPLAY_NAME_MAPPINGS = {}
|
||||
# for node in NODES_LIST:
|
||||
# schema = node.GET_SCHEMA()
|
||||
# NODE_CLASS_MAPPINGS[schema.node_id] = node
|
||||
# if schema.display_name:
|
||||
# NODE_DISPLAY_NAME_MAPPINGS[schema.node_id] = schema.display_name
|
||||
|
Reference in New Issue
Block a user