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

Upgrade to Yarn v4 #289

Merged
merged 1 commit into from
Dec 5, 2024
Merged

Upgrade to Yarn v4 #289

merged 1 commit into from
Dec 5, 2024

Conversation

mcmire
Copy link
Contributor

@mcmire mcmire commented Dec 4, 2024

This commit aligns this repo more closely with our module template.

  • Add packageManager to package.json
  • Add allow-scripts Yarn plugin
  • Add Yarn constraints (but modified to suit this package, whose build pipeline is not fully standardized with the module template)
  • Remove setup script (since allow-scripts gets called automatically now)
  • Replace prepublishOnly script with prepack
  • Update GitHub workflow to install Yarn via Corepack
  • Update Yarn-specific section of .gitignore
  • Update installation instructions in README
  • Upgrade eslint-plugin-jsdoc as the version we were using was previously not compatible with the version of Node we are using, but Yarn v1 did not pick this up. Fix lint violations to match.

Closes #285.

Copy link

socket-security bot commented Dec 4, 2024

New and removed dependencies detected. Learn more about Socket for GitHub ↗︎

Package New capabilities Transitives Size Publisher
npm/@babel/[email protected] None 0 31.8 kB existentialism, hzoo, jlhwung, ...1 more
npm/@babel/[email protected] None 0 48.3 kB nicolo-ribaudo
npm/@es-joy/[email protected] None 0 71.4 kB brettz9
npm/@isaacs/[email protected] None +6 171 kB isaacs
npm/@npmcli/[email protected] environment, network +5 936 kB npm-cli-ops
npm/@pkgjs/[email protected] None 0 74.2 kB oss-bot
npm/@yarnpkg/[email protected] None +1 99.2 kB yarnbot
npm/[email protected] None 0 13.6 kB joshuakgoldberg
npm/[email protected] environment, filesystem, shell 0 16.1 kB satazor
npm/[email protected] None 0 13.6 kB komagata
npm/[email protected] None +1 1.72 MB gajus
npm/[email protected] None 0 1.04 MB michaelficarra
npm/[email protected] None 0 37.3 kB sssayegh
npm/[email protected] shell 0 69 kB isaacs
npm/[email protected] None 0 177 kB beaugunderson
npm/[email protected] environment 0 297 kB isaacs
npm/[email protected] None 0 46.9 kB andyperlitch
npm/[email protected] None 0 242 kB jsdoc-type-pratt-parser
npm/[email protected] None 0 36.5 kB isaacs
npm/[email protected] filesystem 0 535 kB isaacs
npm/[email protected] network 0 156 kB joshglazebrook
npm/[email protected] None 0 39.9 kB alexei
npm/[email protected] None 0 0 B
npm/[email protected] None 0 0 B
npm/[email protected] None 0 0 B

🚮 Removed packages: npm/@babel/[email protected], npm/@babel/[email protected], npm/@es-joy/[email protected], npm/[email protected], npm/[email protected], npm/[email protected], npm/[email protected], npm/[email protected], npm/[email protected], npm/[email protected]

View full report↗︎

Copy link

socket-security bot commented Dec 4, 2024

👍 Dependency issues cleared. Learn more about Socket for GitHub ↗︎

This PR previously contained dependency changes with security issues that have been resolved, removed, or ignored.

Ignoring: npm/[email protected], npm/[email protected], npm/[email protected], npm/@npmcli/[email protected], npm/[email protected]

View full report↗︎

Next steps

Take a deeper look at the dependency

Take a moment to review the security alert above. Review the linked package source code to understand the potential risk. Ensure the package is not malicious before proceeding. If you're unsure how to proceed, reach out to your security team or ask the Socket team for help at support [AT] socket [DOT] dev.

Remove the package

If you happen to install a dependency that Socket reports as Known Malware you should immediately remove it and select a different dependency. For other alert types, you may may wish to investigate alternative packages or consider if there are other ways to mitigate the specific risk posed by the dependency.

Mark a package as acceptable risk

To ignore an alert, reply with a comment starting with @SocketSecurity ignore followed by a space separated list of ecosystem/package-name@version specifiers. e.g. @SocketSecurity ignore npm/[email protected] or ignore all packages with @SocketSecurity ignore-all

@mcmire mcmire force-pushed the upgrade-to-yarn-v4 branch 2 times, most recently from aeeb31d to c3a6f44 Compare December 4, 2024 19:59
@mcmire
Copy link
Contributor Author

mcmire commented Dec 4, 2024

@SocketSecurity ignore npm/[email protected]
@SocketSecurity ignore npm/@npmcli/[email protected]
@SocketSecurity ignore npm/[email protected]

These are indirect dependencies of Jest.

@mcmire
Copy link
Contributor Author

mcmire commented Dec 4, 2024

@SocketSecurity ignore npm/[email protected]
@SocketSecurity ignore npm/[email protected]

These are also indirect dependencies of Jest.

@mcmire mcmire force-pushed the upgrade-to-yarn-v4 branch 2 times, most recently from 8a4f1af to 5f2af88 Compare December 4, 2024 20:05
- Add `packageManager` to `package.json`
- Add `allow-scripts` Yarn plugin
- Add Yarn constraints (but modified to suit this package, whose build
  pipeline is not fully standardized with the module template)
- Remove `setup` script (since `allow-scripts` gets called automatically
  now)
- Replace `prepublishOnly` script with `prepack`
- Update GitHub workflow to install Yarn via Corepack
- Update Yarn-specific section of `.gitignore`
- Update installation instructions in README
- Upgrade `eslint-plugin-jsdoc` as the version we were using was
  previously not compatible with the version of Node we are using, but
  Yarn v1 did not pick this up. Fix lint violations to match.
@mcmire mcmire force-pushed the upgrade-to-yarn-v4 branch from 5f2af88 to d9b814f Compare December 4, 2024 20:12
@mcmire mcmire marked this pull request as ready for review December 4, 2024 20:16
@mcmire mcmire requested a review from a team as a code owner December 4, 2024 20:16
@mcmire mcmire self-assigned this Dec 4, 2024
Copy link
Member

@mikesposito mikesposito left a comment

Choose a reason for hiding this comment

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

LGTM!

@mcmire mcmire merged commit 95f269e into main Dec 5, 2024
8 checks passed
@mcmire mcmire deleted the upgrade-to-yarn-v4 branch December 5, 2024 15:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Upgrade Yarn from v1 to v4
2 participants