parcel-bundler / parcel

The zero configuration build tool for the web. πŸ“¦πŸš€
https://parceljs.org
MIT License
43.42k stars 2.26k forks source link

Parcel Serve 2.8.0 randomly crashes while rebuilding #8615

Open roddypratt opened 1 year ago

roddypratt commented 1 year ago

After editing an HTML file and resaving, parcel will occasionally bomb out with the following trace.

Not repeatable, but this never happened with the previous 2.7.0 build.

Server running at http://localhost:1234
\ Building index.html...
node:internal/fs/utils:347
    throw err;
    ^

Error: ENOENT: no such file or directory, unlink 'C:\Rascular\ViewMaster\dist\index.html.2508.m'
    at Object.unlinkSync (node:fs:1767:3)
    at NodeFS.unlinkSync (C:\Rascular\ViewMaster\.pnp.cjs:5919:24)
    at makeCallSync.subPath.subPath (C:\Rascular\ViewMaster\.pnp.cjs:8166:26)
    at ZipOpenFS.makeCallSync (C:\Rascular\ViewMaster\.pnp.cjs:8379:14)
    at ZipOpenFS.unlinkSync (C:\Rascular\ViewMaster\.pnp.cjs:8165:17)
    at VirtualFS.unlinkSync (C:\Rascular\ViewMaster\.pnp.cjs:7463:24)
    at PosixFS.unlinkSync (C:\Rascular\ViewMaster\.pnp.cjs:7463:24)
    at URLFS.unlinkSync (C:\Rascular\ViewMaster\.pnp.cjs:7463:24)
    at WriteStream.<anonymous> (C:\Rascular\ViewMaster\.yarn\__virtual__\@parcel-fs-virtual-99d78ac16b\0\cache\@parcel-fs-npm-2.8.0-30a533924e-75d79963a1.zip\node_modules\@parcel\fs\lib\index.js:1019:83)
    at Object.onceWrapper (node:events:628:26) {
  errno: -4058,
  syscall: 'unlink',
  code: 'ENOENT',
  path: 'C:\\Rascular\\ViewMaster\\dist\\index.html.2508.m'

🌍 Your Environment

Software Version(s)
Parcel 2.8.0
Node 16.18.0
npm/Yarn Yarn 3.2.4
Operating System Windows 11
sKopheK commented 3 months ago

started to use vite instead and it does not suffer from any of the issues described

Groov3 commented 2 months ago

I have this issue on every second save, Node v.18.18.0, Parcel 2.12.0, VSCode, Win 11, latest Chrome.

for anyone who struggling with this, i don't want to spend time to fix parcel, from now i'm just spawning it with pm2 and when parcel fails pm2 restarting it.