Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: upgrade to yarn v4 #7230

Merged
merged 1 commit into from
Jun 7, 2024
Merged

chore: upgrade to yarn v4 #7230

merged 1 commit into from
Jun 7, 2024

Conversation

chriswk
Copy link
Member

@chriswk chriswk commented May 31, 2024

Outdated as of 2020

This has been on our TODO list for a long time, I guess using v6 as a linchpin to finally do it isn't too bad. This is an initial attempt just following official step-by-step on yarn's homepage.

Copy link

vercel bot commented May 31, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
unleash-docs ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 7, 2024 9:06am
unleash-monorepo-frontend ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jun 7, 2024 9:06am

@chriswk chriswk self-assigned this May 31, 2024
Copy link
Contributor

github-actions bot commented May 31, 2024

Dependency Review

The following issues were found:

  • ✅ 0 vulnerable package(s)
  • ❌ 2 package(s) with incompatible licenses
  • ✅ 0 package(s) with invalid SPDX license definitions
  • ⚠️ 4 package(s) with unknown licenses.
  • ⚠️ 23 packages with OpenSSF Scorecard issues.

View full job summary

@@ -70,5 +74,6 @@
"react-router": "6.23.1",
"replace-in-file": "7.2.0",
"typescript": "4.8.4"
}
},
"packageManager": "[email protected]"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we want to do @4 here in case there's a vulnerability and a patch release?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's a fair question, but the regex validator here requires an absolute version. Though, you're allowed to do ^4.2.2 I believe.

@@ -50,9 +50,9 @@ jobs:
YARN_1="yarn --mutex network --cwd ./current"
YARN_2="yarn --mutex network --cwd ./main"

$YARN_1 install --ignore-scripts &> /dev/null && $YARN_1 build:backend --strictNullChecks true 2> .stderr-current > .out-current &
$YARN_1 install &> /dev/null && $YARN_1 build:backend --strictNullChecks true 2> .stderr-current > .out-current &
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can ignore this file as it's not working as intended... although we could test if running it with yarn 4 fixes it 🤔

.github/workflows/publish-new-version.yaml Show resolved Hide resolved
.yarn/install-state.gz Outdated Show resolved Hide resolved
@@ -17,5 +17,5 @@ jobs:
uses: actions/dependency-review-action@v4
with:
fail-on-severity: moderate
allow-licenses: Apache-2.0, MIT, BSD-2-Clause, BSD-3-Clause, ISC, CC0-1.0, Unlicense
allow-licenses: Apache-2.0, MIT, BSD-2-Clause, BSD-3-Clause, ISC, CC0-1.0, Unlicense, Null, BlueOak-1.0.0
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems like adding Null here is making the action fail. Maybe an alternative solution is to add jackspeak to allow-dependencies-licenses.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hmm, good catch, it seemed like Null was a license ID, but looking at the license list, that's a non-existing identifier. Will update.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done. Thanks for pointing it out.

@chriswk
Copy link
Member Author

chriswk commented Jun 7, 2024

I see the dependency review still failing. this is due to the spdx parser not handling packages with dual licensing (Apache 2.0 OR MIT, APACHE 2.0 AND MIT) even if we allow both licenses. There are PRs happening which will fix this, so hopefully it gets merged soon actions/dependency-review-action#719

Copy link
Member

@nunogois nunogois left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job with this, I vote we try it out 👍

@chriswk chriswk merged commit 15726cc into main Jun 7, 2024
14 of 15 checks passed
@chriswk chriswk deleted the chore/yarnv4 branch June 7, 2024 12:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

4 participants