You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(npm): detect pnpm node-linker=pnp trees as pnpm
pnpm's own PnP mode (node-linker=pnp in .npmrc) writes a .pnp.cjs
loader at the project root just like yarn-berry does, but keeps real
package directories in the pnpm virtual store — exactly the layout
the CoW guard patches natively. The detector returned YarnBerryPnP
for ANY PnP marker, so `apply` refused outright and told the user to
run `yarn patch` in a pnpm repo; the vendored probe had the same hole
one layer down and refused with vendor_yarn_berry_unsupported.
Add a shared carve-out (pnpm_pnp_layout): a PnP marker with
pnpm-lock.yaml, an installed pnpm store, and NO yarn.lock classifies
as pnpm, so `apply` proceeds under the CoW guard. Anything ambiguous
(yarn.lock alongside, or a stale pnpm-lock.yaml with no installed
store) keeps the fail-closed yarn-berry refusal. Vendored mode still
refuses on such trees — the file: rewiring has no fixtures under
pnpm's PnP linker — but now with its own code
(vendor_pnpm_pnp_unsupported) and a pnpm remedy: use
`scan --mode hosted` or switch node-linker and reinstall.
Un-ignores the RED test pnpm_pnp_mode_is_pnpm_not_yarn_berry and adds
vendored-probe twins for the pnpm refusal and both ambiguity guards.
Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
0 commit comments