diff --git a/vnpy/trader/gateway/ctpGateway/__init__.py b/vnpy/trader/gateway/ctpGateway/__init__.py index d93e34f7..eae07c90 100644 --- a/vnpy/trader/gateway/ctpGateway/__init__.py +++ b/vnpy/trader/gateway/ctpGateway/__init__.py @@ -1,13 +1,11 @@ # encoding: UTF-8 -import sys import os -#print u'init {0}'.format(os.path.dirname(__file__)) +print u'init path:{0}'.format(os.path.dirname(__file__)) from vnpy.trader import vtConstant from ctpGateway import CtpGateway - gatewayClass = CtpGateway gatewayName = 'CTP' gatewayDisplayName = 'CTP' diff --git a/vnpy/trader/gateway/ctpGateway/ctpGateway.py b/vnpy/trader/gateway/ctpGateway/ctpGateway.py index 9b1da2a1..5d22dc73 100644 --- a/vnpy/trader/gateway/ctpGateway/ctpGateway.py +++ b/vnpy/trader/gateway/ctpGateway/ctpGateway.py @@ -6,21 +6,18 @@ vn.ctp的gateway接入 考虑到现阶段大部分CTP中的ExchangeID字段返回的都是空值 vtSymbol直接使用symbol ''' - +print 'loading ctpGateway.py' import os -import sys import json -from copy import copy -from datetime import datetime -import logging +# 加载经booster编译转换的SO API库 from vnctpmd import MdApi from vnctptd import TdApi from vnpy.trader.vtConstant import * from vnpy.trader.vtGateway import * -from ctpDataType import * from vnpy.trader.gateway.ctpGateway.language import text +from vnpy.trader.gateway.ctpGateway.ctpDataType import * # 以下为一些VT类型和CTP类型的映射字典 # 价格类型映射 diff --git a/vnpy/trader/gateway/ctpGateway/language/__init__.py b/vnpy/trader/gateway/ctpGateway/language/__init__.py index e7d7568b..790ecf0a 100644 --- a/vnpy/trader/gateway/ctpGateway/language/__init__.py +++ b/vnpy/trader/gateway/ctpGateway/language/__init__.py @@ -1,10 +1,7 @@ # encoding: UTF-8 -import json import os -import traceback - -#print u'init {0}'.format(os.path.dirname(__file__)) +print u'load {0}/*'.format(os.path.dirname(__file__)) # 默认设置 from chinese import text