我无法在 python2.7 中运行 tg-admin,我该怎么做?
我试图在 python 2.7 上的 ubuntu 11.04 中运行 tg-admin 但我一直遇到如下所示的错误,但后来我能够使用 python 2.6 运行它,如下所示:
#!/usr/bin/python
# EASY-INSTALL-ENTRY-SCRIPT: 'TurboGears==1.1.1','console_scripts','tg-admin'
__requires__ = 'TurboGears==1.1.1'
我将第一行更改为 :
#!/usr/bin/python2.6
并且它工作正常,但是由于 ubuntu11.04 上的默认 python 版本是 python 2.7,所以当我尝试用它运行某些东西时,它总是失败,错误消息如下:
......bla...bla 和@last
File "/usr/lib/pymodules/python2.7/peak/util/assembler.py", line 221, in TryExcept
next_test.JUMP_IF_FALSE, Code.POP_TOP, # remove condition
AttributeError: 'Label' object has no attribute 'JUMP_IF_FALSE'
I was trying to run tg-admin in ubuntu 11.04 on python 2.7 but I keep having an error shown below, but later I was able to run it using python 2.6 like this :
#!/usr/bin/python
# EASY-INSTALL-ENTRY-SCRIPT: 'TurboGears==1.1.1','console_scripts','tg-admin'
__requires__ = 'TurboGears==1.1.1'
I changed the first line to :
#!/usr/bin/python2.6
and it works fine, but since the default python version on ubuntu11.04 is python 2.7 so it keeps failing when I try to run some thing with it, and the error message is like this :
.......bla...bla and @ last
File "/usr/lib/pymodules/python2.7/peak/util/assembler.py", line 221, in TryExcept
next_test.JUMP_IF_FALSE, Code.POP_TOP, # remove condition
AttributeError: 'Label' object has no attribute 'JUMP_IF_FALSE'
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论