Skip to content

sdkbuild: pass --ignore-scripts to harness pnpm install#813

Merged
brianstrauch merged 4 commits intomainfrom
bump-protobufjs-override-to-7.5.5
May 7, 2026
Merged

sdkbuild: pass --ignore-scripts to harness pnpm install#813
brianstrauch merged 4 commits intomainfrom
bump-protobufjs-override-to-7.5.5

Conversation

@brianstrauch
Copy link
Copy Markdown
Contributor

@brianstrauch brianstrauch commented May 7, 2026

Summary

  • Feature tests are failing on main and on sdk-typescript main after the release of protobuf@7.5.6 last week, with the same error:
    [ERR_PNPM_IGNORED_BUILDS] Ignored build scripts: @swc/core@1.15.33, protobufjs@7.5.5, protobufjs@7.5.6
    
  • The SDK install just above this code already passes --ignore-scripts for the same reason. This change mirrors that for the harness install.
  • The pnpm.overrides/pnpm.onlyBuiltDependencies route does not help — the rejection is a strict-build policy, not a version mismatch (verified empirically: even with onlyBuiltDependencies: ["@swc/core", "protobufjs"] set in the generated package.json, pnpm 10.33.4 in CI still raises ERR_PNPM_IGNORED_BUILDS).

Test plan

  • feature-tests-ts CI passes on this commit (currently broken on main).

@brianstrauch brianstrauch requested review from a team as code owners May 7, 2026 19:14
@brianstrauch brianstrauch force-pushed the bump-protobufjs-override-to-7.5.5 branch from 7da2c69 to 62ddaba Compare May 7, 2026 19:27
@brianstrauch brianstrauch changed the title sdkbuild: bump TS harness protobufjs override to 7.5.5 sdkbuild: whitelist protobufjs and @swc/core install scripts May 7, 2026
pnpm 10.33's strict-builds policy fails the harness install with
ERR_PNPM_IGNORED_BUILDS for any dep with an unapproved install script:

  [ERR_PNPM_IGNORED_BUILDS] Ignored build scripts: \
    @swc/core@1.15.33, protobufjs@7.5.5, protobufjs@7.5.6

Whitelisting via pnpm.onlyBuiltDependencies is the documented escape
hatch. Both packages have shipped install scripts for years; this just
makes pnpm's new strict default explicit for the harness.

The protobufjs version override is left at 7.5.1 — the SDK's protobufjs
patch lives in its own root pnpm.patchedDependencies and never reaches
the harness install, so the version chosen here doesn't materially
affect runtime behavior.
@brianstrauch brianstrauch force-pushed the bump-protobufjs-override-to-7.5.5 branch 2 times, most recently from 873fd68 to 9107b50 Compare May 7, 2026 19:52
@brianstrauch brianstrauch changed the title sdkbuild: whitelist protobufjs and @swc/core install scripts sdkbuild: pass --ignore-scripts to harness pnpm install May 7, 2026
@brianstrauch brianstrauch force-pushed the bump-protobufjs-override-to-7.5.5 branch from 9107b50 to f69065f Compare May 7, 2026 20:00
pnpm 10 fails the harness install with `ERR_PNPM_IGNORED_BUILDS` when
any transitive dep ships an unapproved postinstall script:

  [ERR_PNPM_IGNORED_BUILDS] Ignored build scripts: \
    @swc/core@1.15.33, protobufjs@...

The SDK install just above already passes `--ignore-scripts` for the
same reason; this mirrors that for the harness install.

Tried more targeted alternatives first; none take effect in the GitHub
Actions runner (same configs work locally with the same pnpm 10.33.4):

- `pnpm.onlyBuiltDependencies` in package.json — silently ignored
- `onlyBuiltDependencies` in pnpm-workspace.yaml — silently ignored
- `--config.onlyBuiltDependencies[]=...` CLI override — silently ignored
- `--allow-build` flag — does not exist in pnpm 10

`--ignore-scripts` is the same approach the SDK install already uses
and is the only knob that's been observed to work in CI here.
@brianstrauch brianstrauch force-pushed the bump-protobufjs-override-to-7.5.5 branch from f69065f to 145ac72 Compare May 7, 2026 20:04
Comment thread sdkbuild/typescript.go Outdated
Comment thread sdkbuild/typescript.go
@brianstrauch brianstrauch merged commit 73e53f8 into main May 7, 2026
24 of 26 checks passed
@brianstrauch brianstrauch deleted the bump-protobufjs-override-to-7.5.5 branch May 7, 2026 20:30
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.

2 participants