修改gateway,增加log记录
This commit is contained in:
parent
2075fe9866
commit
7786dcda27
@ -17,6 +17,8 @@ from vnctptd import TdApi
|
|||||||
from ctpDataType import *
|
from ctpDataType import *
|
||||||
from vtGateway import *
|
from vtGateway import *
|
||||||
|
|
||||||
|
import logging
|
||||||
|
|
||||||
|
|
||||||
# 以下为一些VT类型和CTP类型的映射字典
|
# 以下为一些VT类型和CTP类型的映射字典
|
||||||
# 价格类型映射
|
# 价格类型映射
|
||||||
@ -538,6 +540,9 @@ class CtpTdApi(TdApi):
|
|||||||
#----------------------------------------------------------------------
|
#----------------------------------------------------------------------
|
||||||
def onRspOrderInsert(self, data, error, n, last):
|
def onRspOrderInsert(self, data, error, n, last):
|
||||||
"""发单错误(柜台)"""
|
"""发单错误(柜台)"""
|
||||||
|
|
||||||
|
logging.info(u'onRspOrderInsert')
|
||||||
|
|
||||||
err = VtErrorData()
|
err = VtErrorData()
|
||||||
err.gatewayName = self.gatewayName
|
err.gatewayName = self.gatewayName
|
||||||
err.errorID = error['ErrorID']
|
err.errorID = error['ErrorID']
|
||||||
|
@ -11,7 +11,7 @@ from uiMainWindow import *
|
|||||||
|
|
||||||
from setup_logger import setup_logger
|
from setup_logger import setup_logger
|
||||||
|
|
||||||
setup_logger(filename='logs/vnpy_{0}.log'.format(datetime.now().strftime('%m%d_%H%M')), debug=True)
|
setup_logger(filename='logs/vnpy_{0}.log'.format(datetime.now().strftime('%m%d_%H%M')), debug=False)
|
||||||
|
|
||||||
# ----------------------------------------------------------------------
|
# ----------------------------------------------------------------------
|
||||||
def main():
|
def main():
|
||||||
|
Loading…
Reference in New Issue
Block a user