James Pinkerton
James Pinkerton

Reputation: 161

Poloniex Push WAMP API through Autobahn dropping connection to peer tcp

I tried to connect to the Push API in poloniex using python and followed the instructions on the answer here:

How to connect to poloniex.com websocket api using a python library

However I keep getting this error:

2017-06-25T04:07:04 dropping connection to peer tcp:104.20.13.48:443 with abort=True: WebSocket opening handshake timeout (peer did not finish the opening handshake in time)

Anyone know what's going on here? I can't figure it out from online documentation. Thanks!

Upvotes: 5

Views: 739

Answers (1)

Ad Hero
Ad Hero

Reputation: 51

As per @Cyphrags suggestion, I was able to get my autobahn websocket to work outside of localhost by increasing openHandshakeTimeout with factory.setProtocolOptions

factory.protocol = MyClientProtocol factory.setProtocolOptions(failByDrop=False, openHandshakeTimeout=90, closeHandshakeTimeout=5)

Solution found via https://github.com/crossbario/crossbar/issues/930. Perhaps the reason it is needed has something to do with slow DNS routing taking longer than the default handshake time.

Upvotes: 0

Related Questions