Skip to content

[pydocstyle] Fix numpy section ordering (D420)#23685

Merged
amyreese merged 1 commit intomainfrom
amy/numpy-docstring-sections
Mar 3, 2026
Merged

[pydocstyle] Fix numpy section ordering (D420)#23685
amyreese merged 1 commit intomainfrom
amy/numpy-docstring-sections

Conversation

@amyreese
Copy link
Member

@amyreese amyreese commented Mar 3, 2026

Matches numpydoc section ordering

Fixes #23682

Matches numpydoc section ordering

Fixes #23682
@astral-sh-bot
Copy link

astral-sh-bot bot commented Mar 3, 2026

ruff-ecosystem results

Linter (stable)

✅ ecosystem check detected no linter changes.

Linter (preview)

ℹ️ ecosystem check detected linter changes. (+6 -6 violations, +0 -0 fixes in 3 projects; 53 projects unchanged)

DisnakeDev/disnake (+2 -0 violations, +0 -0 fixes)

ruff check --no-cache --exit-zero --no-fix --output-format concise --preview

+ disnake/guild.py:5481:5: D420 Section "Attributes" appears after section "Examples" but should be before it
+ disnake/threads.py:1153:5: D420 Section "Attributes" appears after section "Examples" but should be before it

PlasmaPy/PlasmaPy (+0 -1 violations, +0 -0 fixes)

ruff check --no-cache --exit-zero --no-fix --output-format concise --preview

- src/plasmapy/utils/datatype_factory_base.py:77:5: D420 Section "Notes" appears after section "Attributes" but should be before it

astropy/astropy (+4 -5 violations, +0 -0 fixes)

ruff check --no-cache --exit-zero --no-fix --output-format concise --preview

+ astropy/io/votable/dataorigin.py:136:5: D420 Section "Attributes" appears after section "Notes" but should be before it
- astropy/io/votable/dataorigin.py:241:5: D420 Section "Notes" appears after section "Attributes" but should be before it
+ astropy/io/votable/dataorigin.py:77:5: D420 Section "Attributes" appears after section "Notes" but should be before it
- astropy/modeling/fitting.py:1464:5: D420 Section "Notes" appears after section "Attributes" but should be before it
+ astropy/nddata/ccddata.py:151:5: D420 Section "Methods" appears after section "Raises" but should be before it
- astropy/nddata/ccddata.py:162:5: D420 Section "Attributes" appears after section "Methods" but should be before it
+ astropy/nddata/ccddata.py:162:5: D420 Section "Attributes" appears after section "Raises" but should be before it
- astropy/nddata/ccddata.py:171:5: D420 Section "Notes" appears after section "Methods" but should be before it
- astropy/nddata/utils.py:582:5: D420 Section "Examples" appears after section "Attributes" but should be before it

Changes by rule (1 rules affected)

code total + violation - violation + fix - fix
D420 12 6 6 0 0

@amyreese amyreese added bug Something isn't working rule Implementing or modifying a lint rule labels Mar 3, 2026
@amyreese amyreese requested a review from ntBre March 3, 2026 00:33
@amyreese amyreese merged commit 189361e into main Mar 3, 2026
45 checks passed
@amyreese amyreese deleted the amy/numpy-docstring-sections branch March 3, 2026 16:13
carljm added a commit that referenced this pull request Mar 3, 2026
* main:
  [ty] Apply narrowing to walrus values (#23687)
  [`perflint`] Extend `PERF102` to comprehensions and generators (#23473)
  [ty] Fix GitHub-annotations mdtest output format (#23694)
  [ty] Reduce the number of potentially-flaky projects (#23698)
  [`pydocstyle`] Fix numpy section ordering (`D420`) (#23685)
  [ty] Move method-related types to a submodule (#23691)
  [ty] Avoid the mandatory "ecosystem-analyzer workflow run cancelled" notification every time you make a PR (#23695)
  [ty] Move `Type::subtyping_is_always_reflexive` to `types::relation` (#23692)
  Update conformance suite commit hash (#23693)
  [ty] Add mdtest suite for `typing.Concatenate` (#23554)
  [ty] filter out pre-loop bindings from loop headers (#23536)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working rule Implementing or modifying a lint rule

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Implemented Numpy docstring sections order convention different from numpydoc

2 participants