From d3d1afd7c7bed281be37c7818157c84693a808f3 Mon Sep 17 00:00:00 2001 From: "vn.py" Date: Fri, 1 Dec 2017 09:29:48 +0800 Subject: [PATCH] =?UTF-8?q?[Mod]2=E5=92=8C3=E5=85=BC=E5=AE=B9=E6=80=A7?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- vnpy/event/eventType.py | 4 ++-- vnpy/trader/vtGlobal.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/vnpy/event/eventType.py b/vnpy/event/eventType.py index afe7ff72..0515bcb1 100644 --- a/vnpy/event/eventType.py +++ b/vnpy/event/eventType.py @@ -34,8 +34,8 @@ def test(): if len(value)>1: print(u'存在重复的常量定义:{}'.format(str(key))) for name in value: - print name - print '' + print(name) + print('') print(u'测试完毕') diff --git a/vnpy/trader/vtGlobal.py b/vnpy/trader/vtGlobal.py index 25581335..420b9fa7 100644 --- a/vnpy/trader/vtGlobal.py +++ b/vnpy/trader/vtGlobal.py @@ -16,7 +16,7 @@ settingFilePath = getJsonPath(settingFileName, __file__) globalSetting = {} # 全局配置字典 try: - with open(settingFilePath) as f: + with open(settingFilePath, 'rb') as f: setting = f.read() if type(setting) is not str: setting = str(setting, encoding='utf8')