Skip to content

refactor: use semver range for @apify/scraper-tools instead of workspace:*#275

Merged
B4nan merged 1 commit intomasterfrom
chore/revert-workspace-refs-in-actors
Apr 30, 2026
Merged

refactor: use semver range for @apify/scraper-tools instead of workspace:*#275
B4nan merged 1 commit intomasterfrom
chore/revert-workspace-refs-in-actors

Conversation

@B4nan
Copy link
Copy Markdown
Member

@B4nan B4nan commented Apr 30, 2026

Summary

After the pnpm migration in #273, each actor's package.json referenced @apify/scraper-tools as workspace:*. The actors are built on Apify via their own Dockerfile (npm install + npm run build), and npm rejects the workspace protocol in a single-package context with EUNSUPPORTEDPROTOCOL. The next manual run of release-generic-actors.yaml would have failed for every scraper.

Reverts the dep specifier on each actor to a regular semver range (^1.1.4, matching the locally-published version). Because pnpm-workspace.yaml has linkWorkspacePackages: true, local development still resolves to the workspace symlink, but the Apify Docker build now sees a normal range it can install from npm.

Verified locally:

  • Workspace linkage preserved (packages/actor-scraper/web-scraper/node_modules/@apify/scraper-tools is a symlink to packages/scraper-tools)
  • npm install against the actor's package.json (simulating Apify's build) now succeeds — added 410 packages in 24s
  • Full pnpm ci:build still passes

…kspace:*

Each actor is built on Apify via its own Dockerfile that runs `npm install`.
npm doesn't support the workspace: protocol in single-package contexts and
fails with EUNSUPPORTEDPROTOCOL when the dep is `workspace:*`.

Revert to the pre-migration pattern of `^1.1.4` (the published npm version,
which matches the local workspace version). With `linkWorkspacePackages: true`
in pnpm-workspace.yaml, local development still gets the workspace symlink;
the Apify build sees a real semver range it can resolve from npm.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@B4nan B4nan changed the title fix(actors): use semver range for @apify/scraper-tools instead of workspace:* refactor: use semver range for @apify/scraper-tools instead of workspace:* Apr 30, 2026
@B4nan B4nan merged commit b1ef2ee into master Apr 30, 2026
4 checks passed
@B4nan B4nan deleted the chore/revert-workspace-refs-in-actors branch April 30, 2026 19:05
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