Skip to content

feat(ci): add live-verification check for plugin PRs - #1

Merged
pdmacinnes merged 1 commit into
masterfrom
feat/plugin-live-check-ci
Aug 5, 2026
Merged

feat(ci): add live-verification check for plugin PRs#1
pdmacinnes merged 1 commit into
masterfrom
feat/plugin-live-check-ci

Conversation

@pdmacinnes

Copy link
Copy Markdown
Owner

Summary

  • Adds scripts/live-check-plugin.js: bundles a plugin with esbuild and runs it against the real site (popularNovels -> searchNovels -> parseNovel -> parseChapter), classifying each step PASS/FAIL/INCONCLUSIVE.
  • Adds .github/workflows/plugin-live-check.yml: runs the check on PRs that touch plugins/**/*.ts (excluding multisrc-generated files), posts a summary PR comment, and only fails the check on a genuine FAIL — a target site being briefly down or Cloudflare-blocked never blocks a merge.
  • npm run check:plugin -- <path> for local use before opening a PR; documented in docs/testing.md.

Motivated by the Baka-Tsuki plugin work: tsc/ESLint/Prettier were all clean while six real bugs were live (zero chapters returned, search leaking foreign-language pages). None of that is visible to a compiler when the target is a user-edited site with no schema — only actually running the plugin against the live site catches it.

Private review draft on my own fork — not yet proposed to lnreader/lnreader-plugins upstream.

Test plan

  • Verified against plugins/english/bakaTsuki.ts (known-good) — all 4 steps PASS
  • Verified against a deliberately-broken copy of chrysanthemumgarden.ts (mutated chapter selector) — correctly FAILs at parseChapter only, earlier steps still PASS
  • npm run lint / npm run format:check clean on new files

🤖 Generated with Claude Code

Type-checking/lint/prettier all pass while a plugin can still be
genuinely broken - the Baka-Tsuki plugin shipped six real bugs
(zero chapters, foreign-language search leakage, etc.) that none of
them caught. scripts/live-check-plugin.js bundles a plugin with
esbuild and runs it against the real site (popularNovels,
searchNovels, parseNovel, parseChapter), classifying each step
PASS/FAIL/INCONCLUSIVE so a target site being briefly down or
Cloudflare-blocked never fails CI.

Wired into .github/workflows/plugin-live-check.yml: runs only
against plugin files changed in a PR, posts one summary comment,
and only fails the check on a genuine FAIL.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
@pdmacinnes
pdmacinnes merged commit f6067e7 into master Aug 5, 2026
3 checks passed
@pdmacinnes
pdmacinnes deleted the feat/plugin-live-check-ci branch August 5, 2026 15:09
@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Aug 8, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant