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

Skip magic trailing comma #2496

Conversation

jonathanberthias
Copy link

Summary

There have been many comments asking contributors to merge lines where possible such as this one. There is an option available in the Ruff formatter to do this automatically, at the expense of ignoring magic trailing commas: skip-magic-trailing-comma, and a sibling isort option for imports: split-on-trailing-comma.

This change reformats a lot of code, so I would understand if you prefer not merging this.

Checklist

  • I understand that this PR may be closed in case there was no previous discussion. (This doesn't apply to typos!)
  • I've added a test for each change that was introduced, and I tried as much as possible to make a single atomic change.
  • I've updated the documentation accordingly.

Ruff format indicates there is an incompatibility with isort.split-on-trailing-comma,
so one of the 2 must be set to false for them to be coherent.
@Kludex
Copy link
Member

Kludex commented Feb 9, 2024

We can merge this and, add a .git-blame-ignore-revs in a subsequent commit.

@Kludex
Copy link
Member

Kludex commented Feb 29, 2024

Yeah, let's not merge this. 👍

Thanks for letting me know about those flags, anyway.

@Kludex Kludex closed this Feb 29, 2024
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

Successfully merging this pull request may close these issues.

2 participants