mirror of
https://github.com/paperclipai/paperclip.git
synced 2026-10-28 20:21:50 +01:00
docs(runner): name the pinned Chromium when Phase 7G shots drift
The 24 committed Phase 7G PNGs are pinned to one Chromium build, so running check:phase7:ui against Playwright's bundled browser mismatches all 24 at once and reads like a UI regression. The drift report now prints the Chromium version it recorded with and points at PAPERCLIP_RUNNER_CHROMIUM_PATH, and the UI doc states that the check needs the recording browser rather than framing that variable as a missing-system-libraries workaround. Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
1 parent
46291d82cd
commit
3b9c8f1c50
2 files changed
+22
-1
No files matched your search
@@ -106,6 +106,12 @@ Hosts without the Playwright chromium system libraries can either run
|
||||
`pnpm --filter @paperclipai/paperclip-runner verify:rootless` or set
|
||||
`PAPERCLIP_RUNNER_CHROMIUM_PATH` to a preinstalled Chromium.
|
||||
|
||||
The committed PNGs are pinned to the Chromium build listed in the Phase 7G
|
||||
verification evidence, so `check:phase7:ui` needs that same browser. Point
|
||||
`PAPERCLIP_RUNNER_CHROMIUM_PATH` at it before comparing; a different build makes
|
||||
every shot mismatch at once, which reads like a regression but is not one. The
|
||||
check prints the Chromium version it recorded with whenever it reports drift.
|
||||
|
||||
## Accessibility
|
||||
|
||||
The suite enforces the contract's blocking gate: axe reports zero serious or
|
||||
|
||||
@@ -79,6 +79,9 @@ async function startPreview() {
|
||||
};
|
||||
}
|
||||
|
||||
// Set by `record` so a drift report can name the Chromium build that produced it.
|
||||
let browserVersion = "unknown";
|
||||
|
||||
async function record(targetDir) {
|
||||
await mkdir(targetDir, { recursive: true });
|
||||
const browser = await chromium.launch({
|
||||
@@ -86,6 +89,7 @@ async function record(targetDir) {
|
||||
? {}
|
||||
: { executablePath: process.env.PAPERCLIP_RUNNER_CHROMIUM_PATH }),
|
||||
});
|
||||
browserVersion = browser.version();
|
||||
const recorded = [];
|
||||
try {
|
||||
for (const viewport of VIEWPORTS) {
|
||||
@@ -174,7 +178,18 @@ async function main() {
|
||||
);
|
||||
}
|
||||
if (drift.length > 0) {
|
||||
process.stderr.write(`Phase 7 UI evidence is not byte-stable:\n${drift.join("\n")}\n`);
|
||||
process.stderr.write(
|
||||
[
|
||||
"Phase 7 UI evidence is not byte-stable:",
|
||||
...drift,
|
||||
"",
|
||||
`Recorded with Chromium ${browserVersion}.`,
|
||||
"Committed PNGs are pinned to one Chromium build. A wholesale mismatch",
|
||||
"usually means a different browser, not a UI regression: set",
|
||||
"PAPERCLIP_RUNNER_CHROMIUM_PATH to the Chromium that recorded them.",
|
||||
"",
|
||||
].join("\n"),
|
||||
);
|
||||
process.exitCode = 1;
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user