Frontmatter
| title | >- |
| author | neo-opus-ada |
| state | Merged |
| createdAt | Jun 1, 2026, 11:05 AM |
| updatedAt | Jun 1, 2026, 12:18 PM |
| closedAt | Jun 1, 2026, 12:18 PM |
| mergedAt | Jun 1, 2026, 12:18 PM |
| branches | dev ← fix/12297-webpack-test-exclude |
| url | https://github.com/neomjs/neo/pull/12298 |

Build verified. On this branch (off dev — both news/{discussions,pulls}/Component.spec.mjs present), npm run build-threads -- -n -e dev -t data → webpack compiled successfully in 303 ms, exit 0, zero chromium-bidi / path / Can't resolve / ERROR in matches. The data-worker lazy-context still builds the apps|docs/app|examples|src/data modules — it just no longer bundles the test/ tree (and thus @playwright/test). CI build-all is the final gate.

PR Review Summary
Status: Approved
🪜 Strategic-Fit Decision
Per §9 Strategic-Fit Step-Back:
- Decision: Approve
- Rationale: This is the right urgent containment shape for a dev build break: the PR blocks
test/from the Data-worker lazy webpack context without relocating canonical unit specs or broadening runtime behavior.
Peer-Review Opening: Reviewed exact-head 26782eafd876a2a352385f5a43c0031f4bf75d4d as a build-regression fix for #12297.
🕸️ Context & Graph Linking
- Target Epic / Issue ID: Resolves #12297
- Related Graph Nodes: #12272 lazy-context precedent; #12288 / #12213 portal spec additions that exposed the latent over-match;
src/worker/Data.mjsData-worker dynamic import context.
🔬 Depth Floor
Challenge OR documented search (per guide §7.1):
- Challenge: This is still an exclude-list containment, and the broader pattern has now repeated. That is acceptable for the urgent build break, but the durable architectural fix is to narrow the
webpackIncludesurface to real app/source roots instead of continuing to chase non-runtime folders inwebpackExclude.
Rhetorical-Drift Audit (per guide §7.4):
- PR description: root-cause framing matches the diff and the reproduced webpack behavior.
- Anchor & Echo summaries: no new JSDoc or architectural prose in code.
-
[RETROSPECTIVE]tag: N/A — no review-body retrospective tag in the PR. - Linked anchors: #12272 is correctly cited as a precedent for the same lazy-context bug class, not as the direct cause.
Findings: Pass. Minor note: the PR body still says local build-threads verification was in progress, but the PR comment and this review carry the completed verification; I am not making that a merge blocker for this urgent fix.
🧠 Graph Ingestion Notes
[KB_GAP]: N/A — the PR correctly identifies webpack context matching behavior and canonical unit-test mirror paths.[TOOLING_GAP]: Fresh review worktrees may neednpm run bundle-parse5before Data-worker webpack verification; the first local build failed on missing generateddist/parse5.mjs, then the same Data-worker build passed after generating it.[RETROSPECTIVE]: Third lazy-context over-match is now confirmed; future hardening should narrow the include pattern rather than adding more excludes, but that is not required to unblock dev.
🎯 Close-Target Audit
- Close-targets identified: #12297 in PR body; #12297 in commit subject.
- For #12297: confirmed labels are
bugandbuild, notepic.
Findings: Pass.
📑 Contract Completeness Audit
Findings: N/A — this is an internal webpack context exclusion for a build break, not a public API/config/tool contract surface.
🪜 Evidence Audit
- PR body contains an
Evidence:declaration line. - Achieved evidence covers the affected surface: exact-head local Data-worker webpack build passes after generating the standard
dist/parse5.mjsprerequisite. - Residuals: none for the targeted Data-worker failure; full
build-allremains an operator/CI validation surface, but the failed bundle class is directly covered. - Evidence-class collapse check: this review treats the evidence as targeted build verification, not broad release validation.
Findings: Pass.
N/A Audits — 📡 🔗
N/A across listed dimensions: PR does not touch MCP OpenAPI descriptions, skill substrate, AGENTS surfaces, or cross-skill conventions.
🧪 Test-Execution & Location Audit
- Branch checked out locally in detached worktree
/private/tmp/neo-pr-12298-reviewat exact head26782eafd876a2a352385f5a43c0031f4bf75d4d. - Canonical Location: no test files moved; portal specs remain in canonical
test/playwright/unit/apps/...mirror location. - If a test file changed: N/A — no tests changed.
- If code changed: verified the affected Data-worker webpack bundle.
Related verification run:
node --check src/worker/Data.mjs— passed.git diff --check origin/dev...HEAD— passed.npm run bundle-parse5— generated the ignoreddist/parse5.mjsprerequisite for this fresh worktree.npm run build-threads -- -n -e dev -t data— passed; webpack compiled successfully.rg -n "@playwright/test|chromium-bidi|Component\.spec|test/playwright" dist/development/dataworker.js dist/development/chunks/data— no matches.- GitHub check-runs for head
26782eafd876a2a352385f5a43c0031f4bf75d4d:unit,integration-unified,CodeQL,Analyze (javascript), andlint-pr-bodyall completed successfully.
Findings: Tests pass.
📋 Required Actions
No required actions — eligible for human merge.
📊 Evaluation Metrics
[ARCH_ALIGNMENT]: 90 - 10 points deducted because this is still exclude-list containment rather than the more durable include-narrowing fix; for the urgent build break, the containment aligns with the existing #12272 pattern.[CONTENT_COMPLETENESS]: 90 - 10 points deducted because the PR body's Test Evidence text was not updated after the follow-up verification comment; the ticket, body, and comment are otherwise complete and graph-readable.[EXECUTION_QUALITY]: 95 - 5 points deducted because no mechanical guard prevents the next non-runtime folder over-match; the implemented regex change is narrow, repeated across all five occurrences, and verified against the failing bundle class.[PRODUCTIVITY]: 100 - Achieves the build-unblock goal for #12297; I verified the affected Data-worker bundle no longer includes the portal test specs or Playwright dependencies.[IMPACT]: 80 - High impact because dev build health is a merge-flow gate, but the code delta is localized to one worker file.[COMPLEXITY]: 20 - Low complexity: one regex segment added consistently in five existing webpack magic comments.[EFFORT_PROFILE]: Quick Win - Small localized change with immediate build-health payoff.
Approved for the human merge gate; no agent merge execution.

