chore: Upgrade Yarn from 4.12.0 to 4.17.1 - #41510
Conversation
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
|
Looks like this PR is ready to merge! 🎉 |
|
/jira ARCH-2200 |
|
WalkthroughThe repository updates its Yarn toolchain from 4.12.0 to 4.17.1 across Yarn configuration and package metadata, and enables approved Git repositories, install scripts, and zero-day npm package age gating. ChangesYarn toolchain update
Estimated code review effort: 1 (Trivial) | ~5 minutes Suggested labels: Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In @.yarnrc.yml:
- Around line 1-2: Replace the wildcard value in approvedGitRepositories with
explicit HTTPS and SSH URL patterns covering only the trusted repositories or
organizations. Preserve the allowlist configuration while removing the
unrestricted "**" entry.
- Around line 12-16: Update the Yarn configuration to remove the global
enableScripts: true and npmMinimalAgeGate: 0 settings. Keep install scripts and
the release-age protection enabled by default, and express any required
package-specific exceptions through scoped dependenciesMeta entries with a
nonzero npmMinimalAgeGate.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Organization UI
Review profile: CHILL
Plan: Pro
Run ID: 739ec3e7-eaaa-4e63-b408-68c429898c49
⛔ Files ignored due to path filters (3)
.yarn/releases/yarn-4.12.0.cjsis excluded by!**/.yarn/**.yarn/releases/yarn-4.17.1.cjsis excluded by!**/.yarn/**yarn.lockis excluded by!**/yarn.lock,!**/*.lock
📒 Files selected for processing (2)
.yarnrc.ymlpackage.json
📜 Review details
⏰ Context from checks skipped due to timeout. (5)
- GitHub Check: 📦 Build Packages
- GitHub Check: cubic · AI code reviewer
- GitHub Check: Hacktron Security Check
- GitHub Check: CodeQL-Build
- GitHub Check: CodeQL-Build
🧰 Additional context used
🧠 Learnings (2)
📚 Learning: 2026-03-23T19:33:43.067Z
Learnt from: cardoso
Repo: RocketChat/Rocket.Chat PR: 39818
File: apps/meteor/client/hooks/usePruneWarningMessage.ts:45-56
Timestamp: 2026-03-23T19:33:43.067Z
Learning: In Rocket.Chat, cron expressions used for the retention policy (e.g., `RetentionPolicy_Advanced_Precision_Cron`) follow the `cron` npm package convention, which uses **0-indexed months** (0 = January, 11 = December) rather than POSIX-style 1–12. In `apps/meteor/client/hooks/usePruneWarningMessage.ts`, the local `sendAt` logic intentionally mirrors this behavior—do **not** adjust `date.getMonth()` with `+1` or similar changes, because it will break tests and introduce inconsistency with the backend.
Applied to files:
.yarnrc.yml
📚 Learning: 2026-04-23T18:14:22.005Z
Learnt from: d-gubert
Repo: RocketChat/Rocket.Chat PR: 39857
File: apps/meteor/app/lib/server/lib/debug.js:87-91
Timestamp: 2026-04-23T18:14:22.005Z
Learning: In apps/meteor/app/lib/server/lib/debug.js, do not flag a missing try/finally around the `wrapMethods` timing calls (`end()` / `endHistogram()`) as a bug. These timer calls are intentionally placed after `await originalHandler.apply(this, originalArgs)` because method-handler errors are handled by the higher-level route-handler action wrapper in apps/meteor/app/api/server/ApiClass.ts (around lines 892-893), which converts thrown errors into proper response objects and preserves the intended execution flow.
Applied to files:
.yarnrc.yml
🔇 Additional comments (1)
package.json (1)
206-213: LGTM!
There was a problem hiding this comment.
All reported issues were addressed across 5 files
Reply with feedback, questions, or to request a fix.
Re-trigger cubic
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## develop #41510 +/- ##
===========================================
- Coverage 68.69% 68.66% -0.04%
===========================================
Files 4134 4134
Lines 160417 160417
Branches 29312 29237 -75
===========================================
- Hits 110205 110154 -51
- Misses 45104 45146 +42
- Partials 5108 5117 +9
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
Proposed changes (including videos or screenshots)
Upgrades Yarn from 4.12.0 to 4.17.1, updating the pinned
yarnPath,packageManager,engines.yarnandvolta.yarnfields accordingly, plus regeneratingyarn.lock(lockfile format bumped from v8 to v10).Issue(s)
Steps to test or reproduce
yarn installand confirm it succeeds using the new Yarn release.Further comments
Task: ARCH-2290
Summary by CodeRabbit