[PR #170] [MERGED] fix: pin chess.js so the chess package rebuilds from a clean checkout #836

Closed
opened 2026-10-20 17:31:29 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/Pasta-Devs/Marinara-Agents/pull/170
Author: @Romuromylus
Created: 7/31/2026
Status: ✅ Merged
Merged: 8/1/2026
Merged by: @Romuromylus

Base: staging ← Head: fix/169-chess-js-dependency


📝 Commits (2)

  • 6b26e63 fix: pin chess.js so the chess package rebuilds from a clean checkout
  • 5ac91fe docs: npm ci setup step + external-source-root resolution caveat

📊 Changes

4 files changed (+45 additions, -0 deletions)

View changed files

➕ .gitignore (+1 -0)
📝 CONTRIBUTING.md (+8 -0)
➕ package-lock.json (+24 -0)
➕ package.json (+12 -0)

📄 Description

Important

Contributions target staging. Only SpicyMarinara may promote this repository's staging branch to main.
Outside and first-time contributors also require an approving review from SpicyMarinara.

Linked issue

Closes #169

Why this change

The chess feature bundle imports chess.js, but the Engine dropped that dependency when the turn games moved into this catalog, and this repository had no dependency manifest of its own. The library existed nowhere, so node scripts/build-feature-packages.mjs chess failed with Could not resolve "chess.js" on any clean Engine + Agents checkout — the chess package was the only one in the catalog that could not be rebuilt reproducibly (#168 worked around it with a scratch install).

What changed

Option 1 from #169 — a root dependency manifest, no builder changes:

  • package.json — new minimal private manifest pinning chess.js@1.4.0 exactly (the version the Engine shipped before the extraction; the committed chess bundle was built from it).
  • package-lock.json — lockfile for that single dependency (chess.js has no transitive deps).
  • .gitignore — new, ignores node_modules/.
  • CONTRIBUTING.md — documents npm install as a one-time setup step under Requirements and Setup, and why the manifest exists.

No generated outputs changed. Node module resolution walks upward from sources/engine/…, so the builder resolves chess.js from this repository's node_modules exactly the way every other bare import already resolves — no changes to build-feature-packages.mjs needed.

Package and security impact

  • Affected package IDs: chess (rebuild path only — its committed payload, manifest, artifact, and catalog entry are untouched)
  • Engine compatibility impact: none
  • New or changed permissions/entrypoints: none
  • Restart, storage, update, or uninstall impact: none

Validation

  • node scripts/validate-catalog.mjs passes locally
  • git diff --check passes locally
  • Rebuilt every affected manifest, payload, artifact, and catalog entry
  • Installed or updated the affected package through Marinara Engine
  • Checked supported modes, restart behavior, and uninstall cleanup
  • Read and followed CONTRIBUTING.md

Manual verification notes

  • Reproduced the failure first: on this checkout, the chess server bundle build fails with Could not resolve "chess.js" (only the chess package; every other bare import resolves).
  • Ran npm install at the repo root, then rebuilt the chess server bundle with the builder's exact entry stub and esbuild flags. chess.js now resolves from Marinara-Agents/node_modules.
  • The rebuilt bundle is byte-identical to the committed packages/chess/server.mjs after normalizing the committed file's CRLF line endings (51 \r bytes from the Windows build noted in #168) — i.e. the pinned chess.js@1.4.0 reproduces exactly the shipped artifact.
  • node scripts/test-catalog-lanes.mjs — passes.
  • node scripts/validate-catalog.mjs — passes (31 packages, v2=31, v3=6; legacy=v2).
  • git diff --check — clean.
  • Same Windows caveat as #168 applies to this environment: the builder's spawnSync("pnpm", …) cannot spawn here, so the rebuild used the Engine's esbuild binary directly with the builder's flags. The dependency-resolution change this PR makes is independent of that.

Documentation impact

  • No documentation changes needed
  • Updated this README catalog and package guidance
  • Updated linked Marinara Engine documentation

(CONTRIBUTING.md setup section — the README catalog itself is unchanged.)

UI evidence (if applicable)

Not applicable — build/tooling change only.

Summary by CodeRabbit

  • Documentation

    • Added contributor setup instructions for installing dependencies before rebuilding feature packages.
    • Clarified how shared root dependencies are made available to feature sources.
  • Chores

    • Added project package configuration with a Node.js 24+ requirement.
    • Added the pinned chess.js dependency.
    • Updated ignore rules to exclude installed Node.js dependencies.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/Pasta-Devs/Marinara-Agents/pull/170 **Author:** [@Romuromylus](https://github.com/Romuromylus) **Created:** 7/31/2026 **Status:** ✅ Merged **Merged:** 8/1/2026 **Merged by:** [@Romuromylus](https://github.com/Romuromylus) **Base:** `staging` ← **Head:** `fix/169-chess-js-dependency` --- ### 📝 Commits (2) - [`6b26e63`](https://github.com/Pasta-Devs/Marinara-Agents/commit/6b26e63c93f39c33fe0314797176346dead5afcf) fix: pin chess.js so the chess package rebuilds from a clean checkout - [`5ac91fe`](https://github.com/Pasta-Devs/Marinara-Agents/commit/5ac91fe6057dee4c83f267f169efbeb841189bdf) docs: npm ci setup step + external-source-root resolution caveat ### 📊 Changes **4 files changed** (+45 additions, -0 deletions) <details> <summary>View changed files</summary> ➕ `.gitignore` (+1 -0) 📝 `CONTRIBUTING.md` (+8 -0) ➕ `package-lock.json` (+24 -0) ➕ `package.json` (+12 -0) </details> ### 📄 Description > [!IMPORTANT] > Contributions target `staging`. Only `SpicyMarinara` may promote this repository's `staging` branch to `main`. > Outside and first-time contributors also require an approving review from `SpicyMarinara`. ## Linked issue Closes #169 ## Why this change The chess feature bundle imports `chess.js`, but the Engine dropped that dependency when the turn games moved into this catalog, and this repository had no dependency manifest of its own. The library existed nowhere, so `node scripts/build-feature-packages.mjs chess` failed with `Could not resolve "chess.js"` on any clean Engine + Agents checkout — the chess package was the only one in the catalog that could not be rebuilt reproducibly (#168 worked around it with a scratch install). ## What changed Option 1 from #169 — a root dependency manifest, no builder changes: - `package.json` — new minimal private manifest pinning `chess.js@1.4.0` exactly (the version the Engine shipped before the extraction; the committed chess bundle was built from it). - `package-lock.json` — lockfile for that single dependency (chess.js has no transitive deps). - `.gitignore` — new, ignores `node_modules/`. - `CONTRIBUTING.md` — documents `npm install` as a one-time setup step under Requirements and Setup, and why the manifest exists. No generated outputs changed. Node module resolution walks upward from `sources/engine/…`, so the builder resolves `chess.js` from this repository's `node_modules` exactly the way every other bare import already resolves — no changes to `build-feature-packages.mjs` needed. ## Package and security impact - Affected package IDs: `chess` (rebuild path only — its committed payload, manifest, artifact, and catalog entry are untouched) - Engine compatibility impact: none - New or changed permissions/entrypoints: none - Restart, storage, update, or uninstall impact: none ## Validation - [x] `node scripts/validate-catalog.mjs` passes locally - [x] `git diff --check` passes locally - [x] Rebuilt every affected manifest, payload, artifact, and catalog entry - [x] Installed or updated the affected package through Marinara Engine - [x] Checked supported modes, restart behavior, and uninstall cleanup - [x] Read and followed `CONTRIBUTING.md` ### Manual verification notes - Reproduced the failure first: on this checkout, the chess server bundle build fails with `Could not resolve "chess.js"` (only the chess package; every other bare import resolves). - Ran `npm install` at the repo root, then rebuilt the chess server bundle with the builder's exact entry stub and esbuild flags. `chess.js` now resolves from `Marinara-Agents/node_modules`. - **The rebuilt bundle is byte-identical to the committed `packages/chess/server.mjs`** after normalizing the committed file's CRLF line endings (51 `\r` bytes from the Windows build noted in #168) — i.e. the pinned `chess.js@1.4.0` reproduces exactly the shipped artifact. - `node scripts/test-catalog-lanes.mjs` — passes. - `node scripts/validate-catalog.mjs` — passes (`31 packages`, `v2=31, v3=6; legacy=v2`). - `git diff --check` — clean. - Same Windows caveat as #168 applies to this environment: the builder's `spawnSync("pnpm", …)` cannot spawn here, so the rebuild used the Engine's esbuild binary directly with the builder's flags. The dependency-resolution change this PR makes is independent of that. ## Documentation impact - [ ] No documentation changes needed - [x] Updated this README catalog and package guidance - [ ] Updated linked Marinara Engine documentation (CONTRIBUTING.md setup section — the README catalog itself is unchanged.) ## UI evidence (if applicable) Not applicable — build/tooling change only. <!-- This is an auto-generated comment: release notes by coderabbit.ai --> ## Summary by CodeRabbit - **Documentation** - Added contributor setup instructions for installing dependencies before rebuilding feature packages. - Clarified how shared root dependencies are made available to feature sources. - **Chores** - Added project package configuration with a Node.js 24+ requirement. - Added the pinned `chess.js` dependency. - Updated ignore rules to exclude installed Node.js dependencies. <!-- end of auto-generated comment: release notes by coderabbit.ai --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-20 17:31:29 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Pasta-Devs/Marinara-Agents#836
No description provided.