-
-
Notifications
You must be signed in to change notification settings - Fork 18.1k
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
DOC: fix SA05 errors in docstrings #57392
Comments
I don't have permission to add them, but this could probably use some labels:
|
Addresses #57352 |
I'll take
|
I'll take
|
I'll take |
I found a small fix that resolved all of the ExponentialMovingWindow, Expanding, Rolling, and Window SA05 errors (and pandas.plotting.boxplot). This fix takes care of the following:
|
I think this is the updated list of what's left:
|
Hey @jordan-d-murphy I can take SeriesGroupBy : first and last once my previous PR gets merged. |
Awesome! thank you 😊 |
Hey @jordan-d-murphy |
@Pistonamey Looks like your PR is merged now, can you check again? Sometimes there might by multiple reviewers on a PR and the first reviewer might add their approval review but leave it for another reviewer to merge. Looks like that was the case here Great work! Thank you for helping out 🙂 |
Got it, Thanks. |
I'll take
|
Seems like both are ok, even without changes. I'll just remove these two then. |
Hi @jordan-d-murphy, For
There is a ES01 -- No extended summary found error. If there a suggested fix to this? |
For the ES01 I have opened a PR to get these addressed. See #57359 I have a merge conflict to resolve in order to get that merged, and then I'll open an Issue to fix all ES01 errors. (Similar to this issue) Hopefully that will happen later today when I get home from work. I need to do that from my personal laptop. But feel free to fix it if you want to! The ultimate goal of All these issues I'm opening is to have correct docstrings for all the functions. I'm segmenting them out to give some structure to the process, but a fully correct docstring for each function is the end goal! (Typing this from my phone is it's hard to explain the fix for ES01, but when I get back to my personal laptop I'll share more info on those fixes. For PRs opened under this issue it's okay if other errors show up, as long as the SA05 errors are resolved.) |
I'll take
|
@williamking1221 #57440 for ESO1s |
Thanks @jordan-d-murphy! I will pull from main, which as the ignore ES01 checks, and then raise a PR for
Do you have a link to a doc on resolving ES01 issues? |
I believe if this PR goes through, this issue can be closed. |
@williamking1221 Yeah here's some info on the ES01s from what I understand. I'll show two examples to illustrate:
and running
If we look at the docstrings, we can see a difference: pandas.Categorical.array (fails with one ES01 - see the higlighted single line summary) pandas.Categorical.map (passes with no ES01 - See highlighted Extended Summary) Adding an extended summary fixes this: updated output:
I dont' know if that answers the question, but hopefully that's a start. EDIT: I just want to be clear this is an example of HOW to resolve the issue, but call out that we shouldn't just start adding meaningless extended summaries in order to pass the checks. |
@williamking1221 thanks for opening the issue to close this out, I added one comment as a suggestion to ensure the integrity of the SA05 checks |
Thanks for this! Btw, is your comment on the PR I raised? |
yeah if you open your pr it should show as a review comment |
I don't see it, could you please double check if it went through? Thanks! |
I tagged you can you see it now? |
Fixed it. Please take a look if this is what we want it to be. |
@williamking1221 What we were talking about was adding SA05 here Lines 68 to 70 in 43209e7
when we remove the block here Lines 3185 to 3187 in 43209e7
|
Ah gotcha! Thanks! Fixed it in recent commit. |
for anyone interested, I've opened some similar issues: |
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! 🙂 |
Pandas has a script for validating docstrings:
pandas/ci/code_checks.sh
Lines 145 to 206 in 1d7aedc
Currently, some methods fail the SA05 check.
The task here is:
method-name
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
The text was updated successfully, but these errors were encountered: