简体   繁体   中英

Anaconda Spyder Qt library error on launch

When launching Spyder from the Anaconda python installation on Linux Mint 13 I get the following error:

Cannot mix incompatible Qt library (version 0x40801) with this library (version 0x40805)
Aborted

$PATH is

   /home/ron/anaconda/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games

Has anyone found a work around?

Anaconda web-site indicates that Spyder may not launch correctly on Linux machines.

http://docs.continuum.io/anaconda/

*** Resolved I am a little sheepish. Discovered that I installed Anaconda as sudo. Reinstalled as indicated in documentation and everything works fine. Thanks everyone for the help.

I use anaconda 1.8 on kubuntu alpha. It uses qt 4.8.5. I can see it with

find $ANACONDA/lib -name '*.4.8.5'

My system qt libs is 4.8.6. I can see it with

find /usr/lib -name "*so.4.8.6"

If Your system qt version is 4.8.5, and anaconda is 4.8.1 -- maybe You can just update anaconda? Try to run

conda update conda
conda update anaconda

Edit

It seems that the problem is spyder picking up Your system libraries. I tried to sheild the libs using evnironment variables LD_LIBRARY_PATH and various qt-related. But nothing works. However simple copying system libs to $ANACONDA/lib solves the problem.

Go to $ANACONDA/lib and move all *.4.8* files to another dir. Then go to /usr/lib/x86_64-linux-gnu (are You using 64 bit?) and copy all *.4.8* to $ANACONDA/lib . That's it: run spyder !

在此输入图像描述

The qtlibs are usually stored as files and links: for example if there's a libQtGui.so.4.8.6 file then there's also a symbolic link libQtGui.so.4.8 . You have to copy/move links too.

Edit 2 :

There's a suggestion to

unset QT_PLUGIN_PATH

I tried to set it to nothing export QT_PLUGIN_PATH= , but didn't try to unset it.

Spyder dev here )仅仅是为了记录,这是Anaconda中的一个知识错误 ,希望将在下一个版本中修复(将于2014年10月发布)。

For me, the best solution was (inspired by @Adobe's answer) to go to the directory in which Anaconda was installed, then the subdirectory lib and to move all the files libQt* out of the way (I moved them to a temporary subdirectory I created for the purpose). Anaconda will now pick up the system libraries. I expect there will be a problem when I update Anaconda and it installs new Qt libraries, but that's for later.

My version is conda 3.9.1 with python 3.4.3 and qt 4.8.5, installed on Debian testing (current as of today) with libqtcore4 version 4:4.8.6+git64-g5dc8b2b+dfsg-3; the architecture is amd64.

Unsetting QT_PLUGIN_PATH and/or setting it to empty did work in the first instance, in that it allowed me to start spyder, but it has some disadvantages. Most importantly, whenever I tried to plot something using matplotlib and inline graphics, I got the error message "it seems the kernel died unexpectedly" instead of the plot I wanted.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM