vn.py量化社区
By Traders, For Traders.
Member
avatar
加入于:
帖子: 2
声望: 0

在图形界面点CTA回测 会有如下报错
Traceback (most recent call last):
File "D:\vnpy\lib\site-packages\vnpy\trader\ui\mainwindow.py", line 278, in open_widget
widget = widget_class(self.main_engine, self.event_engine)
File "D:\vnpy\lib\site-packages\vnpy\app\cta_backtester\ui\widget.py", line 50, in init
self.init_strategy_settings()
File "D:\vnpy\lib\site-packages\vnpy\app\cta_backtester\ui\widget.py", line 57, in init_strategy_settings
setting = self.backtester_engine.get_default_setting(class_name)
File "D:\vnpy\lib\site-packages\vnpy\app\cta_backtester\engine.py", line 239, in get_default_setting
return strategy_class.get_class_parameters()
File "D:\vnpy\lib\site-packages\vnpy\app\cta_strategy\template.py", line 60, in get_class_parameters
class_parameters[name] = getattr(cls, name)
AttributeError: type object 'CuatroStrategy' has no attribute 'slow_windowtrailling_long'

搜索了CuatroStrategy策略全文,没有slow_windowtrailling_long。。
把CuatroStrategy 策略删除 又能正常打开回测界面了
请问应该怎么排查问题

Member
avatar
加入于:
帖子: 2
声望: 0

问题解决 param 参数漏了逗号一个。。

© 2015-2019 上海韦纳软件科技有限公司
备案服务号:沪ICP备18006526号-3