ReadTimeoutError in KiteConnect

rajeevr
@sujith
I'm trying to place orders at market open. They were going fine until yesterday, today I got a readtimeout exception. It looks like the problem is in connect.py. Can someone look at it.

The whole error message I received is:

The current time is: 2018-06-04 09:15:07.528775
Staring strategy
Unhandled Error
Traceback (most recent call last):
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/twisted/python/log.py", line 103, in callWithLogger
return callWithContext({"system": lp}, func, *args, **kw)
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/twisted/python/log.py", line 86, in callWithContext
return context.call({ILogContext: newCtx}, func, *args, **kw)
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/twisted/python/context.py", line 122, in callWithContext
return self.currentContext().callWithContext(ctx, func, *args, **kw)
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/twisted/python/context.py", line 85, in callWithContext
return func(*args,**kw)
--- ---
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/twisted/internet/selectreactor.py", line 149, in _doReadOrWrite
why = getattr(selectable, method)()
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/twisted/internet/tcp.py", line 205, in doRead
return self._dataReceived(data)
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/twisted/internet/tcp.py", line 211, in _dataReceived
rval = self.protocol.dataReceived(data)
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/twisted/protocols/tls.py", line 330, in dataReceived
self._flushReceiveBIO()
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/twisted/protocols/tls.py", line 295, in _flushReceiveBIO
ProtocolWrapper.dataReceived(self, bytes)
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/twisted/protocols/policies.py", line 120, in dataReceived
self.wrappedProtocol.dataReceived(data)
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/autobahn/twisted/websocket.py", line 131, in dataReceived
self._dataReceived(data)
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/autobahn/websocket/protocol.py", line 1175, in _dataReceived
self.consumeData()
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/autobahn/websocket/protocol.py", line 1187, in consumeData
while self.processData() and self.state != WebSocketProtocol.STATE_CLOSED:
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/autobahn/websocket/protocol.py", line 1553, in processData
fr = self.onFrameEnd()
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/autobahn/websocket/protocol.py", line 1674, in onFrameEnd
self._onMessageEnd()
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/autobahn/twisted/websocket.py", line 159, in _onMessageEnd
self.onMessageEnd()
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/autobahn/websocket/protocol.py", line 627, in onMessageEnd
self._onMessage(payload, self.message_is_binary)
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/autobahn/twisted/websocket.py", line 162, in _onMessage
self.onMessage(payload, isBinary)
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/kiteconnect-3.7.0b9-py3.5.egg/kiteconnect/ticker.py", line 71, in onMessage

File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/kiteconnect-3.7.0b9-py3.5.egg/kiteconnect/ticker.py", line 657, in _on_message

File "Live_strategy.py", line 166, in on_ticks
start_strategy()
File "Live_strategy.py", line 105, in start_strategy
orderid = kite.place_order('REGULAR',kite.EXCHANGE_NSE,tradingsymbol,'SELL',quantity,'MIS','MARKET',stocks_prices[index])
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/kiteconnect-3.7.0b9-py3.5.egg/kiteconnect/connect.py", line 322, in place_order

File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/kiteconnect-3.7.0b9-py3.5.egg/kiteconnect/connect.py", line 697, in _post

File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/kiteconnect-3.7.0b9-py3.5.egg/kiteconnect/connect.py", line 741, in _request

File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/kiteconnect-3.7.0b9-py3.5.egg/kiteconnect/connect.py", line 738, in _request

File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/requests/sessions.py", line 508, in request
resp = self.send(prep, **send_kwargs)
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/requests/sessions.py", line 618, in send
r = adapter.send(request, **kwargs)
File "/Library/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/requests/adapters.py", line 521, in send
raise ReadTimeout(e, request=request)
requests.exceptions.ReadTimeout: HTTPSConnectionPool(host='api.kite.trade', port=443): Read timed out. (read timeout=7)

This discussion has been closed.