chore(v2): fix yarn2 end2end test by using lerna publish --exact #4613
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.
Motivation
While working on #4582
I noticed a weird failure in the Yarn2 e2e test after I updated init template to use a newly created sidebar item:
https://github.com/facebook/docusaurus/runs/2334693775?check_suite_focus=true
The e2e workflow:
When using Yarn2, it seems like for some weird reasons, it did not download the packages that were just published to Verdaccio, but another canary version from npm instead. Not sure what happens exactly but it seems to be the case for a while, and the CI is probably responsible for a lot of downloads on this particular canary release:
https://www.npmjs.com/package/@docusaurus/core
Using
lerna publish --exact
permits to not use the^
package version prefix and ensure that we always use the package that we just published to Verdaccio, instead of having some kind of fallback to another package from Yarn2.