I have to use your https-proxy-agent npm package instead of this package.
I found that this npm package use RFC 7230 - HTTP/1.1: Message Syntax and Routing (proxy server emit request event) to handle ws:// (I am not sure if wss:// has the same problem),
your https-proxy-agent npm package use RFC 7231 - HTTP/1.1: Semantics and Content (proxy server emit connect event).
I have to use your https-proxy-agent npm package instead of this package. I found that this npm package use RFC 7230 - HTTP/1.1: Message Syntax and Routing (proxy server emit request event) to handle ws:// (I am not sure if wss:// has the same problem), your https-proxy-agent npm package use RFC 7231 - HTTP/1.1: Semantics and Content (proxy server emit connect event).