Skip to content

chore(rspack): remove pid in virtual path when unnecessary#549

Merged
sxzz merged 1 commit intounjs:mainfrom
elbywan:chore/rspack-remove-virtual-pid
Oct 13, 2025
Merged

chore(rspack): remove pid in virtual path when unnecessary#549
sxzz merged 1 commit intounjs:mainfrom
elbywan:chore/rspack-remove-virtual-pid

Conversation

@elbywan
Copy link
Contributor

@elbywan elbywan commented Oct 13, 2025

👋 A small follow-up to:

Basically a very simple gate to prevent inserting the process.pid() when the native virtual plugin is used, the rationale is:

  • the native plugin writes virtual files in memory, so there should not be cross-process fs concurrency issues and the pid prefix is unnecessary
  • the pid changes for every compilation, defeating long term caching strategies relying on the content hash

@pkg-pr-new
Copy link

pkg-pr-new bot commented Oct 13, 2025

Open in StackBlitz

npm i https://pkg.pr.new/unjs/unplugin@549

commit: c6341b2

@sxzz sxzz merged commit 5fe9a46 into unjs:main Oct 13, 2025
15 checks passed
@elbywan elbywan deleted the chore/rspack-remove-virtual-pid branch October 13, 2025 19:52
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.

2 participants