pandas
pandas copied to clipboard
DOC: fix PR01 errors in docstrings
Pandas has a script for validating docstrings:
https://github.com/pandas-dev/pandas/blob/719e4a638a4383b859d684db4ad4f7e471a58aaa/ci/code_checks.sh#L144-L467
Currently, some methods fail the PR01 check.
The task here is:
- take 2-4 methods
- run: scripts/validate_docstrings.py --format=actions --errors=PR01
method-name
- check if validation docstrings passes for those methods, and if it’s necessary fix the docstrings according to whatever error is reported
- remove those methods from code_checks.sh
- commit, push, open pull request
Please don't comment take as multiple people can work on this issue. You also don't need to ask for permission to work on this, just comment on which methods are you going to work.
If you're new contributor, please check the contributing guide
I don't have permission to add them, but this could probably use some labels:
- CI
- Docs
- good first issue
Addresses https://github.com/pandas-dev/pandas/pull/57358
Thanks @Deen-dot for fixing
pandas.Grouper
pandas.core.groupby.DataFrameGroupBy.cummax
pandas.core.groupby.DataFrameGroupBy.cummin
pandas.core.groupby.DataFrameGroupBy.cumprod
pandas.core.groupby.DataFrameGroupBy.cumsum
pandas.core.groupby.DataFrameGroupBy.filter
pandas.core.groupby.DataFrameGroupBy.pct_change
pandas.core.groupby.DataFrameGroupBy.rolling
pandas.core.groupby.SeriesGroupBy.nunique
pandas.core.groupby.SeriesGroupBy.cummax
pandas.core.groupby.SeriesGroupBy.cummin
pandas.core.groupby.SeriesGroupBy.cumprod
pandas.core.groupby.SeriesGroupBy.cumsum
pandas.core.groupby.SeriesGroupBy.cumprod
I'll take:
pandas.Categorical
pandas.Categorical.__array__
Opened a fix for
pandas.CategoricalIndex.equals
pandas.CategoricalIndex.map
I'll take
pandas.ExcelFile
pandas.ExcelFile.parse
I'll take
pandas.DataFrame.at_time
pandas.DataFrame.backfill
opened a PR for
pandas.melt
pandas.option_context
pandas.read_fwf
pandas.reset_option
I would like to work on these if they are not taken:
pandas.Index.get_indexer_for
pandas.Index.identical
they are lines 420-421 on pandas/ci/code_checks.sh (I am new to working on open-source repo's so I don't know how to make the format of the above lines look good)
Hi all, if CI: speedup docstring check consecutive runs #57826 gets merged in, I might be reworking our approach here; this would look like closing the following issues:
DOC: fix GL08 errors in docstrings DOC: fix PR01 errors in docstrings DOC: fix PR07 errors in docstrings DOC: fix SA01 errors in docstrings DOC: fix RT03 errors in docstrings DOC: fix PR02 errors in docstrings
And opening a new issue to address these based on the new approach.
tl;dr
the work can still be done, but probably under a new ticket once #57826 is merged in
Closed by: CI: speedup docstring check consecutive runs #57826 CI: Better error control in the validation of docstrings #57879
Opening a new issue to fix docstring errors.
Opened DOC: Enforce Numpy Docstring Validation (Parent Issue) #58063 as a parent issue for fixing docstrings based on the refactoring in code_checks.sh
Feel free to swing by and help out! 🙂