mirror of
https://github.com/pnpm/pnpm.git
synced 2026-04-06 00:06:06 -04:00
The ENOTSUP fallback in createClonePkg() silently converted clone failures to file copies, preventing the auto-importer from detecting that cloning is not supported and falling through to hardlinks. On filesystems without reflink support (e.g. ext4 on Linux CI), this caused every file to be copied instead of hardlinked — a 2-9x regression for install operations on large projects. The fix uses a raw clone (without ENOTSUP fallback) for the auto-mode probe. If the filesystem doesn't support cloning, the error propagates and the auto-importer falls through to hardlinks. Once cloning is confirmed to work, subsequent packages use the full clone importer with ENOTSUP fallback for transient failures under heavy parallel I/O.