Updating ComfyUI should not break API functionality when updated code adds new inputs with defaults
- Dominant language
- Python
- Stars
- 133k
- Forks
- 15.7k
- Avg merge
- 1d 7h
- Merged PRs (30d)
- 158
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
After updating ComfyUI, It shouldn't break production code that is using ComfyUI as an API, as a result of adding a new input with a default value.
I expect that previous workflows to generally still work with the api. I shouldn't have to redistribute applications and have previous builds be broken. And that missing inputs that have a default argument in their schema would be automatically filled with that value. In general, one should now have to update api workflows that just add a default input at the end of the input list.
### Actual Behavior
After recently updating, `resolution_steps` with a default value was added to `ImageScaleToTotalPixels` at the end of it's inputs. Nice that it is at the end for users of the UI, it would just work. But because this value is missing, previous deployed workflows quit working because validation fails.
### Steps to Reproduce
Have a previous api workflow using the ImageScaleToTotalPixels without the `resolution_steps` or delete it. Try running the workflow via API and see that it fails to validate the workflow with the below logs.
### Debug Logs
```powershell
Failed to validate prompt for output 410:
* ImageScaleToTotalPixels 93:
- Required input is missing: resolution_steps
```
### Other
_No response_
Contributor guide
Assessment
This issue has not been assessed yet.