fix: use a lockfile with the runtime dependency install step #633
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Details
This PR updates our runtime dependency install step to use
yarn install --frozen-lockfile
with the same lockfile we use for builds.Using
--ignore-engines
isn't really ideal, but it's consistent with the old behavior and we probably don't want to force an old node version as long as we're using a composite action and doing so would pollute the calling environment.--ignore-optional
is required to avoid double-installing puppeteer (apify has an optionalDependency on Puppeteer 5.3.0; yarn's default behavior is to install that in addition to our explicit 5.5.0 dependency)Performance seems to be similar between the old strategy and the new:
npm install
shows 25.357syarn install
shows 24.24sMotivation
addresses #632
Context
This is a draft while we validate the perf impact; locally, this is much slower than
npm install
Pull request checklist
yarn test
)<rootDir>/test-results/unit/coverage
yarn precheckin
)Accessibility Checks (pull_request)
check should fail. All other checks should pass.