On 21-March-2016 I had data farm connection issues and this had unexpected results.
A stop loss order for a short position at 5154 did not execute. Log shows order with state of Unknown. Position remained as 1 contract short.
When the strategy (my code - not auto exit on close) next issued orders to close the position near the end of the session, the stop loss then executed at 5154 and then the market BuyToCover order (to close the position) took 1 contract long at 5152.
Fortunately I was watching and closed the position a minute later (for a small profit - you gotta be lucky sometimes).
My question is what can be done about this in the future? If a stop loss order (or any other order) results in the order state being unknown, what can be done. Is it up to the developer to write more advanced error handling or is NinjaTrader going to process????
attached is the NinjaTrader log file from 21-March-2016 and an image of the market replay.
Thanks in advance,
Ivan
Comment