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

Use ruff's docstring formatting #7276

Merged
merged 1 commit into from Feb 9, 2024

Conversation

cnpryer
Copy link
Contributor

@cnpryer cnpryer commented Feb 8, 2024

This PR replaces blacken-docs with ruff's docstring formatting.

As mentioned in #7270, I noticed that there were some docstrings that looked like they weren't already formatted. So the diff is pretty large.

Also we might want to tweak the configuration here depending on your preference, assuming this is a change you'd like to make.

Let me know if you'd like to tie this to an issue. I'd be happy to open one for this.

Copy link
Member

@MridulS MridulS left a comment

Choose a reason for hiding this comment

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

Nothing really pops out here, and if there is a nice default in ruff let's go with it 🚀

Copy link
Contributor

@rossbar rossbar left a comment

Choose a reason for hiding this comment

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

Aside from removing blacken-docs, was there also a change in the config to add ruff's docstring formatter? I don't see any changes to pyproject.toml (perhaps I just missed it when skimming the diff!)

Nevermind, just saw it allll the way down at the end of the diff 👍

Copy link
Contributor

@rossbar rossbar left a comment

Choose a reason for hiding this comment

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

LGTM, thanks @cnpryer !

@rossbar rossbar merged commit 3c0f096 into networkx:main Feb 9, 2024
41 of 42 checks passed
@jarrodmillman jarrodmillman added this to the 3.3 milestone Feb 9, 2024
cvanelteren pushed a commit to cvanelteren/networkx that referenced this pull request Apr 22, 2024
Switch from blacken-docs to ruff-format for docstrings.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

None yet

4 participants