Skip to content

update pnpm min release - #31

Open
spentacular wants to merge 2 commits into
mainfrom
pnpm-min-release
Open

spentacular wants to merge 2 commits into
mainfrom
pnpm-min-release

Conversation

@spentacular

@spentacular spentacular commented Sep 24, 2026 •

Copy link
Copy Markdown
Member

What's changing

Adds a new pnpm-workspace.yaml carrying a minimum release age gate, so newly published versions of third-party dependencies aren't resolved until they've been on the registry for a while:

minimumReleaseAge: 4320 # 3 days
minimumReleaseAgeExclude:
  - "@player-cli/*"
  - "@player-lang/*"
  - "@xlr-lib/*"

This repo had no pnpm-workspace.yaml before, so the file is created solely to hold these settings.

Why

minimumReleaseAge is pnpm's mitigation for npm supply-chain attacks. Compromised package versions are typically published, detected, and unpublished/patched within hours — so refusing to install anything younger than a cooldown window means the malicious version is usually gone before we'd ever resolve it. This is the same class of defense that blunted the recent Shai-Hulud-style campaigns.

4320 minutes (3 days) is a deliberately conservative window — longer than pnpm 11's 24-hour default, since this repo's dependency updates aren't time-sensitive.

The excluded scopes are our own first-party packages. Without the exclusion, every Player release would sit behind a 3-day wait before this repo could consume it, which would make canary and next verification impractical. minimumReleaseAgeExclude supports glob patterns as of pnpm v10.17.0.

Notes for reviewers

Three things worth confirming before merge — none is addressed by this diff:

  1. pnpm version is unpinned. Unlike the sibling repos, package.json here declares neither packageManager nor engines.pnpm, so whatever pnpm the developer or CI happens to run decides whether this gate applies at all. minimumReleaseAge / minimumReleaseAgeExclude require pnpm v10.16.0+, and glob support in the exclude list landed in v10.17.0. Pinning packageManager to a version at or above v10.17.0 would make this setting deterministic rather than incidental.

  2. The exclude list doesn't match this repo's first-party deps. This is the biggest mismatch of the set. browser-devtools depends on @player-tools/* (devtools-client, devtools-types) and @player-ui/* (react, pubsub-plugin) — and neither scope is excluded, while all three scopes that are excluded (@player-cli, @player-lang, @xlr-lib) appear nowhere in this repo's lockfile. As written, once the gate is live it would apply the full 3-day wait to exactly the first-party packages this repo consumes, and exempt nothing. The list should likely be @player-tools/* and @player-ui/*, or the fuller five-scope list used in player-ui/ptr#10.

  3. No packages: key. The new file contains only these two settings. That's valid — this repo isn't a pnpm workspace — but it does mean the filename is now doing double duty as plain pnpm config.

Unlike most of the sibling repos, this one isn't Bazel-based, so the gate applies directly to normal pnpm install / pnpm update resolution.

Relevant PNPM docs

Change Type (required)

Indicate the type of change your pull request is:

  • patch
  • minor
  • major

@spentacular spentacular added the patch Increment the patch version when merged label Sep 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

patch Increment the patch version when merged

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant