I received an execution on ZC at 647, and the execution.price came through as 6.47. It was not multiplied by 100 as it should have been. The issue is I did math on this number (expecting 647, like all of the other callbacks) and obviously got an erroneous result. A subsequent order was rejected and I was able to get out at a small loss because I noticed the issue right away, but it could have been much worse had I not been glued to the screen.
I could live with it (although it is not the expected behaviour) if it always gave you the execution price in the same format, but it does not. Sometimes it is multiplied by 100, other times it is not. I've confirmed this in simulation as well.
For now, I'm going to implement a workaround at the top of onExecution, if price is less than 25, multiply it by 100, else do nothing --- as long as corn or wheat do not trade below twenty five cents, I should be covered.
Obviously, NT should handle all of this behind the scenes...please investigate and advise. Let me know if you have trouble recreating this. Thanks,
kc
Comment