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

Avoid unstable formatting in ellipsis-only body with trailing comment #8984

Merged
merged 1 commit into from
Dec 4, 2023

Conversation

charliermarsh
Copy link
Member

Summary

We should avoid inlining the ellipsis in:

def h():
    ...
    # bye

Just as we omit the ellipsis in:

def h():
    # bye
    ...

Closes #8905.

@charliermarsh charliermarsh added bug Something isn't working formatter Related to the formatter labels Dec 3, 2023
Copy link
Contributor

github-actions bot commented Dec 3, 2023

ruff-ecosystem results

Formatter (stable)

✅ ecosystem check detected no format changes.

Formatter (preview)

✅ ecosystem check detected no format changes.

Copy link
Member

@MichaReiser MichaReiser left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you

@charliermarsh charliermarsh merged commit 6fe8f8a into main Dec 4, 2023
17 checks passed
@charliermarsh charliermarsh deleted the charlie/ellipsis branch December 4, 2023 00:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working formatter Related to the formatter
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unstable formatting in ignore_pyi.pyi
2 participants