const net = require('net');
const http = require('http');
const {got} = require('got-cjs');
net.createServer(socket => {
socket.end('HTTP/1.1 200 OK\r\ninvalid header: test\r\n\r\n');
}).listen(8888, async () => {
const stream = got.stream('http://localhost:8888');
stream.pipe(new http.ServerResponse({}));
stream.on('error', () => {
console.log('got error');
});
stream.on('end', () => {
console.log('end!!');
});
});
error
& end
never get emitted.
This line hangs in particular:
Line 346 in d4e34c7
Pay now to fund the work behind this issue.
Get updates on progress being made.
Maintainer is rewarded once the issue is completed.
You're funding impactful open source efforts
You want to contribute to this effort
You want to get funding like this too