Skip to content

Deploy the browser analyzer to GitHub Pages - #18

Merged
alexandrefimov merged 2 commits into
mainfrom
pages-deploy
Aug 11, 2026
Merged

Deploy the browser analyzer to GitHub Pages#18
alexandrefimov merged 2 commits into
mainfrom
pages-deploy

Conversation

@alexandrefimov

Copy link
Copy Markdown
Owner

Summary

Publishes the browser analyzer merged in #17 to
https://alexandrefimov.github.io/Query-Doctor/ and links it from both READMEs.

actions/deploy-pages builds web/dist in CI on pushes to main that touch
web/ or the analyzer. A gh-pages branch was the alternative and was
rejected: it would commit ~13 MB of Pyodide binaries per rebuild and let the
deployed site drift from source, which is exactly why build.sh fetches the
runtime at build time instead of vendoring it.

The workflow serves the built site and runs bench/check_page.py against it, so
a deploy fails if the page reaches an external host, raises a JS error, or
renders nothing.

That check was decorative until this change. It watched responses, and an
external reference that fails to resolve never produces one — so on a runner
with blocked egress, a page phoning home would have passed silently. It now
watches requests. Verified both directions by injecting
<img src="https://example.com/pixel.png"> into a built copy: caught now
(FAIL: page reached external hosts: ['example.com']), missed before.

Pages is enabled with build_type=workflow, so nothing is served from a branch
and docs/ is not published.

Type

  • Feature or workflow change
  • CI, packaging, or release
  • Documentation
  • Bug fix
  • Safety or trust-boundary change
  • Tests only

Safety Checklist

  • No raw production SQL, profiles, metadata, local paths, hostnames, secrets, subprocess output, model/runtime internals, or raw artifact filenames are introduced.
  • Browser-visible UI and trusted reports remain sanitized. The page redacts with redact_profile_text before analyzing, as merged in Turn the README into a landing page, add a browser analyzer prototype #17.
  • External collection changes: none. The published page performs no collection and no network access after load, now enforced by the deploy gate.
  • Query Optimizer changes: none.
  • LLM-facing changes: none.
  • Unsupported evidence remains unknown, not_observed, or explicitly unsupported.
  • No screenshots, logs, generated reports, or browser captures from real clusters are added.
  • Fixtures and examples are synthetic. The published sample profile is generated at build time by web/bench/make_profile.py.

The site is public and serves synthetic demo data plus whatever profile the
visitor drops locally. Visitor profiles are never transmitted.

Validation

  • Full suite: 4697 passed, 1 skipped
  • Docs CI: all four checks
  • ruff check web/bench scripts
  • git diff --check
  • Built site verified locally: boot ~1.0 s, 103 KiB sample profile in 162 ms, 8 requests, no external hosts, no JS errors
  • Deploy gate verified in both directions (clean build passes, injected external resource fails)

Documentation

Branch Hygiene

  • Targets a review branch, not direct pushes to main.
  • Based on current main.

Assisted-by: Claude Opus 5 via Claude Code

Builds web/dist in CI and publishes it with actions/deploy-pages on pushes to
main that touch web/ or the analyzer. A gh-pages branch was the alternative and
was rejected: it would commit ~13 MB of Pyodide binaries on every rebuild and
let the deployed site drift from source, which is the reason build.sh fetches
the runtime at build time in the first place.

The workflow serves the built site and runs bench/check_page.py against it, so
the deploy fails if the page reaches an external host, raises a JS error, or
renders nothing. That check was previously decorative: it watched responses, and
an external reference that fails to resolve never produces one, so a blocked
request would have passed silently. Verified both directions by injecting an
external image into a built copy -- caught now, missed before.

Both READMEs lead with the hosted link. It needs no install and no upload, which
is the shortest honest path from reading about the tool to seeing it work.
@alexandrefimov
alexandrefimov merged commit 1b607ab into main Aug 11, 2026
12 checks passed
@alexandrefimov
alexandrefimov deleted the pages-deploy branch August 11, 2026 11:35
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