I'm developing a strategy that enters with 6 contracts, 4 are scalpers and 2 are runners. I have a single market order for the entry with quantity of 6. I handle the setup of partial fills until all 6 are filled. However, I'm getting some scalp target orders cancelled when I get partial fills. For example, with 2 entries and then 4 entries, the 4 target limit orders are set but when the first two targets are met the next two are getting canceled, leaving two position unaccounted for in my scalper logic. (The other two are handled by the runners logic.)
I get this message in the cancelled order process: Cancelled pending exit order, since associated position is closed
But, as explained, there are two remaining positions. Is this happening since 2 positions were filled by a separate order than the other 4?
Even though I use the same Entry Signal Name, there are two Order ids for fulfillment. Therefore, when creating the TP orders (ExitLongLimit orders), the remaining two TP orders are getting canceled since one of the associated Order Ids have been completed with the 2 completed scalps. Is this correct?
(Sorry, if that was clear as mud. )
Thanks,
Stealth
Comment