Skip to content

[backport core/1.34] fix: loading api-format workflow that contains "parameters" string#7516

Merged
christian-byrne merged 1 commit intocore/1.34from
backport-7411-to-core-1.34
Dec 15, 2025
Merged

[backport core/1.34] fix: loading api-format workflow that contains "parameters" string#7516
christian-byrne merged 1 commit intocore/1.34from
backport-7411-to-core-1.34

Conversation

@comfy-pr-bot
Copy link
Member

@comfy-pr-bot comfy-pr-bot commented Dec 15, 2025

Backport of #7411 to core/1.34

Automatically created by backport workflow.

┆Issue is synchronized with this Notion page by Unito

…7411)

## Summary

This change extends
#7154 by making sure
the `prompt` metadata tag is parsed before the legacy A1111 fallback
when files are dropped onto the canvas.

ComfyUI embeds two structured payloads into every first-class export
format we support (PNG, WEBP, WEBM, MP4/MOV/M4V, GLB, SVG, MP3,
OGG/FLAC, etc.): `workflow`, which is the full editor JSON with layout
state, and `prompt`, which is the API graph sent to `/prompt`.

During import we try format-specific decoders first and only as a last
resort look for an A1111 file by scanning text chunks for a `parameters`
entry. That compatibility path was always meant to be a best-effort
option, but when we refactored the loader it accidentally enforced the
order `workflow → parameters → prompt`. As soon as a dropped asset
contained a `parameters` chunk—something Image Saver’s “A1111
compatibility” mode always adds—the A1111 converter activated and
blocked the subsequent `prompt` loading logic.

PR #7154 already lifted `workflow` ahead of the fallback, yet any file
lacking the `workflow` chunk but holding both `prompt` and `parameters`
still regressed. Reordering to `workflow → prompt → parameters`
preserves the compatibility shim for genuine A1111 exports while
guaranteeing native Comfy metadata always wins, eliminating the entire
class of failures triggered merely by the presence of the word
`parameters` in an unrelated metadata chunk.

Fixes #7096, fixes
#6988

## Related 

(fixed by #7154)

- #6633
- #6561

---------

Co-authored-by: github-actions <github-actions@github.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
@comfy-pr-bot comfy-pr-bot added the backport Backporting a PR onto a release candidate label Dec 15, 2025
@comfy-pr-bot comfy-pr-bot requested a review from a team as a code owner December 15, 2025 19:48
@dosubot dosubot bot added the size:M This PR changes 30-99 lines, ignoring generated files. label Dec 15, 2025
@github-actions
Copy link

github-actions bot commented Dec 15, 2025

🎨 Storybook Build Status

Build completed successfully!

⏰ Completed at: 12/15/2025, 07:49:58 PM UTC

🔗 Links


🎉 Your Storybook is ready for review!

@github-actions
Copy link

github-actions bot commented Dec 15, 2025

🎭 Playwright Test Results

⚠️ Tests passed with flaky tests

⏰ Completed at: 12/15/2025, 08:42:39 PM UTC

📈 Summary

  • Total Tests: 490
  • Passed: 470 ✅
  • Failed: 0
  • Flaky: 10 ⚠️
  • Skipped: 10 ⏭️

📊 Test Reports by Browser

  • chromium: View Report • ✅ 461 / ❌ 0 / ⚠️ 10 / ⏭️ 10
  • chromium-2x: View Report • ✅ 2 / ❌ 0 / ⚠️ 0 / ⏭️ 0
  • chromium-0.5x: View Report • ✅ 1 / ❌ 0 / ⚠️ 0 / ⏭️ 0
  • mobile-chrome: View Report • ✅ 6 / ❌ 0 / ⚠️ 0 / ⏭️ 0

🎉 Click on the links above to view detailed test results for each browser configuration.

@christian-byrne christian-byrne merged commit 9516100 into core/1.34 Dec 15, 2025
33 checks passed
@christian-byrne christian-byrne deleted the backport-7411-to-core-1.34 branch December 15, 2025 21:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport Backporting a PR onto a release candidate size:M This PR changes 30-99 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants