-
-
Notifications
You must be signed in to change notification settings - Fork 241
Closed
Labels
Description
This can be reproduced with:
execa('echo', { input: 'test' })
node:internal/process/promises:246
triggerUncaughtException(err, true /* fromPromise */);
^
Error: write EPIPE
at afterWriteDispatched (node:internal/stream_base_commons:164:15)
at writeGeneric (node:internal/stream_base_commons:155:3)
at Socket._writeGeneric (node:net:780:11)
at Socket._write (node:net:792:8)
at writeOrBuffer (node:internal/streams/writable:389:12)
at _write (node:internal/streams/writable:330:10)
at Socket.Writable.end (node:internal/streams/writable:609:17)
at Socket.end (node:net:594:31)
at handleInput (/home/ether/code/nve/node_modules/execa/lib/stream.js:17:17)
at execa (/home/ether/code/nve/node_modules/execa/index.js:156:2) {
errno: -32,
code: 'EPIPE',
syscall: 'write'
}
This happens when the child process is too fast to finish. When this happens, Execa writes to the process stdin
while it has already ended, which creates an EPIPE
error.
Discussion about this happening at nodejs/node#40085
xmedeko