VeighNa量化社区
你的开源社区量化交易平台
Member
avatar
加入于:
帖子: 4
声望: 0

提示信息为:

Traceback (most recent call last):
  File "d:\vnpy\lib\site-packages\vnstation\core\ps.py", line 19, in get_current_python_path
    return get_current_python_path_from_executable(allow_pythonw)
  File "d:\vnpy\lib\site-packages\vnstation\core\ps.py", line 95, in get_current_python_path_from_executable
    raise FileNotFoundError("无法通过sys.executable定位Python.exe的位置")
FileNotFoundError: 无法通过sys.executable定位Python.exe的位置

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "d:\vnpy\lib\site-packages\vnstation\ui\main\mainwindow.py", line 146, in open_lite_clicked
    self.trader_process = start_trader(setting)
  File "d:\vnpy\lib\site-packages\vnstation\ui\main\mainwindow.py", line 326, in start_trader
    hide=True,
  File "d:\vnpy\lib\site-packages\vnstation\core\ps.py", line 114, in start_python
    pypath = get_current_python_path()
  File "d:\vnpy\lib\site-packages\vnstation\core\ps.py", line 24, in get_current_python_path
    raise FileNotFoundError("无法定位Python.exe的位置") from e
FileNotFoundError: 无法定位Python.exe的位置

请问应该怎样处理? 多谢!

  • 安装之前, 系统中有一个vnpy, 印象是 2.1.x, 比较老已经无法启动. 做了彻底卸载, 删除了老版本的文件夹, 并更改了安装路径.
  • 曾根据提示, 对 d:\vnpy\lib\site-packages\vnstation\core\ps.py 中的相应函数做修改, 仍不工作 (闪退):
    def get_current_python_path_from_import():
      return 'd:\\vnpy' # 改成包含anaconda3的路径也不行
  • /d/vnpy运行 python -m, 提示找不到模块:
    λ python -m vnstation
    C:\Program Files\Python36\python.exe: No module named vnstation
Member
avatar
加入于:
帖子: 337
声望: 27

应该是安装路径有问题,可以重新安装一下,建议直接使用一键下载

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

沪公网安备 31011502017034号

【用户协议】
【隐私政策】
【免责条款】