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

Implement flake8-broken-line #3465

Open
1 task
Cielquan opened this issue Mar 12, 2023 · 4 comments
Open
1 task

Implement flake8-broken-line #3465

Cielquan opened this issue Mar 12, 2023 · 4 comments
Labels
needs-decision Awaiting a decision from a maintainer plugin Implementing a known but unsupported plugin

Comments

@Cielquan
Copy link

flake8-broken-line

Forbids broken lines with a \.

Error Codes

  • N400 Found backslash that is used for line breaking
@charliermarsh charliermarsh added the plugin Implementing a known but unsupported plugin label Mar 12, 2023
@Cielquan
Copy link
Author

Because of compatibility with black this should be taken into account: https://black.readthedocs.io/en/stable/the_black_code_style/future_style.html#using-backslashes-for-with-statements

@conformist-mw
Copy link

As of python 3.10 with statements can be parenthesized.

@Cielquan
Copy link
Author

You are right.

Therefore the check should probably either run differently depending on the version of python that is targeted (pre vs. post 3.10) or have an option to allow backslashes in with statements.

On the other hand the special behavior is an edge case and becomes kind of obsolete in 2.5 years with 3.9 eol. So I can fully understand when the special behavior is not implemented. I do not know how much work that would be to implement. Unfortunately I currently have no time at hand to dig in to this.

@Avasam
Copy link

Avasam commented Dec 8, 2023

For searchability, this is also: "Implement flake8-continuation"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs-decision Awaiting a decision from a maintainer plugin Implementing a known but unsupported plugin
Projects
None yet
Development

No branches or pull requests

4 participants