现象
anaconda提示升级spyder,从3.3.3到3.3.4,升级后spyder无法打开,没有任何提示。
措施
查询了很多资料,基本确定spyder的无法显示是由于qt模块导入失败造成的,一般来说是因为安装的方法、版本等比较混乱,造成qt对应模块依赖找不到
1、卸载qt相关模块
conda remove pyqt qtpy
pip uninstall pyqt5 qtpy
其中conda remove pyqt的过程中,spyder会一同删除
2、重新安装qt相关模块
conda install pyqt qtpy
重新安装pyqt和qtpy后,spyder依然打不开
3、用pip安装pyqt5
pip install pyqt5 qtpy
pip安装pyqt和qtpy后,spyder依然打不开,但是安装过程中提示spyder 3.3.4 requires pyqtwebengine<5.13, which is not installed.
4、按照提示安装pyqtwebengine
pip install pyqtwebengine
spyder --new-instance
成功启动spyder