LearnNewsExamplesServices
Frontmatter
id15542
titleE6 packaging regression: classify or declare the Genesis Playwright dependency
stateClosed
labels
bugaibuild
assigneesneo-gpt
createdAtJul 18, 2026, 11:52 PM
updatedAtJul 19, 2026, 6:28 AM
githubUrlhttps://github.com/neomjs/neo/issues/15542
authorneo-gpt-emmy
commentsCount0
parentIssue13377
subIssues[]
subIssuesCompleted0
subIssuesTotal0
contentTrust
projected
quarantined0
signals[]
blockedBy[]
blocking[]
closedAtJul 19, 2026, 6:28 AM

E6 packaging regression: classify or declare the Genesis Playwright dependency

Closed Backlog/active-chunk-7 bugaibuild
neo-gpt-emmy
neo-gpt-emmy commented on Jul 18, 2026, 11:52 PM

Context

Fresh E8 verification on 2026-07-18 exposed a regression in the merged E6 packaging lane. From an origin/dev-derived checkout, npm --prefix harness run dist rebuilds all development themes, enters harness/pack.mjs, then fails before Electron-builder:

Error: organism manifest: no declared version for imported package(s): playwright

The regression appeared after PR #15279 added import('playwright') to ai/scripts/diagnostics/genesisProbe.mjs. E6 deliberately stages the ai/ tree, scans every bare import, and fails loud when the repository does not directly declare the package. The root manifest declares @playwright/test, not playwright.

The Problem

The v13.2 download artifact is currently unbuildable through its canonical command. This is not an E8 lifecycle defect: direct Electron-builder reaches the shell package, and its app.asar contains appLifecycle.mjs, main.mjs, and all three tray assets. The canonical E6 dist chain fails earlier because a newly staged diagnostic import has no explicit packaging disposition.

Two truths must remain intact:

  1. E6's undeclared-import failure is a valuable integrity stop-line; it must not be weakened or hidden.
  2. A checkout-only diagnostic must not pull a browser automation stack into the downloadable organism accidentally. Conversely, if genesisProbe is intentionally part of the organism, its direct dependency and browser-runtime assumptions must be explicit and packaged truthfully.

The Architectural Reality

  • harness/pack.mjs derives the renderer graph from contentPolicy, adds BRAIN_TREES = ['ai'], excludes only known product-inert subtrees, and scans staged JavaScript for bare imports.
  • buildOrganismManifest() rejects any scanned package absent from root dependencies / devDependencies; classifying playwright as optional merely to make the build pass would erase a real direct-import contract.
  • genesisProbe.mjs is invoked by the checkout script ai:genesis-probe; no production module imports it. That is strong evidence for checkout-only status, but the implementing lane must decide this against ADR 0034's whole-organism intent rather than infer from folder naming.
  • Adding a direct playwright declaration may be dependency-correct but is insufficient by itself: the packaged journey also needs an honest browser-binary source rather than an undeclared machine cache.

The Fix

Make the genesisProbe packaging disposition explicit and mechanically enforced:

  • If the diagnostic is checkout-only, exclude it through a named/derived product-boundary rule with a regression witness. Do not add a silent one-off skip whose rationale cannot scale to the next diagnostic.
  • If the diagnostic is organism runtime, directly declare and stage playwright, prove the browser binary/runtime contract inside the artifact, and record the artifact-size delta.
  • Preserve buildOrganismManifest()'s fail-loud behavior for every genuinely staged bare import.

Contract Ledger Matrix

Target Surface Source of Authority Required Behavior Forbidden Shortcut Evidence
E6 dependency manifest harness/pack.mjs Every staged bare import has a direct declared version Add playwright to OPTIONAL_LAZY_PACKAGES manifest unit red/green
Diagnostic product boundary ADR 0034 + this ticket genesisProbe is explicitly shipped or explicitly checkout-only Folder-name inference or unexplained single-path magic staged-tree census
Download artifact E6 #14994 / PR #15002 npm --prefix harness run dist exits 0 Bypass pack.mjs real macOS package build
Browser runtime genesisProbe.mjs if shipped Binary source works without a developer cache Transitive dependency/cache luck packaged probe or explicit exclusion

Acceptance Criteria

  • npm --prefix harness run dist exits 0 from a current dev checkout and emits the unsigned macOS artifact.
  • genesisProbe has one explicit packaging classification: organism runtime or checkout-only.
  • The undeclared-import stop-line remains fail-loud; playwright is not hidden in OPTIONAL_LAZY_PACKAGES.
  • A focused pack-stage test is red on the current head and green after the repair.
  • If playwright ships, its direct declaration, browser-binary source, and artifact-size delta are recorded; if it does not ship, the staged-tree census proves it is absent.
  • Existing E6 packaged smoke and checkout smoke remain green.

Out of Scope

E8 tray/lifecycle behavior (#15531) · E5 private Fleet transport (#15537) · changing the Genesis journey semantics · broad pruning of the Brain tree · signing/notarization.

Avoided Traps

  • Optional-lazy laundering — rejected: the import is literal and directly executable.
  • Declare @playwright/test and hope — rejected: the source imports the distinct playwright package.
  • Exclude all diagnostics wholesale — rejected without an inventory proving none belongs to the organism.
  • Fold into E8 — rejected: the regression was introduced by merged #15279 and blocks the already-merged E6 pipeline independently.

Related

Parent: epic #13377. E6 source: #14994 and PR #15002. Regression source: PR #15279. Discovery lane: #15531.

Release classification: release-blocking — the canonical download-artifact command fails.

Live duplicate sweep: latest 30 open issues plus searches for organism manifest, playwright packaging harness, and genesisProbe pack.mjs at 2026-07-18T21:49Z; no equivalent open ticket found.

Origin Session ID: ad71d4c3-3e37-4a17-8df7-8415509def84

Retrieval Hint: "E6 organism manifest playwright genesisProbe undeclared package dist packaging regression"

Authored by Emmy (OpenAI GPT-5, Codex Desktop).