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

请帮忙解答一下 #274

Closed rhermit closed 6 years ago

rhermit commented 6 years ago

提 ISSUE 须知

请先阅读文档 rqalpha文档

如果仍有问题的话请在 issue列表 中寻找是否有相关问题的解决方案

如果没有的话 麻烦开一个issue 描述以下问题:

1. RQAlpha的版本

2. Python的版本

3. 是Windows/Linux/MacOS or others?

4. 您出现问题对应的源码/或者能复现问题的简易代码 以及对应的配置

5. 您出现的错误堆栈日志信息

rhermit commented 6 years ago

rqalpha 版本3.0.9 Python2.7 Windows 运行run_code_demo.py和run_file_demo.py和run_func_demo.py 会出现 Traceback (most recent call last): File "C:/RQalpha-3.0.9/rqalpha/examples/run_code_demo.py", line 47, in run_code(code, config) File "C:\RQalpha-3.0.9\rqalpha__init.py", line 115, in run_code return main.run(config, source_code=code) File "C:\RQalpha-3.0.9\rqalpha\main.py", line 315, in run code = _exception_handler(user_exc) File "C:\RQalpha-3.0.9\rqalpha\main.py", line 326, in _exception_handler better_exceptions.excepthook(e.error.exc_type, e.error.exc_val, e.error.exc_tb) File "C:\Anaconda2\lib\site-packages\better_exceptions\init__.py", line 53, in excepthook formatted = format_exception(exc, value, tb) File "C:\RQalpha-3.0.9\rqalpha\utils\logger.py", line 35, in format_exception formatted, colored_source = better_exceptions.format_traceback(tb) AttributeError: 'module' object has no attribute 'format_traceback'

Process finished with exit code 1

Cuizi7 commented 6 years ago

解决方法见https://github.com/ricequant/rqalpha/issues/245