Skip to content

fix: drop only-allow preinstall, enforce pnpm via devEngines#1129

Merged
B4nan merged 1 commit into
masterfrom
fix/drop-only-allow-preinstall
May 11, 2026
Merged

fix: drop only-allow preinstall, enforce pnpm via devEngines#1129
B4nan merged 1 commit into
masterfrom
fix/drop-only-allow-preinstall

Conversation

@B4nan
Copy link
Copy Markdown
Member

@B4nan B4nan commented May 11, 2026

The preinstall: npx only-allow pnpm script ships in the published npm tarball and fires when downstream consumers install apify-cli via npm. In the npm install -g apify-cli flow the npx bootstrap of only-allow fails to put the binary on PATH in time:

  • Linux: sh: 1: only-allow: not found (exit 127)
  • Windows: 'only-allow' is not recognized as an internal or external command (exit 1)

This was the user-visible symptom that first surfaced the bug (apify/apify-client-js#893).

Adds devEngines.packageManager (pnpm@10.33.0, onFail: "warn") alongside the existing devEngines.runtime. onFail: "warn" avoids tripping CI steps that indirectly invoke npm (pnpm v10 shells to npm for pnpm version, pnpm config, etc.).

devEngines is only checked at the package's own repo root, never on transitive installs, so downstream consumers stay unaffected.

Mirrors apify/apify-client-js#895 + #896 and apify/apify-sdk-js#606. Patch release needed after merge.

@B4nan B4nan requested a review from vladfrangu as a code owner May 11, 2026 13:55
@github-actions github-actions Bot added this to the 140th sprint - Tooling team milestone May 11, 2026
@github-actions github-actions Bot added the t-tooling Issues with this label are in the ownership of the tooling team. label May 11, 2026
@B4nan B4nan added the adhoc Ad-hoc unplanned task added during the sprint. label May 11, 2026
The "preinstall": "npx only-allow pnpm" script ships in the published
npm tarball and fires when downstream consumers install apify-cli via
npm. In the `npm install -g apify-cli` flow the npx bootstrap of
only-allow fails to put the binary on PATH in time, breaking the
global install (exit 127 on Linux, exit 1 on Windows). The apify-cli
issue was the user-visible symptom that first surfaced this bug.

Adds devEngines.packageManager (pnpm@10.33.0, onFail:warn) alongside
the existing devEngines.runtime so local devs still get the visible
"use pnpm" signal. onFail:warn (not error) avoids tripping CI steps
that indirectly invoke npm (pnpm v10 shells to npm for `pnpm version`,
`pnpm config`, etc.).

devEngines is checked at the package's own repo root, never on
transitive installs, so downstream consumers are unaffected.

Mirrors apify/apify-client-js#895 + #896 and apify/apify-sdk-js#606.
@B4nan B4nan force-pushed the fix/drop-only-allow-preinstall branch from bd7fcb5 to ffa6579 Compare May 11, 2026 14:35
@B4nan B4nan merged commit 19f0c2d into master May 11, 2026
24 checks passed
@B4nan B4nan deleted the fix/drop-only-allow-preinstall branch May 11, 2026 14:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

adhoc Ad-hoc unplanned task added during the sprint. t-tooling Issues with this label are in the ownership of the tooling team.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants