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

too much indentation later when previous is off by one #486

Closed
Fla3inH0tCheet0s opened this issue Jun 6, 2019 · 1 comment
Closed

too much indentation later when previous is off by one #486

Fla3inH0tCheet0s opened this issue Jun 6, 2019 · 1 comment
Assignees

Comments

@Fla3inH0tCheet0s
Copy link

Fla3inH0tCheet0s commented Jun 6, 2019


Python Code

for a in [1, 2, 3]:
   print('hello world')
    for b in [1, 2, 3]:
        print(a, b)

turns into

for a in [1, 2, 3]:
    print('hello world')
    for b in [1, 2, 3]:
            print(a, b)

Line 2's first indentation is intended, but line 4's has one extra indentation.

Command Line and Configuration

.pep8, setup.cfg, ...

[pep8]

Command Line

$ autopep8 

Your Environment

  • Python version: Python 2.7.12
  • autopep8 version: autopep8 1.4.4 (pycodestyle: 2.5.0)
  • Platform: windows, linux, macOSX, and other OS...
    Ubuntu 16.04
@hhatto
Copy link
Owner

hhatto commented Feb 21, 2020

fix in version 1.5, and released.

https://github.com/hhatto/autopep8/releases/tag/v1.5
https://pypi.org/project/autopep8/1.5/

Thank you for reporting problem 👍

@hhatto hhatto closed this as completed Feb 21, 2020
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

2 participants