Skip to content

Don't warn about magic trailing comma when isort.force-single-line is true#8244

Merged
charliermarsh merged 1 commit intomainfrom
10-26-Don_t_warn_about_magic_trailing_comma_when_isort.force-single-line_is_true
Oct 26, 2023
Merged

Don't warn about magic trailing comma when isort.force-single-line is true#8244
charliermarsh merged 1 commit intomainfrom
10-26-Don_t_warn_about_magic_trailing_comma_when_isort.force-single-line_is_true

Conversation

@MichaReiser
Copy link
Member

Summary

Based on this feedback. Avoid warning about force-wrap-aliases and split-on-trailing-comma if force-single-line is true (which creates a dedicated import for each imported member).

Test Plan

Ran ruff format . --no-cache and verified that the warning show up when force-single-line=false and aren't shown when force-single-line=true

@MichaReiser
Copy link
Member Author

@MichaReiser MichaReiser added the cli Related to the command-line interface label Oct 26, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Oct 26, 2023

PR Check Results

Ecosystem

✅ ecosystem check detected no changes.

@henryiii
Copy link
Contributor

(issue with pypa/build fixed upstream, by the way, not related to this PR)

@charliermarsh
Copy link
Member

(I accidentally merged in main not realizing this has a different upstream, but I'll fix it up before merging.)

Base automatically changed from refine-linter-incompatible-option-warnings to main October 26, 2023 16:22
@charliermarsh charliermarsh force-pushed the 10-26-Don_t_warn_about_magic_trailing_comma_when_isort.force-single-line_is_true branch from 99c944d to 2a78ccb Compare October 26, 2023 16:29
@charliermarsh charliermarsh added the formatter Related to the formatter label Oct 26, 2023
@charliermarsh charliermarsh enabled auto-merge (squash) October 26, 2023 16:29
@charliermarsh charliermarsh merged commit c32f943 into main Oct 26, 2023
@charliermarsh charliermarsh deleted the 10-26-Don_t_warn_about_magic_trailing_comma_when_isort.force-single-line_is_true branch October 26, 2023 16:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cli Related to the command-line interface formatter Related to the formatter

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants