Skip to content

fix(npm): inherit global minimal age gate in scopes#7214

Open
ychampion wants to merge 1 commit into
yarnpkg:masterfrom
ychampion:fix-npm-scope-age-gate
Open

fix(npm): inherit global minimal age gate in scopes#7214
ychampion wants to merge 1 commit into
yarnpkg:masterfrom
ychampion:fix-npm-scope-age-gate

Conversation

@ychampion

Copy link
Copy Markdown

What's the problem this PR addresses?

Resolves #7192.

Scoped npmMinimalAgeGate entries currently get their own default of 1d, so an unset scoped gate doesn't fall back to the global npmMinimalAgeGate. That makes npmMinimalAgeGate: 0 ineffective for scoped packages unless every scope repeats the same value.

How did you fix it?

Scoped npmMinimalAgeGate now defaults to null, which lets the existing npm helper fall back to the global setting unless a scope explicitly sets its own gate.

The regression covers both the config output from the issue and the scoped install behavior when the global gate is disabled.

Validation

  • yarn build:cli
  • yarn test:integration npmMinimalAgeGate
  • yarn typecheck:all
  • yarn test:lint
  • yarn constraints
  • yarn version check
  • git diff --check

Checklist

  • I have read the Contributing Guide.
  • I have set the packages that need to be released for my changes to be effective.
  • I will check that all automated PR checks pass before the PR gets reviewed.

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.

[Bug?]: Disabling global npmMinimalAgeGate does not disable scoped npmMinimalAgeGate

1 participant