% NODE_DEBUG=* node client-http.js
MODULE 92544: looking for "/Users/matt/code/replicate-undici-3133/client-http.js" in ["/Users/matt/.node_modules","/Users/matt/.node_libraries","/Users/matt/.nvm/versions/node/v21.7.3/lib/node"]
MODULE 92544: load "/Users/matt/code/replicate-undici-3133/client-http.js" for module "."
MODULE 92544: Module._load REQUEST http parent: .
MODULE 92544: load built-in module http
HTTP 92544: call onSocket 0 0
HTTP 92544: createConnection 127.0.0.1:3000: [Object: null prototype] {
  protocol: 'http:',
  hostname: '127.0.0.1',
  hash: '',
  search: '',
  pathname: '/',
  path: null,
  href: 'http://127.0.0.1:3000/',
  port: 3000,
  host: '127.0.0.1',
  keepAlive: true,
  noDelay: true,
  servername: '',
  _agentKey: '127.0.0.1:3000:'
}
NET 92544: createConnection [
  [Object: null prototype] {
    protocol: 'http:',
    hostname: '127.0.0.1',
    hash: '',
    search: '',
    pathname: '/',
    path: null,
    href: 'http://127.0.0.1:3000/',
    port: 3000,
    host: '127.0.0.1',
    keepAlive: true,
    noDelay: true,
    servername: '',
    _agentKey: '127.0.0.1:3000:',
    encoding: null,
    keepAliveInitialDelay: 1000
  },
  [Function (anonymous)],
  [Symbol(normalizedArgs)]: true
]
NET 92544: pipe false null
HTTP 92544: sockets 127.0.0.1:3000: 1 1
HTTP 92544: outgoing message end.
(node:92544) Warning: Setting the NODE_DEBUG environment variable to 'http' can expose sensitive data (such as passwords, tokens and authentication headers) in the resulting log.
(Use `node --trace-warnings ...` to show where the warning was created)
NET 92544: connect: attempting to connect to 127.0.0.1:3000 (addressType: 4)
STREAM 92544: resume
STREAM 92544: resume false
STREAM 92544: read 0
STREAM 92544: need readable false
STREAM 92544: length less than watermark true
STREAM 92544: do read
NET 92544: _read - n 16384 isConnecting? true hasHandle? true
NET 92544: _read wait for connection
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: need readable true
STREAM 92544: length less than watermark true
STREAM 92544: reading, ended or constructing false
NET 92544: afterConnect
NET 92544: _read - n 16384 isConnecting? false hasHandle? true
NET 92544: Socket._handle.readStart
STREAM 92544: read 0
STREAM 92544: need readable true
STREAM 92544: length less than watermark true
STREAM 92544: reading, ended or constructing false
STREAM 92544: push <Buffer 48 54 54 50 2f 31 2e 31 20 32 30 30 20 4f 4b 0d 0a 43 6f 6e 74 65 6e 74 2d 54 79 70 65 3a 20 61 70 70 6c 69 63 61 74 69 6f 6e 2f 6a 73 6f 6e 0d 0a 44 ... 147 more bytes>
HTTP 92544: AGENT incoming response!
STREAM 92544: resume
STREAM 92544: push <Buffer 7b 22 64 61 74 61 22 3a 22 48 65 6c 6c 6f 20 57 6f 72 6c 64 21 22 7d>
STREAM 92544: push null
STREAM 92544: onEofChunk
STREAM 92544: emitReadable
STREAM 92544: emitReadable true
STREAM 92544: resume false
STREAM 92544: read 0
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: need readable false
STREAM 92544: length less than watermark true
STREAM 92544: reading, ended or constructing false
STREAM 92544: endReadable
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: read 0
STREAM 92544: endReadable
STREAM 92544: emitReadable_
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: maybeReadMore read 0
STREAM 92544: read 0
STREAM 92544: need readable true
STREAM 92544: length less than watermark true
STREAM 92544: do read
NET 92544: _read - n 16384 isConnecting? false hasHandle? true
STREAM 92544: endReadableNT
HTTP 92544: AGENT socket keep-alive
success: 0
TIMER 92544: no 950 list was found in insert, creating a new one
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
HTTP 92544: CLIENT socket onFree
HTTP 92544: agent.on(free) 127.0.0.1:3000:
HTTP 92544: removeSocket 127.0.0.1:3000: writable: true
TIMER 92544: process timer lists 972
TIMER 92544: timeout callback 950
HTTP 92544: have free socket
HTTP 92544: outgoing message end.
TIMER 92544: 950 list empty
STREAM 92544: push <Buffer 48 54 54 50 2f 31 2e 31 20 32 30 30 20 4f 4b 0d 0a 43 6f 6e 74 65 6e 74 2d 54 79 70 65 3a 20 61 70 70 6c 69 63 61 74 69 6f 6e 2f 6a 73 6f 6e 0d 0a 44 ... 147 more bytes>
HTTP 92544: AGENT incoming response!
STREAM 92544: resume
STREAM 92544: push <Buffer 7b 22 64 61 74 61 22 3a 22 48 65 6c 6c 6f 20 57 6f 72 6c 64 21 22 7d>
STREAM 92544: push null
STREAM 92544: onEofChunk
STREAM 92544: emitReadable
STREAM 92544: emitReadable true
STREAM 92544: resume false
STREAM 92544: read 0
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: need readable false
STREAM 92544: length less than watermark true
STREAM 92544: reading, ended or constructing false
STREAM 92544: endReadable
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: read 0
STREAM 92544: endReadable
STREAM 92544: emitReadable_
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: maybeReadMore read 0
STREAM 92544: read 0
STREAM 92544: need readable true
STREAM 92544: length less than watermark true
STREAM 92544: do read
NET 92544: _read - n 16384 isConnecting? false hasHandle? true
STREAM 92544: endReadableNT
HTTP 92544: AGENT socket keep-alive
success: 950
TIMER 92544: no 960 list was found in insert, creating a new one
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
HTTP 92544: CLIENT socket onFree
HTTP 92544: agent.on(free) 127.0.0.1:3000:
HTTP 92544: removeSocket 127.0.0.1:3000: writable: true
TIMER 92544: process timer lists 1939
TIMER 92544: timeout callback 960
HTTP 92544: have free socket
HTTP 92544: outgoing message end.
TIMER 92544: 960 list empty
STREAM 92544: push <Buffer 48 54 54 50 2f 31 2e 31 20 32 30 30 20 4f 4b 0d 0a 43 6f 6e 74 65 6e 74 2d 54 79 70 65 3a 20 61 70 70 6c 69 63 61 74 69 6f 6e 2f 6a 73 6f 6e 0d 0a 44 ... 147 more bytes>
HTTP 92544: AGENT incoming response!
STREAM 92544: resume
STREAM 92544: push <Buffer 7b 22 64 61 74 61 22 3a 22 48 65 6c 6c 6f 20 57 6f 72 6c 64 21 22 7d>
STREAM 92544: push null
STREAM 92544: onEofChunk
STREAM 92544: emitReadable
STREAM 92544: emitReadable true
STREAM 92544: resume false
STREAM 92544: read 0
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: need readable false
STREAM 92544: length less than watermark true
STREAM 92544: reading, ended or constructing false
STREAM 92544: endReadable
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: read 0
STREAM 92544: endReadable
STREAM 92544: emitReadable_
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: maybeReadMore read 0
STREAM 92544: read 0
STREAM 92544: need readable true
STREAM 92544: length less than watermark true
STREAM 92544: do read
NET 92544: _read - n 16384 isConnecting? false hasHandle? true
STREAM 92544: endReadableNT
HTTP 92544: AGENT socket keep-alive
success: 960
TIMER 92544: no 970 list was found in insert, creating a new one
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
HTTP 92544: CLIENT socket onFree
HTTP 92544: agent.on(free) 127.0.0.1:3000:
HTTP 92544: removeSocket 127.0.0.1:3000: writable: true
TIMER 92544: process timer lists 2914
TIMER 92544: timeout callback 970
HTTP 92544: have free socket
HTTP 92544: outgoing message end.
TIMER 92544: 970 list empty
STREAM 92544: push <Buffer 48 54 54 50 2f 31 2e 31 20 32 30 30 20 4f 4b 0d 0a 43 6f 6e 74 65 6e 74 2d 54 79 70 65 3a 20 61 70 70 6c 69 63 61 74 69 6f 6e 2f 6a 73 6f 6e 0d 0a 44 ... 147 more bytes>
HTTP 92544: AGENT incoming response!
STREAM 92544: resume
STREAM 92544: push <Buffer 7b 22 64 61 74 61 22 3a 22 48 65 6c 6c 6f 20 57 6f 72 6c 64 21 22 7d>
STREAM 92544: push null
STREAM 92544: onEofChunk
STREAM 92544: emitReadable
STREAM 92544: emitReadable true
STREAM 92544: resume false
STREAM 92544: read 0
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: need readable false
STREAM 92544: length less than watermark true
STREAM 92544: reading, ended or constructing false
STREAM 92544: endReadable
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: read 0
STREAM 92544: endReadable
STREAM 92544: emitReadable_
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: maybeReadMore read 0
STREAM 92544: read 0
STREAM 92544: need readable true
STREAM 92544: length less than watermark true
STREAM 92544: do read
NET 92544: _read - n 16384 isConnecting? false hasHandle? true
STREAM 92544: endReadableNT
HTTP 92544: AGENT socket keep-alive
success: 970
TIMER 92544: no 980 list was found in insert, creating a new one
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
HTTP 92544: CLIENT socket onFree
HTTP 92544: agent.on(free) 127.0.0.1:3000:
HTTP 92544: removeSocket 127.0.0.1:3000: writable: true
TIMER 92544: process timer lists 3899
TIMER 92544: timeout callback 980
HTTP 92544: have free socket
HTTP 92544: outgoing message end.
TIMER 92544: 980 list empty
STREAM 92544: push <Buffer 48 54 54 50 2f 31 2e 31 20 32 30 30 20 4f 4b 0d 0a 43 6f 6e 74 65 6e 74 2d 54 79 70 65 3a 20 61 70 70 6c 69 63 61 74 69 6f 6e 2f 6a 73 6f 6e 0d 0a 44 ... 147 more bytes>
HTTP 92544: AGENT incoming response!
STREAM 92544: resume
STREAM 92544: push <Buffer 7b 22 64 61 74 61 22 3a 22 48 65 6c 6c 6f 20 57 6f 72 6c 64 21 22 7d>
STREAM 92544: push null
STREAM 92544: onEofChunk
STREAM 92544: emitReadable
STREAM 92544: emitReadable true
STREAM 92544: resume false
STREAM 92544: read 0
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: need readable false
STREAM 92544: length less than watermark true
STREAM 92544: reading, ended or constructing false
STREAM 92544: endReadable
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: read 0
STREAM 92544: endReadable
STREAM 92544: emitReadable_
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: maybeReadMore read 0
STREAM 92544: read 0
STREAM 92544: need readable true
STREAM 92544: length less than watermark true
STREAM 92544: do read
NET 92544: _read - n 16384 isConnecting? false hasHandle? true
STREAM 92544: endReadableNT
HTTP 92544: AGENT socket keep-alive
success: 980
TIMER 92544: no 990 list was found in insert, creating a new one
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
HTTP 92544: CLIENT socket onFree
HTTP 92544: agent.on(free) 127.0.0.1:3000:
HTTP 92544: removeSocket 127.0.0.1:3000: writable: true
TIMER 92544: process timer lists 4895
TIMER 92544: timeout callback 990
HTTP 92544: have free socket
HTTP 92544: outgoing message end.
TIMER 92544: 990 list empty
STREAM 92544: push <Buffer 48 54 54 50 2f 31 2e 31 20 32 30 30 20 4f 4b 0d 0a 43 6f 6e 74 65 6e 74 2d 54 79 70 65 3a 20 61 70 70 6c 69 63 61 74 69 6f 6e 2f 6a 73 6f 6e 0d 0a 44 ... 147 more bytes>
HTTP 92544: AGENT incoming response!
STREAM 92544: resume
STREAM 92544: push <Buffer 7b 22 64 61 74 61 22 3a 22 48 65 6c 6c 6f 20 57 6f 72 6c 64 21 22 7d>
STREAM 92544: push null
STREAM 92544: onEofChunk
STREAM 92544: emitReadable
STREAM 92544: emitReadable true
STREAM 92544: resume false
STREAM 92544: read 0
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: need readable false
STREAM 92544: length less than watermark true
STREAM 92544: reading, ended or constructing false
STREAM 92544: endReadable
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: read 0
STREAM 92544: endReadable
STREAM 92544: emitReadable_
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: maybeReadMore read 0
STREAM 92544: read 0
STREAM 92544: need readable true
STREAM 92544: length less than watermark true
STREAM 92544: do read
NET 92544: _read - n 16384 isConnecting? false hasHandle? true
STREAM 92544: endReadableNT
HTTP 92544: AGENT socket keep-alive
success: 990
TIMER 92544: no 995 list was found in insert, creating a new one
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
HTTP 92544: CLIENT socket onFree
HTTP 92544: agent.on(free) 127.0.0.1:3000:
HTTP 92544: removeSocket 127.0.0.1:3000: writable: true
TIMER 92544: process timer lists 5897
TIMER 92544: timeout callback 995
HTTP 92544: have free socket
HTTP 92544: outgoing message end.
TIMER 92544: 995 list empty
STREAM 92544: push <Buffer 48 54 54 50 2f 31 2e 31 20 32 30 30 20 4f 4b 0d 0a 43 6f 6e 74 65 6e 74 2d 54 79 70 65 3a 20 61 70 70 6c 69 63 61 74 69 6f 6e 2f 6a 73 6f 6e 0d 0a 44 ... 147 more bytes>
HTTP 92544: AGENT incoming response!
STREAM 92544: resume
STREAM 92544: push <Buffer 7b 22 64 61 74 61 22 3a 22 48 65 6c 6c 6f 20 57 6f 72 6c 64 21 22 7d>
STREAM 92544: push null
STREAM 92544: onEofChunk
STREAM 92544: emitReadable
STREAM 92544: emitReadable true
STREAM 92544: resume false
STREAM 92544: read 0
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: need readable false
STREAM 92544: length less than watermark true
STREAM 92544: reading, ended or constructing false
STREAM 92544: endReadable
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: read 0
STREAM 92544: endReadable
STREAM 92544: emitReadable_
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: maybeReadMore read 0
STREAM 92544: read 0
STREAM 92544: need readable true
STREAM 92544: length less than watermark true
STREAM 92544: do read
NET 92544: _read - n 16384 isConnecting? false hasHandle? true
STREAM 92544: endReadableNT
HTTP 92544: AGENT socket keep-alive
success: 995
TIMER 92544: no 995 list was found in insert, creating a new one
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
HTTP 92544: CLIENT socket onFree
HTTP 92544: agent.on(free) 127.0.0.1:3000:
HTTP 92544: removeSocket 127.0.0.1:3000: writable: true
TIMER 92544: process timer lists 6898
TIMER 92544: timeout callback 995
HTTP 92544: have free socket
HTTP 92544: outgoing message end.
TIMER 92544: 995 list empty
STREAM 92544: push <Buffer 48 54 54 50 2f 31 2e 31 20 32 30 30 20 4f 4b 0d 0a 43 6f 6e 74 65 6e 74 2d 54 79 70 65 3a 20 61 70 70 6c 69 63 61 74 69 6f 6e 2f 6a 73 6f 6e 0d 0a 44 ... 147 more bytes>
HTTP 92544: AGENT incoming response!
STREAM 92544: resume
STREAM 92544: push <Buffer 7b 22 64 61 74 61 22 3a 22 48 65 6c 6c 6f 20 57 6f 72 6c 64 21 22 7d>
STREAM 92544: push null
STREAM 92544: onEofChunk
STREAM 92544: emitReadable
STREAM 92544: emitReadable true
STREAM 92544: resume false
STREAM 92544: read 0
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: need readable false
STREAM 92544: length less than watermark true
STREAM 92544: reading, ended or constructing false
STREAM 92544: endReadable
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: read 0
STREAM 92544: endReadable
STREAM 92544: emitReadable_
STREAM 92544: flow
STREAM 92544: read undefined
STREAM 92544: endReadable
STREAM 92544: maybeReadMore read 0
STREAM 92544: read 0
STREAM 92544: need readable true
STREAM 92544: length less than watermark true
STREAM 92544: do read
NET 92544: _read - n 16384 isConnecting? false hasHandle? true
STREAM 92544: endReadableNT
HTTP 92544: AGENT socket keep-alive
success: 995
TIMER 92544: no 996 list was found in insert, creating a new one
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
STREAM 92544: endReadableNT
HTTP 92544: CLIENT socket onFree
HTTP 92544: agent.on(free) 127.0.0.1:3000:
HTTP 92544: removeSocket 127.0.0.1:3000: writable: true
TIMER 92544: process timer lists 7900
TIMER 92544: timeout callback 996
HTTP 92544: have free socket
HTTP 92544: outgoing message end.
TIMER 92544: 996 list empty
NET 92544: destroy
NET 92544: close
NET 92544: close handle
HTTP 92544: SOCKET ERROR: read ECONNRESET Error: read ECONNRESET
    at TCP.onStreamRead (node:internal/stream_base_commons:217:20)
node:events:497
      throw er; // Unhandled 'error' event
      ^

Error: read ECONNRESET
    at TCP.onStreamRead (node:internal/stream_base_commons:217:20)
Emitted 'error' event on ClientRequest instance at:
    at Socket.socketErrorListener (node:_http_client:500:9)
    at Socket.emit (node:events:519:28)
    at emitErrorNT (node:internal/streams/destroy:169:8)
    at emitErrorCloseNT (node:internal/streams/destroy:128:3)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21) {
  errno: -54,
  code: 'ECONNRESET',
  syscall: 'read'
}

Node.js v21.7.3