相关疑难解决方法(0)

启动spyder后,'import sitecustomize'失败

我正在尝试安装python.或者实际上,现在已经安装和卸载了几次.我正在使用pythonxy与spyder IDE(我习惯使用matlab是我想使用spyder的原因).3.3.2 python甚至不会在我的win8机器上用spyder开始,所以现在我安装了2.7版本.

Spyder现在启动,但在启动时我得到'import sitecustomize'失败了吗?在我的控制台和python中不会执行我输入的任何命令.在错误之后,startupscript继续不做任何事情,我不能再做任何事了.错误告诉我用-v附录启动python,输出如下.

我用谷歌搜索了这个错误,它给了我两个可能的解决方案:我应该编辑python.rb https://github.com/mxcl/homebrew/commit/10ba101c323f98118b427f291e15abc5b3732991 或者我应该将此(在那里的最后一篇文章中的附件)应用到sitecustomize https:/ /code.google.com/p/spyderlib/issues/detail?id=771

应用diff文件没有帮助,正如mata在下面解释的那样,在安装过程中使用.rb文件,因此不适用于我的问题.

所以我的问题是:有人知道如何从经验中修复这个错误吗?

错误:

'import sitecustomize' failed; use -v for traceback
Python 2.7.5 (default, May 15 2013, 22:43:36) [MSC v.1500 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
Run Code Online (Sandbox Code Playgroud)

追溯:

C:\Python27\lib\site-packages\spyderlib\pil_patch.pyc matches C:\Python27\lib\site-packages\spyderlib\pil_patch.py

import spyderlib.pil_patch # precompiled from C:\Python27\lib\site-packages\spyderlib\pil_patch.pyc

Traceback (most recent call last):

  File "C:\Python27\lib\site.py", line 498, in execsitecustomize
    import sitecustomize

  File "C:\Python27\lib\site-packages\spyderlib\widgets\externalshell\sitecustomize.py", line 174, in <module>

    os.environ["SPYDER_AR_STATE"].lower() == "true")
  File "C:\Python27\lib\site-packages\spyderlib\widgets\externalshell\monitor.py", line 146, in …
Run Code Online (Sandbox Code Playgroud)

python installation install spyder

5
推荐指数
1
解决办法
6379
查看次数

标签 统计

install ×1

installation ×1

python ×1

spyder ×1