From 5b2a6d06eab7c0f21d2eb5250e5f484e3e7e3b4d Mon Sep 17 00:00:00 2001 From: wisfern Date: Fri, 18 Aug 2017 09:53:30 +0800 Subject: [PATCH] =?UTF-8?q?bugfix:=20=E6=95=B0=E6=8D=AE=E5=BC=95=E6=93=8E?= =?UTF-8?q?=E6=8E=92=E9=99=A4=E6=8B=92=E5=8D=95=E7=B1=BB=E7=9A=84=E6=B4=BB?= =?UTF-8?q?=E5=8A=A8=E8=AE=A2=E5=8D=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- vnpy/trader/vtEngine.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/vnpy/trader/vtEngine.py b/vnpy/trader/vtEngine.py index ab52c066..dc7a9a2f 100644 --- a/vnpy/trader/vtEngine.py +++ b/vnpy/trader/vtEngine.py @@ -350,7 +350,7 @@ class DataEngine(object): self.orderDict[order.vtOrderID] = order # 如果订单的状态是全部成交或者撤销,则需要从workingOrderDict中移除 - if order.status == STATUS_ALLTRADED or order.status == STATUS_CANCELLED: + if order.status in [STATUS_ALLTRADED, STATUS_REJECTED, STATUS_CANCELLED]: if order.vtOrderID in self.workingOrderDict: del self.workingOrderDict[order.vtOrderID] # 否则则更新字典中的数据