[ci] [python-package] enforce 'numpydoc-validation' and 'pydoclint' checks #7478

Open
jameslamb opened 4:57pm on October 1, 2026 wants to merge 325 Ξ” into microsoft/lightgbm main from
ci/pydoclint
Reviewing
284 fewer changed lines
(61% less) vs GitHub
This saves about 106.8 hours per year vs conventional diff tools
jameslamb authored
of work between September 30 and October 1
Diff Delta:
325
About 16 Diff Delta/hour
Classified as:  Bug Fix, Feature Add, General

jameslamb's Description of Work

Contributes to #7470

Proposes adding numpydoc-validation and pydoclint, 2 linters that enforce standardization and correctness of Python docstrings. These caught a few issues (like eval_{X,y} missing from the Dask docstrings.

Both are fast enough to not be noticeable.

I think they'll help a lot with consistency and standardization, and relieve a small bit of review burden.

Notes for Reviewers

I tried to choose configurations for these tools that as closely as possible match the project's current conventions. See inline comments below.

I've added this branch (temporarily) to readthedocs configuration.

11 total changed files
(1 file ignored)
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
Loading changes...
You’ve completed the full review pass
PR review complete, one step closer to shipping πŸš€