本文介绍了ipython 0.10.1中的意外缩进的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

限时删除!!

我在ubuntu 11.04和python 2.7.1中使用ipython 0.10.1遇到问题.

I have a problem with ipython 0.10.1 in ubuntu 11.04 and python 2.7.1.

在以前的ipython版本中,交互工作时缩进并不重要.

In previous versions of ipython indentation did not matter when working interactively.

现在,任何缩进语句都会引发异常:

Now instead any indented statement throws an exception:

In [1]:  a=3
------------------------------------------------------------
IndentationError: unexpected indent (<ipython console>, line 1)

这真的很烦人,特别是在我调试时,我想从缩进的脚本中粘贴一些代码,并且不得不对每一行进行缩排.

this is really very annoying specifically when I am debugging and I want to paste some code from a script which is indented, and I am forced to undent every line.

任何暗示欢迎.

推荐答案

仅当使用-wthread调用ipython时,我才提交了错误对此.

This happens only when ipython is called with -wthread, I've just filed a bug about this.

这篇关于ipython 0.10.1中的意外缩进的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

1403页,肝出来的..

09-06 21:18