Why is SL-M orders sent to exchange as a Limit order on trigger, instead of Market order execution?

Shaha
Below is the history of SL-M leg of a BO order(order id - 170919000032781). Parent order id - 170919000023768

I was expecting that the SL-M order to get converted to a Market order on trigger. But surprised to see it to get executed as a Limit order. Why so? And if so, doesnt convertion to LIMIT order make it vulnerable to non-execution in fast moving price?
Sorry, if i could not explain my question clearly. But it is a serious consideration in my algos, as depending on the behaviour i will have to handle accordingly. So, intend to get the background clarified.
In [15]: pandas.DataFrame(kite.orders("170919000032781"))[["order_type","status","order_timestamp","order_id"]]
Out[15]:
order_type status order_timestamp order_id
0 SL-M PUT ORDER REQ RECEIVED 2017-09-19 09:15:49 170919000032781
1 SL-M VALIDATION PENDING 2017-09-19 09:15:49 170919000032781
2 SL-M OPEN PENDING 2017-09-19 09:15:49 170919000032781
3 SL-M TRIGGER PENDING 2017-09-19 09:15:49 170919000032781
4 LIMIT OPEN 2017-09-19 09:18:47 170919000032781
5 LIMIT COMPLETE 2017-09-19 09:18:47 170919000032781
Checked that same is the case on a stand alone single legged SL-M order, too.
Tagged:
  • Shaha
    Still unanswered. And this behavior led to huge loss yesterday for some trades.
  • Shaha
    SL-M orders should be executed as Market orders on trigger and not as Limit order... Else whats the difference between SL-M and SL orders.
  • Shaha
    This is what you have mentioned everywhere... in almost every documentation.

    b)Stop Loss Market - In a stop loss market order only the trigger price has to be specified.
    Once the trigger price is hit, the order becomes a market order and it will be executed. Stop
    Loss market orders will always be filled and will definitely be executed.
  • Shaha
    Yesterdays Order to analyse:
    In [17]: Orders_History[Orders_History["order_id"]==171025000042909][["transaction_type","order_type","status","order_timestamp","average_price","price","trigg
    ...: er_price","tradingsymbol"]]^M
    ...:
    Out[17]:
    transaction_type order_type status order_timestamp average_price price trigger_price tradingsymbol
    1636 BUY SL-M PUT ORDER REQ RECEIVED 2017-10-25 09:15:21 0.0 0.0 158.9 PNB
    1637 BUY SL-M VALIDATION PENDING 2017-10-25 09:15:21 0.0 0.0 158.9 PNB
    1638 BUY SL-M OPEN PENDING 2017-10-25 09:15:21 0.0 0.0 158.9 PNB
    1639 BUY SL-M TRIGGER PENDING 2017-10-25 09:15:21 0.0 0.0 158.9 PNB
    1640 BUY LIMIT OPEN 2017-10-25 09:15:21 0.0 0.0 158.9 PNB
    1641 BUY LIMIT OPEN 2017-10-25 09:15:21 0.0 158.9 158.9 PNB
    1642 BUY LIMIT MODIFY VALIDATION PENDING 2017-10-25 15:02:30 0.0 158.9 158.9 PNB
    1643 BUY LIMIT MODIFY PENDING 2017-10-25 15:02:30 0.0 158.9 158.9 PNB
    1644 BUY LIMIT MODIFIED 2017-10-25 15:02:37 0.0 158.9 158.9 PNB
    1645 BUY MARKET OPEN 2017-10-25 15:02:37 0.0 0.0 0.0 PNB
    1646 BUY MARKET COMPLETE 2017-10-25 15:02:37 199.0 0.0 0.0 PNB
  • sujith
    Hi @Shaha,
    Is this happening for all the orders?
    Ideally, this can happen when circuit limit is hit.
  • sujith
    If it is happening on all orders. Kindly give us order id on the same day of issue. We will look into this and get back to you.
  • Shaha
    All orders, everyday. It looks to be an architecture issue. Check order history of any bracket order where SL is hit..
  • Shaha
    Shaha edited October 2017
    Even single legged, standalone SL-M order example given on 20th Sep, behaved this way.
  • jayganesh
    This happened with me as well. SL Orders shouldn't be converted to Limit Orders. I have to put a manual check and cancel those limit orders.
  • Shaha
    Because there is nothing like market order for exchange. Exchange works on order matching logic. All orders are limit order for exchange.
  • Shaha
    It might surprise you initially. But this is how it is. Also BO order is not a product of Zerodha, Zerodha simply sends the BO order with SL and target to exchange. Entire BO order execution happens at exchange. I am saying this with enough background and having had few healthy discussions with Zerodha RMS on few other related items. Welcome to the world of algo/auto trading. At every stage u are too close but yet somewhat far. :-)
Sign In or Register to comment.