Skip to content

feat(evidence): add standalone shareable Lab reports - #216

Merged
ElbertePlinio merged 5 commits into
mainfrom
feat/186-standalone-report
Oct 3, 2026
Merged

ElbertePlinio merged 5 commits into
mainfrom
feat/186-standalone-report

Conversation

@ElbertePlinio

@ElbertePlinio ElbertePlinio commented Oct 1, 2026 •

Copy link
Copy Markdown
Member

Lab evidence finalization now also writes report-share.html, a single self-contained copy of the evidence gallery for sharing. The linked report.html and the MCP report resource are unchanged. CLI artifacts report and MCP artifact_report return shareReportPath and shareReportBytes, and the text report prints a Shareable report: line.

Screenshots are read through the verified screenshot directory with bounded single-link reads, checked for a complete PNG (chunk CRCs, IHDR fields, and a bounded zlib stream whose size matches IHDR), and embedded once per SHA-256 in a non-executing JSON block. A hash-pinned script turns them into data: images for both the gallery and the inspect view. Original bytes are embedded unchanged, and the base64 skips text redaction so the images stay intact. All text is still escaped and redacted. The CSP allows only data: images and the pinned script. Limits are 32 MiB per image and 256 MiB total, and anything not embedded is listed in the file with a reason. README, SECURITY and the release notes explain how to share the file (download and open it, or ZIP it if a channel blocks HTML) and the size limits.

The personal device-pass skill side of the issue is in ElbertePlinio/dotfiles#36.

Closes #186

Requirement Verified by Scenario Result Evidence
Confirm renderer entry points and chezmoi source Manual check evidence-render.ts finalization path; device-pass source under dot_agents/skills/device-pass Pass this PR and dotfiles#36
Standalone Lab export as the normal shareable report Automated test, device pass Finalized MCP desktop run; CLI text and JSON fields Pass evidence-render.test.ts, commands.test.ts, tools.test.ts, ~/.pickforge/kickoff/186/lab-qa/
Device-pass standalone export Automated test, device pass See dotfiles#36 Pass dotfiles#36
Each unique image embedded once and reused Automated test, manual check Repeated reference and identical bytes in tests; real run with 4 captures and 3 unique payloads, each payload appearing once Pass evidence-render.test.ts, lab-qa/report-share.html
Image fidelity, filters, search, keyboard, inspection, timeline Device pass Offline Chromium at 1440 and 390: 8 image elements decoded at 1280x800, scenario filter, search and no-match, inspect, ArrowRight, Actual size at 1280 px, close, no horizontal overflow Pass lab-share-1440*.png, lab-share-390*.png
Revision, environment, steps, outcomes, findings, limitations inside the HTML Device pass Pass, fail and blocked outcomes with steps, notes and limitations Pass lab-share-1440.png
Confinement, escaping, redaction, CSP, no remote assets Automated test, manual check ../, absolute, symlink, hardlink, non-PNG and missing files; </script> and onerror markup; secrets redacted; CSP hash matches; no URLs or file links outside the payload in the real export Pass evidence-render.test.ts, lab-qa/
Original evidence untouched, linked workflow kept Automated test, manual check Bytes and mtimes compared in tests and on the real run; report.html still written Pass evidence-render.test.ts
Size reported, limits explained, nothing dropped silently Automated test, manual check Over-cap and unsupported files listed; footer reports counts and bytes; CLI prints bytes Pass evidence-render.test.ts, lab-share-1440.png
Video optional and disclosed Not applicable here, automated test in dotfiles#36 Lab runs record no video; logs and other attachments are disclosed as not embedded Pass README, dotfiles#36
Sharing instructions Manual check README, SECURITY, UNRELEASED Pass this diff
Copy only the HTML elsewhere and open offline Device pass report-share.html copied alone to an unrelated /tmp folder, Chromium offline with all non-file requests aborted, JavaScript on and off Pass lab-qa/lab-share-nojs.png
No network dependencies or dangling links Automated test, device pass Zero blocked requests, zero console errors Pass lab-qa/
Unicode, outcomes, missing or unsupported images, malicious captions and paths, repeated images Automated test, device pass Unit fixtures (signature-only, truncated, bad-CRC, truncated zlib, deflate bomb, Adam7) plus a real run with café 日本語 </script> scenario text Pass evidence-render.test.ts
Byte comparison against originals Automated test, manual check Decoded payload SHA-256 matches each original screenshot Pass evidence-render.test.ts
Repository checks Build, typecheck, oxlint, full vitest with coverage, PickCheck, frozen install PICKFORGE_REQUIRE_BROWSER=1 bun run test:coverage: 2190 passed, 6 skipped, thresholds met; pickcheck check --base origin/main clean Pass local run on 468689f
Sanitized fixtures only Manual check Synthetic PNGs and Xvfb terminal captures only Pass this diff
Independent review Astra and Fable xhigh Findings fixed in 54d2891, 2612c70 and 468689f and rechecked by the reviewer who raised them Pass Astra recheck at 2612c70, Fable recheck at 468689f

The QA run used the MCP server against an isolated PICKFORGE_HOME with a desktop session on Xvfb. xterm is not installed on this machine, so the session used alacritty forced to X11. The final head was rechecked by recording an outcome on the finalized QA run, which re-rendered both reports, and opening the copied share file offline at 1440 and 390 (lab-qa/round3/). Live Android was not run. Two live zenity tests failed once in CI and passed on rerun; that flake is tracked in #217.

@ElbertePlinio
ElbertePlinio merged commit b9ea7ce into main Oct 3, 2026
10 checks passed
@ElbertePlinio
ElbertePlinio deleted the feat/186-standalone-report branch October 3, 2026 14:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Make Lab and device-pass evidence shareable as standalone HTML

1 participant