Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Geany adds extra indent when sending selection to terminal with IPython #2238

Closed
yyatsyn opened this issue Aug 1, 2019 · 1 comment
Closed

Comments

@yyatsyn
Copy link

yyatsyn commented Aug 1, 2019

When a piece of tabbed code is sent to terminal with Python then it runs OK, but when exactly the same code is sent to terminal with IPython, then Geany adds extra indentation to each line.

Example: code in Terminal with Python:

def my_function(x):
    #bla-bla-bla
    y = x + x
    return x

while the same code sent in Terminal with IPython appears as

def my_function(x):
    #bla-bla-bla
        y = x + x
            return y

which results in IndentationError: unexpected indent

@yyatsyn
Copy link
Author

yyatsyn commented Aug 1, 2019

Actually, the problem was with autoindent in IPython. The solution was to start IPython as ipython --no-autoindent.

@yyatsyn yyatsyn closed this as completed Aug 1, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant