Skip to content

Fix temp file ENOENT crash (#8615) #10153

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: v2
Choose a base branch
from

Conversation

Baegus
Copy link

@Baegus Baegus commented May 12, 2025

Fixes #8615

↪️ Pull Request

This should fix a crash that seems to happen to many people, including myself - see issue #8615, #8571 etc.

Full disclosure: I haven't had much success building Parcel and running tests and I really just needed this fixed ASAP, so I just tested this by editing the compiled scripts and then applying the fixes back to the original source file. There might be some issues I'm overlooking, so any help with testing and other necessary steps will be much appreciated. I haven't really seen a good fix anywhere in this repository (that doesn't cause any other issues down the road).

🚨 Test instructions

For me, the original bug happens on Windows using Parcel 2.15.0, while using the Pug preprocessor. All that's needed to crash Parcel is to run a dev script, make a small change to index.pug, save and hot-reload, make another small change, save again and after the 3rd or 4th save, it crashes pretty reliably, throwing the ENOENT error many have described in the mentioned issue. After applying my fix, it does not happen anymore and everything works well.

✔️ PR Todo

  • Added/updated unit tests for this change
  • Filled out test instructions (In case there aren't any unit tests)
  • Included links to related issues/PRs

@devongovett devongovett force-pushed the temp-enoent-crash-fix branch from da37671 to 2400543 Compare May 20, 2025 04:29
@devongovett
Copy link
Member

Thanks. Looks like there are a couple failing tests

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.

Parcel Serve 2.8.0 randomly crashes while rebuilding
2 participants