Feature set 126. - #53
Merged
Merged
Conversation
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
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.
Saves generated image URLs as the batch runs instead of once at the end.
GenerateAsynccollected every result in memory and wrote them all in a singleSaveChangesAsyncafter the last image. A 400-image run on 2026-08-03 took close to therunner''s six-hour
timeout-minutesceiling, and anything killed at that ceiling loses theGeneratedImageUrlfor every image it had already generated, paid for and uploaded.No money was ever at risk — object keys derive from the row id, so a later run finds the art
already at its final address and adopts it back for free. But recovering bookkeeping that was
already done costs an entire extra run against a daily quota of 1,000 requests.
Results now queue and drain to the database every 25 rows, capping the loss at the last partial
group. The flush is serialised behind its own gate rather than relying on the worker semaphore
being set to a concurrency of one, so raising that later cannot quietly introduce a race on the
non-thread-safe
DbContext. The trailing flush after the batch keeps the existing behaviour ofrecording work the daily quota cut short.
Release notes
end, so a batch stopped by the job timeout keeps the work it has already done.