ricequant / rqalpha

A extendable, replaceable Python algorithmic backtest && trading framework supporting multiple securities
http://rqalpha.io
Other
5.39k stars 1.62k forks source link

RQAlpha 3.0.6编码问题 #214

Closed yuandi0823 closed 7 years ago

yuandi0823 commented 7 years ago

1. RQAlpha 3.0.6

2. Python 2.7.14

3. Windows 10

4. 使用eclipse,pycharm调试buy_and_hold.py(参数没有问题),debug的时候如下错误,头部已经加入了utf-8的编码设置

5.

raceback (most recent call last): File "D:\Work\IDE\eclipse-jee-oxygen-R-win32-x86_64\eclipse\plugins\org.python.pydev_6.0.0.201709191431\pysrc\pydevd.py", line 1621, in main() File "D:\Work\IDE\eclipse-jee-oxygen-R-win32-x86_64\eclipse\plugins\org.python.pydev_6.0.0.201709191431\pysrc\pydevd.py", line 1615, in main globals = debugger.run(setup['file'], None, None, is_module) File "D:\Work\IDE\eclipse-jee-oxygen-R-win32-x86_64\eclipse\plugins\org.python.pydev_6.0.0.201709191431\pysrc\pydevd.py", line 1022, in run pydev_imports.execfile(file, globals, locals) # execute the script File "D:\Work\VM\Anaconda2\envs\A2ENV\Scripts\rqalpha.exe", line 1 SyntaxError: Non-ASCII character '\x90' in file D:\Work\VM\Anaconda2\envs\A2ENV\Scripts\rqalpha.exe on line 1, but no encoding declared; see http://python.org/dev/peps/pep-0263/ for details

hzliu commented 7 years ago

应该是你配置错误,请仔细看一下文档中 pycharm 调试部分。

yuandi0823 commented 6 years ago

好的👌,谢谢了