mirror of
https://github.com/willmiao/ComfyUI-Lora-Manager.git
synced 2026-03-26 15:38:52 -03:00
refactor(nodes): standardize node class names with LM suffix
Rename all node classes to use consistent 'LM' suffix pattern: - LoraCyclerNode → LoraCyclerLM - LoraManagerLoader → LoraLoaderLM - LoraManagerTextLoader → LoraTextLoaderLM - LoraStacker → LoraStackerLM - LoraRandomizerNode → LoraRandomizerLM - LoraPoolNode → LoraPoolLM - WanVideoLoraSelectFromText → WanVideoLoraTextSelectLM - DebugMetadata → DebugMetadataLM - TriggerWordToggle → TriggerWordToggleLM - PromptLoraManager → PromptLM Updated: - Core node class definitions (9 files) - NODE_CLASS_MAPPINGS in __init__.py - Node type mappings in node_extractors.py - All related test imports and references - Logger prefixes for consistency Frontend extension names remain unchanged (LoraManager.LoraStacker, etc.)
This commit is contained in:
@@ -129,22 +129,22 @@ def test_metadata_registry_caches_and_rehydrates(populated_registry):
|
||||
def test_lora_manager_cache_updates_when_loras_removed(metadata_registry):
|
||||
import nodes
|
||||
|
||||
class LoraManagerLoader: # type: ignore[too-many-ancestors]
|
||||
__name__ = "LoraManagerLoader"
|
||||
class LoraLoaderLM: # type: ignore[too-many-ancestors]
|
||||
__name__ = "LoraLoaderLM"
|
||||
|
||||
nodes.NODE_CLASS_MAPPINGS["LoraManagerLoader"] = LoraManagerLoader
|
||||
nodes.NODE_CLASS_MAPPINGS["LoraLoaderLM"] = LoraLoaderLM
|
||||
|
||||
prompt_graph = {
|
||||
"lora_node": {"class_type": "LoraManagerLoader", "inputs": {}},
|
||||
"lora_node": {"class_type": "LoraLoaderLM", "inputs": {}},
|
||||
}
|
||||
prompt = SimpleNamespace(original_prompt=prompt_graph)
|
||||
cache_key = "lora_node:LoraManagerLoader"
|
||||
cache_key = "lora_node:LoraLoaderLM"
|
||||
|
||||
metadata_registry.start_collection("prompt1")
|
||||
metadata_registry.set_current_prompt(prompt)
|
||||
metadata_registry.record_node_execution(
|
||||
"lora_node",
|
||||
"LoraManagerLoader",
|
||||
"LoraLoaderLM",
|
||||
{"loras": [[{"name": "foo", "strength": 0.8, "active": True}]]},
|
||||
None,
|
||||
)
|
||||
@@ -152,7 +152,7 @@ def test_lora_manager_cache_updates_when_loras_removed(metadata_registry):
|
||||
|
||||
metadata_registry.start_collection("prompt2")
|
||||
metadata_registry.set_current_prompt(prompt)
|
||||
metadata_registry.record_node_execution("lora_node", "LoraManagerLoader", {"loras": [[]]}, None)
|
||||
metadata_registry.record_node_execution("lora_node", "LoraLoaderLM", {"loras": [[]]}, None)
|
||||
|
||||
assert cache_key not in metadata_registry.node_cache
|
||||
|
||||
|
||||
Reference in New Issue
Block a user