I’m using python and I’m trying to submit a stop loss order, my understanding is that when the stop loss price is hit, then a new order is initiated. But, the stop loss is getting triggered immediately. Here is an example I have been trying in paper money:
When running the below code, SPY price was at 220.15
After running the above code a market order was triggered immediately at 220.15, then a market sell was immediately triggered at 220.16. But, I thought it would wait until the price for SPY dropped to 218.15 before triggering the sell order.
What am I missing?