1

我正在尝试使用带有 ipython 作为外壳的 PuDB,但是当我放入外壳时,我收到以下错误:

can't set attribute
Error in atexit._run_exitfuncs:
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/atexit.py", line 24, in _run_exitfuncs
    func(*targs, **kargs)
  File "/Library/Python/2.7/site-packages/IPython/core/interactiveshell.py", line 2744, in atexit_operations
    self.reset(new_session=False)
  File "/Library/Python/2.7/site-packages/IPython/core/interactiveshell.py", line 1132, in reset
    self.displayhook.flush()
  File "/Library/Python/2.7/site-packages/IPython/core/displayhook.py", line 255, in flush
    self.shell.user_ns['_oh'].clear()
KeyError: '_oh'
Error in sys.exitfunc:
Traceback (most recent call last):
  File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/atexit.py", line 24, in _run_exitfuncs
    func(*targs, **kargs)
  File "/Library/Python/2.7/site-packages/IPython/core/interactiveshell.py", line 2744, in atexit_operations
    self.reset(new_session=False)
  File "/Library/Python/2.7/site-packages/IPython/core/interactiveshell.py", line 1132, in reset
    self.displayhook.flush()
  File "/Library/Python/2.7/site-packages/IPython/core/displayhook.py", line 255, in flush
    self.shell.user_ns['_oh'].clear()
KeyError: '_oh'

版本详情:

  • 普度 2011.3.1
  • IPython 0.12
  • Python 2.7.1
  • Mac OS X 10.7.3
4

1 回答 1

2

这是一个已知问题,应该在 IPython 0.12.1 或 master 中修复。更新到当前 (0.12.1) IPython 有帮助吗?

于 2012-05-09T18:56:11.427 回答