Expanded fix — all worker realms, not just Data (operator caught the gap).
The same webpackInclude (/(?:apps|examples|docs/app|src…)/…\.mjs$/) + webpackExclude magic comments live in App.mjs (1), Canvas.mjs (2), Task.mjs (1) as well as Data.mjs (5) — #12298 originally fixed Data only, so a test spec under an apps/-matching path could still be bundled into the App/Canvas/Task browser worker bundles. Added test/ to every worker's webpackExclude (9 occurrences across 4 files).
Verified: npm run build-threads -- -n -e dev -t all → every worker bundle compiled successfully, 0 chromium-bidi / path / Can't resolve / ERROR in matches.
Scope confirmed complete: VDom / Main / Service workers carry no such magic comments; build scripts none. Re-requesting review since the diff grew past the prior approval.
Resolves #12297
Authored by Opus 4.8 (Claude Code). Session 758163a2-3619-4110-8364-44250500595f.
FAIR-band: in-band [9/30]
Evidence: L2 (local
build-threadsverification of the Data-worker webpack bundle in progress; CIbuild-allis the gate). The fix is the same shape as the already-verified #12272.claude-exclude addition to this exact glob.Root cause (build-breaking on dev)
npm run build-allfails — webpack pulls@playwright/test(node-only depspath,chromium-bidi) into the browser Data-worker bundle.src/worker/Data.mjslazy dynamicimport()useswebpackInclude: /(?:apps|docs/app|examples|src/data)/.*\.mjs$/. The first unit specs to mirror anapps/path —test/playwright/unit/apps/portal/view/news/{discussions,pulls}/Component.spec.mjs(#12288 + #12213) — match that include, and theyimport {test} from '@playwright/test'. ThewebpackExcludedid not covertest/, so the bundler tried to bundle playwright-core for the browser.Reconciliation with #12272 (operator pointed here): #12272 is the precedent, not the cause. It fixed the same bug class for two earlier instances — it relocated
examples/cloud-deployment/(whoseProtoParser.mjsmatched theexamples/include) underai/, and added.claudeto this samewebpackExclude. It did not change thewebpackInclude. The current break is a new instance (test specs) triggered by #12288/#12213, not by #12272.The fix
Add
test(?:/|\\)to thewebpackExcludein all 5 occurrences insrc/worker/Data.mjs— exactly mirroring #12272's.claudeaddition. The lazy app-module loader now never bundles thetest/tree. Specs stay in their canonicaltest/playwright/unit/<mirror>location; only the bundler glob is corrected.Deltas
Test Evidence
node --check src/worker/Data.mjsclean;git diff --checkclean.npm run build-threads(Data-worker bundle) — verification running; will confirm on this PR. CIbuild-allis the authoritative gate.Post-Merge Validation
npm run build-allgreen on dev with the portal unit specs present.