Sorry the code is
print("before received")
received=kite.orders()
print("after received")
# for individual_order in received:
# if (individual_order['order_id'])==order_id_limit:
# …
@rakeshr
I have modified the code as per the link advised by you earlier itself. The code is now outside the on_ticks function. Still the same error. Now I observed the problem is with the following code
received=kite.orders().
If I comment out thi…
In the scenario where the code is witin on_ticks Whenever I get this error: 1006 - connection was closed uncleanly (None). I can see that tick data is not getting printed in output for 7 to 8 seconds and then the tick data starts as I have commented…
@rakeshr
Dear Rakesh, Kindly advise. Sorry to bother you with large posts.
I tried putting the code outside on_ticks function, but facing issues. I also ran the same logic with code inside on_ticks function. Following are the results. Code and log…
I have modified the code as below. So it is working. My above observation was correct. Cancelled order was getting multiple times so the error was thrown. In the following code that has been taken care of. May not be a good code. but somehow working…
I have a doubt in the following code , after the PENDING order is cancelled first time, for every tick, the cancelled order is getting cancelled again. That is why first time there is no error and second time onwards the error is thrown. I will look…
For your clarity I am attaching the screen shot of the orders executed today with the logic. In the screenshot, the market order is executed by the logic and when the profit is booked (LIMIT order is executed), the SLM order automatically got can ce…
Dear Sujith, It is open order (TRIGGER PENDING status). It is working first time for the first position taken. I mean when the first LIMIT order is executed, the corresponding SLM order is cancelled today. But for the subsequent orders the error is …