From bf832e4cde775b5d350070d2a4fb76b08826c8eb Mon Sep 17 00:00:00 2001 From: Sirshendu Ganguly Date: Fri, 3 Apr 2026 13:57:24 +0530 Subject: [PATCH] Removed unwaneted funcs --- modules/imageInferenceSettingsColorPalette.py | 11 ++--------- modules/upscaler.py | 2 +- 2 files changed, 3 insertions(+), 10 deletions(-) diff --git a/modules/imageInferenceSettingsColorPalette.py b/modules/imageInferenceSettingsColorPalette.py index 927fc58..753c3ef 100644 --- a/modules/imageInferenceSettingsColorPalette.py +++ b/modules/imageInferenceSettingsColorPalette.py @@ -6,13 +6,6 @@ Builds settings.colorPalette: list of { "hex": "#...", "ratio": "NN.NN%" } for R from typing import Any, Dict, List, Tuple -def _normalize_hex(raw: str) -> str: - h = raw.strip() - if not h: - return "" - return h if h.startswith("#") else f"#{h}" - - class RunwareImageInferenceSettingsColorPalette: """Up to 8 hex/ratio pairs; each slot is included only when use_{i} is enabled.""" @@ -52,8 +45,8 @@ class RunwareImageInferenceSettingsColorPalette: for i in range(1, self._SLOTS + 1): if not kwargs.get(f"use_{i}", False): continue - hx = _normalize_hex(str(kwargs.get(f"hex_{i}") or "")) - if not hx or hx == "#": + hx = str(kwargs.get(f"hex_{i}") or "").strip() + if not hx: raise ValueError( f"use_{i} is enabled but hex_{i} is empty or invalid. " "Provide a hex color (e.g. #C2D1E6) or disable this swatch." diff --git a/modules/upscaler.py b/modules/upscaler.py index c288b5d..ca23b47 100644 --- a/modules/upscaler.py +++ b/modules/upscaler.py @@ -133,7 +133,7 @@ class upscaler: "max": 2, }), "safetyInputs": ("RUNWARESAFETYINPUTS", { - "tooltip": "Deprecated compatibility socket. Accepted for old workflows but ignored by this node.", + "tooltip": "Connect Runware Safety Inputs node to include safety settings in the upscale request.", }), "Accelerator": ("RUNWAREACCELERATOR", { "tooltip": "Connect a Runware Accelerator Options Node to configure caching and acceleration settings.",