Skip to content

[fmt]: Updated black version to 26 - #5564

Merged
RMeli merged 3 commits into
MDAnalysis:developfrom
jpkrowe:black-update
Dec 1, 2026
Merged

RMeli merged 3 commits into
MDAnalysis:developfrom
jpkrowe:black-update

Conversation

@jpkrowe

@jpkrowe jpkrowe commented Nov 28, 2026 •

Copy link
Copy Markdown
Contributor

Fixes #5553

Changes made in this Pull Request:

  • Updated the black version from 24 to 26.
  • A number of files have been changed - mostly removing whitespaces in docstrings and removing brackets from assignments of variables.

LLM / AI generated code disclosure

  • I have read and understood MDAnalysis's AI policy in AI_POLICY.md.

LLMs or other AI-powered tools (beyond simple IDE use cases) were used in this contribution: no

PR Checklist

  • Issue raised/referenced?
  • Tests updated/added?
  • Documentation updated/added?
  • package/CHANGELOG file updated?
  • Is your name in package/AUTHORS? (If it is not, add it!)
  • I have read and understand the current AI Policy
  • LLM/AI disclosure was updated.

Developers Certificate of Origin

I certify that I can submit this code contribution as described in the Developer Certificate of Origin, under the MDAnalysis LICENSE.

@read-the-docs-community

read-the-docs-community Bot commented Nov 28, 2026 •

Copy link
Copy Markdown

@codecov

codecov Bot commented Nov 28, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 97.35450% with 5 lines in your changes missing coverage. Please review.
✅ Project coverage is 93.96%. Comparing base (f4ffee3) to head (65155ff).

Files with missing lines Patch % Lines
package/MDAnalysis/coordinates/base.py 92.98% 4 Missing ⚠️
package/MDAnalysis/analysis/bat.py 75.00% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #5564      +/-   ##
===========================================
+ Coverage    93.93%   93.96%   +0.03%     
===========================================
  Files          184      184              
  Lines        22679    22679              
  Branches      3228     3228              
===========================================
+ Hits         21303    21310       +7     
+ Misses         916      911       -5     
+ Partials       460      458       -2     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@orbeckst orbeckst left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Please add a second commit where you record the commit of the all the black changes in .git-blame-ignore-revs. Then this PR must be merged to keep the individual commits intact.

@jpkrowe

jpkrowe commented Nov 29, 2026

Copy link
Copy Markdown
Contributor Author

Thanks @orbeckst for reviewing, I have now added that change to .git-blame-ignore-revs.

@RMeli RMeli left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks. I think it is time to format everything in one go, so I suggest to remove the extend-exclude which still excludes some files. (Please remember to add the subsequent formatting again to .git-blame-ignore-revs.)

Comment thread package/pyproject.toml
)
'''
required-version = '24'
required-version = '26'

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

While at it, can you also remove the extend-exclude above so that everything is finally formatted?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I have removed these sections in both the package and testsuite. The coordinates/base.py file caused some issues with pylint that I have now fixed

Comment thread testsuite/pyproject.toml
)
'''
required-version = '24'
required-version = '26'

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

While at it, can you also remove the extend-exclude above so that everything is finally formatted?

The # pylint: disable=assignment-from-no-return in the
_read_frame_with_aux method is no longer necessary

@RMeli RMeli left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Looks great, thank you!

@RMeli
RMeli merged commit a266d0e into MDAnalysis:develop Dec 1, 2026
35 of 36 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Maint] update black version

3 participants