-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Exclude formatter from running on specific lines with inline comment #451
Comments
You can use |
Excellent, thank you! |
@jakerye That doesn't work inline as the title of the issue required. I don't want to have to add two new lines if my goal is for
|
@Ab-w: |
@eric-wieser It would be, but I don't see it as being necessary at all. As a case in point, consider pylint. It lets me disable analysis either for a line or for a block, both with the same |
Ref #790 (comment) which discusses the desirability of an inline comment toggle and has a clever workaround for setting |
Doesn't work when used on jupyter magic commands:
|
@juliuscrn |
For anyone who stumbles upon this GitHub Issue: it looks like Black now supports skipping a single line by adding foo = 1 # fmt: skip |
This comment was marked as off-topic.
This comment was marked as off-topic.
Found out that leaving just |
This is also my observation in #3450. |
Only this indeed works rather than |
Some of my code is just over the border of the line limit. Here is an example:
I'd really like it to look like this (or equivalent):
Is this something that aligns with the black ideology?
The text was updated successfully, but these errors were encountered: