Comfy-Org / Comfy-Org/ComfyUI

ControlNetLoader exports invalid legacy model names in API workflow

Open
#15,806 0 comments 0 reactions 0 assignees View on GitHub
Potential Bug
Dominant language
Python
Stars
133k
Forks
15.7k
Avg merge
1d 6h
Merged PRs (30d)
155

Description

### Custom Node Testing

- [x] I have tried disabling custom nodes and the issue persists (see [how to disable custom nodes](https://docs.comfy.org/troubleshooting/custom-node-issues#step-1%3A-test-with-all-custom-nodes-disabled) if you need help)

### Expected Behavior

Selecting a ControlNet model from the Load ControlNet Model dropdown should export the selected model identifier in Workflow API JSON.

Example:
xinsir/controlnet-openpose-sdxl-1.0 - diffusion_pytorch_model

The exported API workflow should contain a valid control_net_name accepted by the node.

### Actual Behavior

The UI dropdown shows the correct Xinsir ControlNet models:

xinsir/controlnet-openpose-sdxl-1.0 - diffusion_pytorch_model
xinsir/controlnet-canny-sdxl-1.0 - diffusion_pytorch_model

However, Export Workflow API generates legacy filenames:

controlnet-openpose-sdxl-1.0.safetensors
controlnet-canny-sdxl-1.0.safetensors

These values are not present in the current model registry, causing validation failure when running the workflow.

### Steps to Reproduce

1. Add Load ControlNet Model node.
2. Select:
xinsir/controlnet-openpose-sdxl-1.0 - diffusion_pytorch_model
3. Export Workflow API.
4. Observe generated JSON:
"control_net_name": "controlnet-openpose-sdxl-1.0.safetensors"
5. Run workflow.
6. Validation fails:
control_net_name is not a valid value

### Debug Logs

```powershell
Using Comfy Cloud, no local terminal logs are available.

"""
2
Invalid input

Some input values are not available for this node.
Load ControlNet Model - control_net_name

The value controlnet-canny-sdxl-1.0.safetensors for Load ControlNet Model's control_net_name is not available.
Load ControlNet Model - control_net_name

The value controlnet-tile-sdxl-1.0.safetensors for Load ControlNet Model's control_net_name is not available.
"""
```

### Other

This issue happens with a fresh Load ControlNet Model node, not only with imported workflows.

Prompt outputs failed validation

ControlNetLoader:
control_net_name:
'controlnet-openpose-sdxl-1.0.safetensors'
is not a valid value

Image

Contributor guide

Open the contributing guide

Research direction

Reproduce the problem with a fresh Load ControlNet Model node using the listed Xinsir model, then inspect the ControlNetLoader value in the exported Workflow API JSON. Compare the exported control_net_name with the model identifier shown in the dropdown and the current model registry. Done means the API workflow contains an accepted identifier and passes validation.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
api, backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
68/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.