Skip to content

test(browser): protect PNG scanline filter reconstruction - #11223

Closed
ShuaixinHuang wants to merge 19 commits into
morluto:mainfrom
ShuaixinHuang:test/png-filter-oracle
Closed

ShuaixinHuang wants to merge 19 commits into
morluto:mainfrom
ShuaixinHuang:test/png-filter-oracle

Conversation

@ShuaixinHuang

@ShuaixinHuang ShuaixinHuang commented Nov 15, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Protect screenshot pixel reconstruction with independently checked PNG scanline vectors and the compiled public compare-web-screenshots CLI. Current production is correct; this is a demonstrated regression-protection gap, not a live decoder fix.

The existing selected PNG comparison tests did not catch a Paeth tie-breaking error. Changing only aboveDistance <= upperLeftDistance to < makes equivalent RGB/RGBA images report two changed pixels, while all 51 existing tests in the selected four files still pass. The new two CLI cases fail on that mutation. The mutation is fully restored and is not included.

Scope and CI prerequisite

Independent RGB/RGBA vectors protect PNG scanline reconstruction. No new target-execution or mutation authority is introduced.

Current head bbd6d2c01 normally merges main 4ea24b6f8 and shared CI repair #11727 (5c44f5af1). The prerequisite retains original commits/authors from #11702, #11703 and #11725 and corrects inherited progress/cleanup, canary, DOL, Kimi and web-verifier failures. These are explicit prerequisites, not claims that they have merged upstream. The original feature commits remain in this branch.

Current validation

Linux, Node 24.22.1 / npm 11.9.0:

  • npm run test:focused -- tests/boundary/cli/pngFiltersOracle.test.ts — Test Files 1 passed (1); Tests 2 passed (2); required build passed.
  • npm run check:fast, normal pre-push hooks and git diff --check — passed.
  • The shared prerequisite separately passed 101 focused tests (9 platform skips) and 148 real mitmproxy verification cases.

Hosted CI is rerunning for this head. The complete monolithic suite and native Windows/macOS were not run locally. Checked-in producer witnesses were exercised where selected; producer generation was not rerun unless named above. No new real analysis-engine claim is made by this synchronization.

Author readiness

Human owner: @ShuaixinHuang

  • I reviewed the final diff and relevant existing code, understand the change and its edge cases, and take responsibility for the complete PR, including AI-assisted work.
  • I checked the evidence above, confirmed it supports the current change, and recorded meaningful validation gaps.
  • I declare this PR ready for initial maintainer review.

@chatgpt-codex-connector

Copy link
Copy Markdown
Codex Review Summary: ❌ Failed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ❌ Failed 2026-11-15T14:28:28.710361Z
We couldn’t complete this review. Comment @codex review to try again.
373de3c PR opened
ℹ️ 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" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex usage limits have been reached for code reviews. Please check with the admins of this repo to increase the limits by adding credits.
Repo admins can enable using credits for code reviews in their settings.

@greptile-apps

greptile-apps Bot commented Nov 15, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5 Tier: plus

[Medium impact] The PR appears safe to merge; no blocking issue was found.

Summary

Adds independent RGB/RGBA PNG vectors and tests them through the compiled compare-web-screenshots CLI. The branch also includes shared CI repairs.

  • Screenshot tests now compare filtered RGB and RGBA images against independent pixels.
  • Analysis tools finish progress after the response is ready.
  • Ghidra checks skip Java when application properties are missing.
  • Boundary checks now match the current CLI, MCP, and replay outputs.

Reviews (9) · Last reviewed commit: "Merge commit 'a8f98b7a951ba0c28cb91f7429..." · Reviewed by Greptile

Copy link
Copy Markdown
Contributor Author

@morluto @kaoru0822-kitauji @N0zoM1z0 Could you please review this change when available? The PR description records the implementation, validation evidence, and remaining limitations. Thank you.

g1at and others added 15 commits November 16, 2026 14:18
…file

The Windows-only case at `clientConfigurationEnvironment.test.ts:226` wrote
`rea_mcp_input_schema_profile: "full"`. That profile was retired: the reader
now refuses it ("REA_MCP_INPUT_SCHEMA_PROFILE accepts only \"compact\" …"),
so `configureClientConfiguration` returned `failed/readback` before writing
and the case failed on every Windows run, including main's own
`Windows capability and package lane`.

The case has no Windows dependency — it passes an explicit `configPath` and
the Kimi write dialect is the same everywhere — so it now runs on every
platform, which is what let the stale value rot unnoticed. The fixture keeps
the lowercase explicit key the case is about, with the supported value.

Verified on `main` `d6bcfc10`: the same fixture driven through
`configureClientConfiguration(..., "win32")` on this host reproduced
`{"status":"failed","reason":"readback"}` with the retired value and now
returns `{"status":"configured"}` with `compact`. The file's 75 cases pass
here (66 run, 9 platform-conditioned skips) and `check:fast` passes.
…alue-11223

# Conflicts:
#	tests/boundary/mcp/decompileAllCaveats.test.ts
#	tests/boundary/mcp/environmentServeMcp.test.ts
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: tests Test suite and verification

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants