Repository navigation
fix: reject image results after Metal backend failures - #21
Merged
Merged
Conversation
leehack
marked this pull request as ready for review
October 18, 2026 14:45
This was referenced Oct 18, 2026
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.
A failed Metal command buffer can leave upstream generate_image returning a corrupt image as success. The guarded sd_dart_generate_image export now detects the pinned Metal failure/error-state diagnostics (including INFO level), frees returned batches, clears outputs, and rejects tracked-context reuse until disposal/reload. No upstream source or ABI/export change. Synthetic failure logging occurs outside the context registry lock so recorder waits do not hold up cancellation/disposal.
Validation:
1bb395f7540cc35570c307a30f354f267de43a6d.Closes #19. Kept separate from upstream update/FP8 work in #20. Source only: artifact release, Apple companion checksum/pin adoption and downstream qualification require separate approval. Publication and consumer changes remain separate from this source merge.
High-risk QA
Post-merge verification: merged as
ea609150a6a55746a2b98ddc7955b60e07867cce; merged tree exactly matches the tested source head. Automatic main CI passed all 17 checks. Publication and downstream artifact/checksum/pin adoption remain separate.