Repository navigation
fix(render): name the background blurs an export leaves out - #258
Conversation
A background blur past the per-export limit (64 blurs or 32 MiB of backdrop) was dropped without a trace: every blurred node carries the same static approximate diagnostic, so warnings could not tell which blur, if any, was missing from the image. The render now returns the nodes it left out, and export, bundle and compare-image warnings name them. At most 20 nodes are named and the rest counted, so a crafted file cannot grow a report without bound.
|
@codex review |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex Review: Didn't find any major issues. Chef's kiss. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 68afa95c1a
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…READMEs and skill The warning is only produced by a render, so nodes and inspect cannot show it. Help, every README locale and the served Known gaps section now say where it appears and that 20 nodes are named before a count.
|
@codex review |
|
Codex Review: Didn't find any major issues. More of your lovely PRs please. Reviewed commit: ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
Problem
A background blur past the per-export limit (64 blurs or 32 MiB of expanded backdrop,
src/render.rs) is skipped so a crafted file cannot exhaust the renderer. Nothing recorded which blur was skipped:_figlens.renderDiagnosticsputs the same staticapproximatenote on every blurred node, soexportand bundle warnings could not say which blur, if any, was missing from the image.Change
The render records the nodes whose background blur the limit left out.
Svg::document_reportingandPrepared::export_svg_reportingreturn them;Svg::documentandPrepared::export_svg_inare unchanged wrappers.export(SVG and raster),bundle(vector, composite and reference renders, each node once) andcompare-imageadd a warning per node:At most 20 nodes are named; one more line counts the rest. Export warnings are stored in the visual index's render evidence (256 KiB cap), so an unbounded list would have turned a skipped blur into a failed index unit.
The MCP
exportwarnings description, the bundlecontext.mdnote on render warnings andwiki/render.mddescribe the new line.Output for exports under the limit is unchanged.
Interfaces
export,export --batch,bundleandcompare-imageshare these report paths, so the warning appears in both. No new flag or parameter.exportoutput but not its warnings; no change.--help, READMEs, site, skill: none describe warnings at this level; no change.Checks
docker compose run --rm dev sh -c 'cargo fmt --check && cargo clippy --all-targets -- -D warnings': cleandocker compose run --rm dev cargo test: all pass (838 lib tests)npm test: 234 passpython3 scripts/ai-context.py check: okfiglens-code-reviewpasses run on the diff; verified findings fixed (warning cap,compare-image, MCP description,context.mdtext, two simplifications).Not run: the corpus check (under-limit output is unchanged by construction, not measured) and a
compare-imagetest for the new line.Limits
MAX_CUTS) is still not reported: it is an approximation with no single node to name.nodesandinspectdo not render, so they cannot report a dropped blur.verifydo not surface this warning.wiki/render-diagnostics.mddoes not mention the new line: thebundletopic has 13 bytes left under its cap. The rule is inwiki/render.md.