Skip to content

Better experience for adjusting indentation in VS Code for Python Files with Flake8 formatting #193591

@npz7yyk

Description

@npz7yyk

Overview

Currently, when coding in Python with Flake8 formatting enabled in Visual Studio Code, there is a "pity" with the handling of indentation for lines with no content. I would like to propose a feature enhancement to address it.

Problem Description:

When using the "tab" key to adjust the indentation of a block, it also inserts tabs for lines with no content. This behavior violates Flake8 rules, requiring manual correction. Things are similar when trying to decrease the indentation of a block (lines with no content are removed).

Proposed Solution:

I suggest implementing a modification to multi-line edition mode in VS Code when working with Python files with Flake8 formatting on. Specifically, it should only affect lines with actual content and respect Flake8 formatting rules.

Metadata

Metadata

Assignees

Labels

editor-autoindentEditor auto indentation issuesfeature-requestRequest for new features or functionality

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions