安装VBA转Python工具vb2Py时遭遇legacy-install-failure错误求助
解决vb2Py安装时simpleparse包的legacy-install-failure错误
执行命令:
pip install --trusted-host pypi.org --trusted-host files.pythonhosted.org vb2py
后出现以下错误:
error: legacy-install-failure
× Encountered error while trying to install package.
╰─> simpleparsenote: This is an issue with the package mentioned above, not pip.
hint: See above for output from the failure.
以下是可行的解决办法:
- 强制安装simpleparse的二进制包,跳过源码编译:
完成后再重新执行vb2Py的安装命令。pip install simpleparse --only-binary :all: - 检查Python版本兼容性:simpleparse是较老旧的包,可能不支持Python 3.10及以上版本,可降级到Python 3.9或更低版本后重试安装。
- 手动下载对应系统的simpleparse wheel包本地安装:找到匹配你系统和Python版本的
.whl文件,执行pip install /path/to/simpleparse-xxx.whl,之后再安装vb2Py。 - 尝试安装vb2Py的开发版本:
开发分支可能已经修复了依赖兼容问题。pip install git+https://github.com/vb2py/vb2py.git
内容的提问来源于stack exchange,提问作者Kaseox
相关产品推荐
相关产品推荐

