Fix: Add ComfyUI API compatibility shims for Blend and SDXL encoders#166
Open
Alaric07 wants to merge 1 commit intoSeargeDP:mainfrom
Open
Fix: Add ComfyUI API compatibility shims for Blend and SDXL encoders#166Alaric07 wants to merge 1 commit intoSeargeDP:mainfrom
Alaric07 wants to merge 1 commit intoSeargeDP:mainfrom
Conversation
Author
|
Hi everyone, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This update adds compatibility patches for the latest ComfyUI API changes that caused breakage in the SeargeSDXL workflow.
Summary
ComfyUI recently refactored internal APIs for both post-processing nodes and SDXL text encoders, which led to the following runtime errors:
'Blend' object has no attribute 'blend_images'
'SeargeStageClipConditioning' object has no attribute 'encode_base'
index 1 is out of bounds for dimension 0 with size 1
This patch introduces lightweight shims to restore functionality while remaining backward-compatible.
Changes
Added a Blend compatibility shim to dynamically attach a blend_images() method when missing.
Falls back gracefully to blend(), execute(), or a manual torch-based blend.
Added SDXL encoder compatibility shims for encode_base() and encode_ref() ensuring proper operation with the new ComfyUI text-encoder API (mid-2025+).
Preserved legacy tuple [0] returns to maintain workflow compatibility with older node logic.
Tested Environment
OS: Fedora Linux 43 (Wayland)
Desktop: KDE Plasma 6.5.1 / Frameworks 6.19.0 / Qt 6.10.0
Kernel: 6.17.7-300.fc43.x86_64
CPU: Intel® Core™ Ultra 7-265KF (20 threads)
GPU: NVIDIA GeForce RTX 4090 (ASUS)
RAM: 64 GiB
Verification
Tested successfully with:
ComfyUI master (Nov 2025 build)
JuggernautXL SDXL model (with baked-in VAE)
SeargeSDXL full workflow, including refiner and upscale paths
Notes
This patch is backward-compatible and intended as a temporary fix until upstream adjustments are merged into SeargeSDXL.
Acknowledgment
Submitted by Eric Weiss (Alaric07) — tested on Fedora 43 Workstation.