Skip to content

fix(capture): sample forced states in one CDP session - #339

Merged
BenSheridanEdwards merged 1 commit into
mainfrom
fix/forced-state-same-session
Aug 1, 2026
Merged

fix(capture): sample forced states in one CDP session#339
BenSheridanEdwards merged 1 commit into
mainfrom
fix/forced-state-same-session

Conversation

@BenSheridanEdwards

Copy link
Copy Markdown
Owner

Why does this feature exist?

StyleProof 4.7.3 flushed forced pseudo-state transitions in one CDP session but sampled the subtree through a separate Playwright session. Hydrated applications could therefore report intermittent phantom hover and active changes on unchanged controls.

What changed?

  • Sample the base and forced computed-style subtree through the same CDP session that applies the pseudo-state.
  • Fail loudly if the in-session snapshot raises a browser exception.
  • Repeat the forced-state regression across eight independent captures.
  • Release the correction as 4.7.4 and document it in the changelog.

Behavioural Proof (with video and screenshots)

  • Video: Not applicable; this is a non-visual capture-engine synchronization fix.
  • Screenshots: Not applicable; generated screenshots would not independently prove protocol-session correctness.
  • Behaviour tests: The focused Chromium regression completed eight independent forced-state sweeps and asserted byte-equivalent maps while preserving hover, focus-visible, and active deltas for every one of 24 controls. Full prepublish verification passed: 631 unit tests and 117 browser tests.

Verification Summary

  • Definition of Done: followed .agents/project/DEFINITION_OF_DONE.md.
  • Commands run: npm run prepublishOnly; the repository commit and push hooks also ran build, typecheck, lint, format, privacy, fallow, gitleaks, and the unit suite.
  • Results: 631 unit tests passed; 117 Chromium tests passed; zero failures.
  • Known risks or skipped checks: No checks skipped. Adopters should regenerate affected baselines because previously captured forced-state values may contain false deltas.

Checklist

  • Proof above — linked the regenerated docs/demo/report.md, or pasted the command/test output that demonstrates the change
  • If you changed capture/diff/report rendering, ran npm run demo:report and committed docs/demo/ (not applicable: rendering unchanged)
  • npm run build && npm run typecheck && npm run lint && npm run format:check pass
  • npm test passes (and npm run test:e2e if the capture/engine path changed)
  • Added/updated tests for the change
  • Updated the README / CHANGELOG if behaviour or the public API changed
  • If captured output changed, noted that adopters must regenerate baselines
  • Followed .agents/project/DEFINITION_OF_DONE.md and .agents/skills/pr-inline-screenshot-proof/SKILL.md
  • Screenshots are committed and embedded inline, or the proof section says Not applicable with the technical reason
  • The PR body has no bare screenshot links, local paths, relative paths, or proof placeholders

@github-actions

github-actions Bot commented Aug 1, 2026

Copy link
Copy Markdown

🗺️ StyleProof report

📊 View the side-by-side visual report →


Coverage, determinism, or report/diff consistency evidence is incomplete — repair the capture or reflow source; visual approval cannot clear this failure.

@BenSheridanEdwards
BenSheridanEdwards merged commit 8162814 into main Aug 1, 2026
12 checks passed
@BenSheridanEdwards
BenSheridanEdwards deleted the fix/forced-state-same-session branch August 1, 2026 21: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.

1 participant