https://bugs.kde.org/show_bug.cgi?id=385117

            Bug ID: 385117
           Summary: Python indentation indents too often since recent
                    update
           Product: kate
           Version: 17.08.1
          Platform: openSUSE RPMs
                OS: Linux
            Status: UNCONFIRMED
          Severity: normal
          Priority: NOR
         Component: indentation
          Assignee: kwrite-bugs-n...@kde.org
          Reporter: maar...@treewalker.org
  Target Milestone: ---

I've been using Kate with Python projects for a long time, but since a recent
update it hasn't been functioning well.

The problem is that it will often indent a line to line up with the line above
it. For languages like C this would be desired, but since in Python the end of
a block is identified by the indentation level decreasing, an editor should
never change the indentation of an existing line, since it changes the meaning
of the code being edited.

For example, if I start with this code fragment:

    if x == 0:
        foo()
    y = x

and I then add "+ 1" to the third line, Kate will indent it like this:

    if x == 0:
        foo()
        y = x + 1

which incorrectly pulls the third line into the if's body.

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to