Skip to content

fix(docs): allow core-js postinstall scripts under pnpm v11#9356

Merged
nflaig merged 1 commit into
ChainSafe:unstablefrom
lodekeeper:fix/pnpm11-docs-strict-builds
May 11, 2026
Merged

fix(docs): allow core-js postinstall scripts under pnpm v11#9356
nflaig merged 1 commit into
ChainSafe:unstablefrom
lodekeeper:fix/pnpm11-docs-strict-builds

Conversation

@lodekeeper
Copy link
Copy Markdown
Contributor

Summary

After the pnpm v11 upgrade (#9299), the Deploy docs workflow fails at the cd docs && pnpm install step with:

ERR_PNPM_IGNORED_BUILDS  Ignored build scripts: core-js-pure@3.36.0, core-js@3.36.0

pnpm v11 defaults strict-dep-builds=true, so any transitive dependency with a postinstall script that isn't explicitly allowed (or denied) in allowBuilds fails the install with exit 1.

The root pnpm-workspace.yaml already declares core-js: true in its allowBuilds map, but docs/ is a separate pnpm project (it has its own pnpm-lock.yaml and its own pnpm-workspace.yaml) and didn't inherit that decision. Docusaurus pulls in both core-js and core-js-pure transitively, so the docs install needs the same allow entries.

This PR adds the matching entries to docs/pnpm-workspace.yaml:

allowBuilds:
  core-js: true
  core-js-pure: true

Verification

Reproduced locally on a fresh worktree at the upstream unstable HEAD with Node 24 + pnpm 11.0.0:

  • Before: cd docs && pnpm install exits 1 with the ERR_PNPM_IGNORED_BUILDS error (matches CI run 25682774486).
  • After: cd docs && pnpm install resolves 1189 packages and exits 0 with no error.

Test plan

  • CI Deploy docs workflow succeeds against this branch.

AI Assistance Disclosure

  • AI-assisted: investigation of the failing Deploy docs run, reproduction of the install error under pnpm 11.0.0, identification of the allowBuilds mechanism mirroring the root pnpm-workspace.yaml, and authoring of the one-file patch. All changes were reviewed before commit.

🤖 Generated with AI assistance

After the pnpm v11 upgrade (ChainSafe#9299), the "Deploy docs" workflow fails
at `cd docs && pnpm install` with:

  ERR_PNPM_IGNORED_BUILDS  Ignored build scripts:
  core-js-pure@3.36.0, core-js@3.36.0

pnpm v11 defaults `strict-dep-builds=true`, so any transitive dep with
a postinstall script that isn't explicitly allowed (or denied) in
`allowBuilds` causes install to exit 1.

The root `pnpm-workspace.yaml` already declares `core-js: true` in its
`allowBuilds` map, but `docs/` is a separate pnpm project (it has its
own `pnpm-lock.yaml` and its own `pnpm-workspace.yaml`) and didn't
inherit that decision. Docusaurus pulls in both `core-js` and
`core-js-pure` transitively.

Add the matching entries to `docs/pnpm-workspace.yaml` to align with
root behavior. Verified locally with pnpm v11.0.0 from `docs/`:
install now resolves 1189 packages and exits 0 with no
ERR_PNPM_IGNORED_BUILDS.

Refs CI failure on commit 59c0680 (run 25682774486 job 75434691391).

🤖 Generated with AI assistance
@lodekeeper lodekeeper requested a review from a team as a code owner May 11, 2026 21:31
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the docs/pnpm-workspace.yaml file to include core-js and core-js-pure in the allowBuilds configuration. The reviewer suggests setting these values to false instead of true to improve installation performance and security, as these post-install scripts are primarily used for informational messages rather than functional build steps.

Comment thread docs/pnpm-workspace.yaml
@nflaig nflaig merged commit a58ad80 into ChainSafe:unstable May 11, 2026
18 of 19 checks passed
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.

3 participants