Skip to main content

pnpm 10.31

· 2 min read
Zoltan Kochan
Lead maintainer of pnpm

pnpm 10.31 在更新 pnpm-workspace.yaml 时会保留注释和格式,并包含众多错误修复。

🌐 pnpm 10.31 preserves comments and formatting when updating pnpm-workspace.yaml, and includes numerous bug fixes.

小幅更改

🌐 Minor Changes

pnpm-workspace.yaml 中保留注释

🌐 Preserving Comments in pnpm-workspace.yaml

当 pnpm 更新 pnpm-workspace.yaml 时,注释、字符串格式和空白将被保留。

🌐 When pnpm updates the pnpm-workspace.yaml, comments, string formatting, and whitespace will be preserved.

补丁更改

🌐 Patch Changes

  • Added -F as a short alias for the --filter option in the help output.

  • Handle undefined pkgSnapshot in pnpm why -r #10700.

  • Fix headless install not being used when a project has an injected self-referencing file: dependency that resolves to link: in the lockfile.

  • Fixed a race condition when multiple worker threads import the same package to the global virtual store concurrently. The rename operation now tolerates ENOTEMPTY/EEXIST errors if another thread already completed the import.

  • When lockfile-include-tarball-url is set to false, tarball URLs are now always excluded from the lockfile. Previously, tarball URLs could still appear for packages hosted under non-standard URLs #6667.

  • Fixed optimisticRepeatInstall skipping install when overrides, packageExtensions, ignoredOptionalDependencies, patchedDependencies, or peersSuffixMaxLength changed.

  • Fixed pnpm patch-commit failing with "unable to access '/.config/git/attributes': Permission denied" error in environments where HOME is unset or non-standard (Docker containers, CI systems) #6537.

  • Fix pnpm why -r --parseable missing dependents when multiple workspace packages share the same dependency #8100.

  • Fix link-workspace-packages=true incorrectly linking workspace packages when the requested version doesn't match the workspace package's version #10173.

  • Fixed pnpm update --interactive table breaking with long version strings by dynamically calculating column widths instead of using hardcoded values #10316.

  • The parameter set by the --allow-build flag is written to allowBuilds.

  • Fix a bug in which specifying filter on pnpm-workspace.yaml would cause pnpm to not detect any projects.

  • Print help message on running pnpm dlx without arguments and exit.