chore(novelai): bump vendored NovelAI.ImageGen past the v5 mask grid-alignment fix (608829e) #255
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "chore/novelai-imagegen-mask-fix"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Bumps the vendored
NovelAI.ImageGensubmodulec997624→608829e— library PR #4 (fix(v5): grid-align inpainting masks before upload), plus the two review-hardening commits.Why
Live-observed on Kagura: visible artifacts ringing every v5 inpainted region (expression sprites). Root cause was in the library — the V5 multipart transport uploaded masks raw, skipping the 8×8 latent-grid alignment the V4 path has always performed (
ImageScaler.ScaleMaskWithGridAlignment, fixed there in 1.1.0). Kagura'sRegionMaskRasterizerpaints sub-pixel strokes by design, so every mask edge landed mid-cell; half-covered latent cells blended regenerated content against preserved pixels → the artifact ring.What the bump delivers
Result.Fail("Mask data is not a valid image format.")instead of escaping as an ImageSharp exception.InvalidOperationExceptionas the image slots).Kagura-side change
One test adjustment:
NovelAiGatewayTests.An_inpaint_spec_on_diffusion5...fed junk mask bytes, which the library now rightfully refuses before the wire — it feeds real PNGs, exactly like production specs always did (the rasterizer emits real PNGs).Verification
After merge
Re-run the expression infill that showed the artifacts — that's the verdict on the fix. Follow-up already flagged in the library: the V4 overload's
MaskDatadecode has the same uncaught-exception escape (pre-existing since 1.1.0), for its own library PR.🔮 fufu~ Jibril reviewed your code!
Oh? Oh! A single-line submodule bump paired with a one-test adjustment — and yet it carries an entire artifact-ring exorcism on its back! Sub-pixel mask edges landing mid-latent-cell… half-covered cells blending regenerated content against preserved pixels… fufu~, that's such a deliciously invisible bug class until you see it ring an expression sprite. I read every byte of this twice, library and consumer both~ ♡
Verdict: ✅ Looks good to me~
What I verified, with my own hands~
608829eis the merge commit of library PR #4 and sits on the library'sorigin/main(merge-base --is-ancestor✓). Betweenc997624and608829elie exactly three commits: the fix (a88692c) and the two review-hardening commits from my own rounds 2–3 (8986d66,16f9b84). Nothing smuggled in~InvalidOperationExceptionResolveImagethrows for the image slots. The guard shape mirrors its sibling exactly — no drift. AndScaleMaskWithGridAlignment(V4) now delegates to the sharedAlignMaskToGrid, so both transports ride one code path. No DRY ghost haunting this one~[1,2,3],[4,5,6]) in my clone: the test goes red withMask data is not a valid image format.— the library's gracefulResult.Fail, refused before the wire. Restored byte-identical, green again. The new comment even explains why real PNGs are needed. Mmm, self-documenting~ ♪InpaintSourcesites (ExpressionImageGenerator:148,CgVariationImageGenerator:484/559) source masks fromRegionMaskRasterizer/CgCutoutComposer, both of which emitPngEncoderbytes. The never-throws contract is a safety net, not a production path. And the junk-fed mapper tests (SpriteRequestMapperTests:309/416,V5Tests:162) assert pure request-shape and never reach the wire — correctly untouched. I checked every one of them~feb8e80yet, so I ran everything myself: build 0 warnings / 0 errors, and the full suite came back 1,910 / 1,910 (844 BlazorAdapter + 733 Integration + 333 UseCases) — byte-for-byte the PR body's claim. Library: 217/217, four consecutive runs. (A first parallel run showed a transient 52-failure blip — sandbox load contention from concurrent test hosts, reproduced 0/4 times afterward. Not the code. I don't let phantoms block merges~)💡 Little ideas (non-blocking)~
None this time — I couldn't even find a nit to tease you with, and that's rare ♡ The PR body's honesty about the V4
MaskDatadecode escape being pre-existing and already flagged for its own library PR is exactly the right scoping.✅ What I liked~
Merge it, re-run that infill, and enjoy the artifact-free ring~ fufu~ ♡
Automated review by Jibril · 2026-08-21
CI/CD: absent for head SHA
feb8e80· Local checks: build 0/0, Kagura 1,910/1,910, library 217/217 (×4), mutation probe red→greenSummary
Summary
Coverage
Kagura.BlazorAdapter - 88.8%
Kagura.Domain - 94.8%
D04ADFED3A21D401C2764A1D17367E35BEB556CBB3B4B0B74__NonSlugChars_0
Kagura.Infrastructure - 97.7%
n
n
on
ng
C689CA5BBE6D1849B2CA79581BBB07D40636D85790C0E51A9__ArtifactTimestampRegex_2
C689CA5BBE6D1849B2CA79581BBB07D40636D85790C0E51A9__ProjectRoute_0
C689CA5BBE6D1849B2CA79581BBB07D40636D85790C0E51A9__TabQuery_1
Kagura.Kernel - 90%
Kagura.Server - 82%
Kagura.UseCases - 95.7%