stable-diffusion-webui-forge icon indicating copy to clipboard operation
stable-diffusion-webui-forge copied to clipboard

controlnet extension - few compat fixes

Open light-and-ray opened this issue 1 year ago • 4 comments
trafficstars

In support forge in my extension I've faced external_code no longer has to_processing_unit. And also it produces errors if few units are None

Checklist:

light-and-ray avatar Mar 03 '24 12:03 light-and-ray

@huchenlei this commit: https://github.com/light-and-ray/sd-webui-replacer/commit/27b965caad626cf945c9adfe4f72c2d5e316e69a

~~For any reason sd-webui works fine with dict and convert it "on fly", when forge required to replace all dicts to units right in p.script_args~~. And second difference between forge and webui: yes, if in p.script_args I've provided only 1 unit, forge didn't work due to NoneType and assert with type checking

light-and-ray avatar Mar 04 '24 07:03 light-and-ray

I'm looking the code, and I think I've misunderstood and forge doesn't require replace dicts in p.script_args, and it was the same error about NoneType. So the part with to_processing_unit can be removed if you want. But I think it's better to keep it for backward compatibility. But None should be fixed in any way I think, because the webui works with them

light-and-ray avatar Mar 04 '24 07:03 light-and-ray

But I think it's better to keep it for backward compatibility.

Btw I still need to check is unit enabled, and maybe other fields in future, and I need to have this function. I can write my analog in my code, but why when it's better to have universal conversion function inside external_code module

Before this I had faced only with different lib path and mask which doesn't require special handling. It doesn't a big deal for extension like mine which just uses cn script and nothing else. But why external_code module shouldn't has the same interface with webui by your opinion, when this module was designed like a lib for usage by external extensions? 😐

I don't think the changes here are well justified.

light-and-ray avatar Mar 04 '24 08:03 light-and-ray

@huchenlei

light-and-ray avatar Mar 08 '24 15:03 light-and-ray

hi we are going to close PRs before forge's recent major revision if we missed some important PRs, please consider reopen (if that is not already on our todo list

lllyasviel avatar Aug 01 '24 19:08 lllyasviel