For code/output blocks: Use ``` (aka backtick or grave accent) in a single line before and after the block. See: http://commonmark.org/help/
the status of order with valid given is never set to "expired" in live trading
-
Hi community,
I'm tying to build my trade system with backtrader and btoandav20.And I find that the order with valid is never set to "expired", I'm not sure this situation is causes by backtrader or btoandav20.
After tracing code, I think the problem is caused by the
self.data.datetime[0]
isnan
when the "expired event" comes and the oandastore.py callsself.broker._expire(oref)
.It makes the expression
self.data.datetime[0] > self.valid
ofexpire
in order.py always returnsfalse
.