{
error: {
message: Invalid WebSocket frame: invalid status code 1,
name: RangeError,
stack:
RangeError: Invalid WebSocket frame: invalid status code 1
at Receiver.controlMessage (/home/bitnami/dice-test/node_modules/ws/lib/receiver.js:464:18)
at Receiver.getData (/home/bitnami/dice-test/node_modules/ws/lib/receiver.js:350:42)
at Receiver.startLoop (/home/bitnami/dice-test/node_modules/ws/lib/receiver.js:143:22)
at /home/bitnami/dice-test/node_modules/ws/lib/receiver.js:397:12
at /home/bitnami/dice-test/node_modules/ws/lib/permessage-deflate.js:308:9
at /home/bitnami/dice-test/node_modules/ws/lib/permessage-deflate.js:386:7
at afterWrite (_stream_writable.js:490:5)
at onwrite (_stream_writable.js:470:7)
at InflateRaw.afterTransform (_stream_transform.js:98:3)
at Zlib.processCallback (zlib.js:585:8)
},
message: Invalid WebSocket frame: invalid status code 1,
target: {
_binaryType: nodebuffer,
_bufferedAmount: 0,
_closeCode: 1002,
_closeFrameReceived: False,
_closeFrameSent: False,
_closeMessage: ,
_closeTimer: None,
_events: [Object],
_eventsCount: 2,
_extensions: [Object],
_isServer: False,
_maxListeners: [undefined],
_protocol: ,
_readyState: 2,
_receiver: [Object],
_redirects: 0,
_req: None,
_sender: [Object],
_socket: [Object],
_url: wss://fstream.binance.com/ws/aaveusdt@kline_1h
},
type: error
}
I got this error using Binance future WebSocket while fetching kline data