Skip to content

Enforce 7-day cooldown for npm packages too#3

Open
interworks-morr wants to merge 1 commit into
mainfrom
fix/npm-7-day-cooldown
Open

Enforce 7-day cooldown for npm packages too#3
interworks-morr wants to merge 1 commit into
mainfrom
fix/npm-7-day-cooldown

Conversation

@interworks-morr

Copy link
Copy Markdown

Problem

The top-level minimumReleaseAge: "7 days" in this preset is not being applied to npm packages. It's silently overridden down to 3 days for everything from npm.

Why: this preset extends config:best-practices, which bundles security:minimumReleaseAgeNpm"Wait until the npm package is three days old before raising the update." That's a packageRule (matchDatasources: ["npm"]minimumReleaseAge: "3 days"), and packageRules override top-level config for matching packages. So:

  • Top-level 7 days → effectively applies only to non-npm datasources.
  • npm packages → 3 days.

This surfaced in internal-deployment: prettier 3.8.4 (published 2026-06-09) had a PR raised at 3 days old (2026-06-12), with Renovate's stability check reporting "met minimum release age requirement" — because the effective npm cooldown was 3 days, not 7.

Fix

Append an npm packageRule (after config:best-practices, so it wins) restoring the 7-day cooldown for npm:

{
  "matchDatasources": ["npm"],
  "minimumReleaseAge": "7 days"
}

After this, npm dependencies wait the full 7 days, matching the intent of the top-level setting. Non-npm datasources are unaffected (still 7 days via top-level).

Verification

Once merged, the next Renovate run on consuming repos should hold npm updates younger than 7 days (visible as "Pending Status Checks" on their dependency dashboards) rather than raising PRs at 3 days.

🤖 Generated with Claude Code

config:best-practices bundles security:minimumReleaseAgeNpm, which sets
minimumReleaseAge to 3 days for npm via a packageRule. Because packageRules
override top-level config, that 3-day rule was silently overriding the
intended top-level minimumReleaseAge of 7 days for every npm dependency
(e.g. prettier PRs were raised at 3 days old).

Add a trailing npm packageRule restoring the 7-day cooldown for npm too.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant