我正在尝试获取 pysmell (https://github.com/orestis/pysmell) 可以工作了——看起来像是一个用于 vim 中 django 开发的不错的代码完成工具。
我在 Mac OS X 1.7.1 (Lion) 上安装了 MacVim 7.3 (快照 61)。我的 Python 版本是 2.7。
每次我尝试在 python 文件中调用 omnicompletion 时,我都会在 MacVim 中收到这些错误(这就是它说的原因Press ENTER or type command to continue
):
Error detected while processing function pysmell#Complete:
line 24:
Traceback (most recent call last):
Press ENTER or type command to continue
Error detected while processing function pysmell#Complete:
line 24:
File "<string>", line 7, in <module>
Press ENTER or type command to continue
Error detected while processing function pysmell#Complete:
line 24:
File "<string>", line 3, in vimcompletePYSMELL
Press ENTER or type command to continue
Error detected while processing function pysmell#Complete:
line 24:
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages
/pysmell/idehelper.py", line 56, in findPYSMELLDICT
Press ENTER or type command to continue
Error detected while processing function pysmell#Complete:
line 24:
tryReadPYSMELLDICT(directory, 'PYSMELLTAGS', PYSMELLDICT)
Press ENTER or type command to continue
Error detected while processing function pysmell#Complete:
line 24:
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages
/pysmell/idehelper.py", line 42, in tryReadPYSMELLDICT
Press ENTER or type command to continue
Error detected while processing function pysmell#Complete:
line 24:
updatePySmellDict(dictToUpdate, eval(tagsFile.read()))
Press ENTER or type command to continue
Error detected while processing function pysmell#Complete:
line 24:
File "<string>", line 0
Press ENTER or type command to continue
Error detected while processing function pysmell#Complete:
line 24:
Press ENTER or type command to continue
Error detected while processing function pysmell#Complete:
line 24:
^
Press ENTER or type command to continue
Error detected while processing function pysmell#Complete:
line 24:
SyntaxError: unexpected EOF while parsing
有人能识别这个错误/看到哪里出了问题并帮助我解决吗?这看起来确实是一个适用于 pythong/django/whatever python lib omnicompletion 的好工具,我想尝试一下。
编辑:删除所有Press ENTER or type command to continue
消息
Error detected while processing function pysmell#Complete:
line 24:
Traceback (most recent call last):
Error detected while processing function pysmell#Complete:
line 24:
File "<string>", line 7, in <module>
Error detected while processing function pysmell#Complete:
line 24:
File "<string>", line 3, in vimcompletePYSMELL
Error detected while processing function pysmell#Complete:
line 24:
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages
/pysmell/idehelper.py", line 56, in findPYSMELLDICT
Error detected while processing function pysmell#Complete:
line 24:
tryReadPYSMELLDICT(directory, 'PYSMELLTAGS', PYSMELLDICT)
Press ENTER or type command to continue
line 24:
File "/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/site-packages
/pysmell/idehelper.py", line 42, in tryReadPYSMELLDICT
Error detected while processing function pysmell#Complete:
line 24:
updatePySmellDict(dictToUpdate, eval(tagsFile.read()))
Error detected while processing function pysmell#Complete:
line 24:
File "<string>", line 0
Error detected while processing function pysmell#Complete:
line 24:
Error detected while processing function pysmell#Complete:
line 24:
^
Error detected while processing function pysmell#Complete:
line 24:
SyntaxError: unexpected EOF while parsing