vnpy / vnpy_ctabacktester

VeighNa框架的CTA回测模块
https://www.vnpy.com
MIT License
56 stars 63 forks source link

dialog.Accepted 没有定义 #22

Closed dalitang closed 1 year ago

dalitang commented 1 year ago

Traceback (most recent call last): File "/opt/homebrew/Caskroom/miniforge/base/envs/vnpy/lib/python3.10/site-packages/vnpy_ctabacktester/ui/widget.py", line 406, in start_optimization if i != dialog.Accepted: AttributeError: 'OptimizationSettingEditor' object has no attribute 'Accepted'. Did you mean: 'accepted'? Traceback (most recent call last): File "/opt/homebrew/Caskroom/miniforge/base/envs/vnpy/lib/python3.10/site-packages/vnpy_ctabacktester/ui/widget.py", line 406, in start_optimization if i != dialog.Accepted: AttributeError: 'OptimizationSettingEditor' object has no attribute 'Accepted'. Did you mean: 'accepted'? qt.pointer.dispatch: skipping QEventPoint(id=1 ts=0 pos=0,0 scn=4549.06,697.076 gbl=4549.06,697.076 Released ellipse=(1x1 ∡ 0) vel=0,0 press=-4549.06,-697.076 last=-4549.06,-697.076 Δ 4549.06,697.076) : no target window

Macos 13.1 VNPY 3.5.0 根据1.0.9版本升级说明,应给是替换GraphicsWindow到 GraphicsLayoutWidget 以后的问题,不知道是不是mac上qt6的问题

dalitang commented 1 year ago

已经解决了: 1)QtWidgets 是pyside6里面的 from PySide6 import QtGui, QtWidgets, QtCore 所以降级 pyside6 from 6.4 to 6.3.2 没有报错了

建议: vnpy repo 的 setup.cfg install_requires 里面的包都加上一个版本号(锁定测试过的版本) 这样不会在升级以后出现不可预知的问题

vnpy commented 1 year ago

感谢反馈!