-
-
Notifications
You must be signed in to change notification settings - Fork 25.9k
MNT Update sklearn.externals._lobpcg.lobpcg docstring according to https://github.com/scipy/scipy/pull/16432 #23597
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
MNT Update sklearn.externals._lobpcg.lobpcg docstring according to https://github.com/scipy/scipy/pull/16432 #23597
Conversation
14c4b55
to
32af96f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm okay with this temporary solution.
My preferred solution is to debug what the issue is on your system and fix get_all_functions_names
itself. I am not able to reproduce the issue on my system so it's harder for me to debug.
…dule doesn't work on some systems Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
But we should already ignore it, isn't it: scikit-learn/sklearn/tests/test_docstrings.py Lines 156 to 166 in 2f787f4
|
Yes, it should be ignored. But for some unknown reason the test runs and fails on my local machine. Since there is already another function of the externals module listed in |
The Scipy devs fixed the docstring themselves scipy/scipy#16432. I updated this PR accordingly. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
With SciPy updated, I am okay with correcting here to keep in sync with SciPy.
Thanks @Diadochokinetic Merging |
…ipy/scipy#16432 (scikit-learn#23597) Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
…ipy/scipy#16432 (scikit-learn#23597) Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
…ipy/scipy#16432 (#23597) Co-authored-by: Thomas J. Fan <thomasjpfan@gmail.com>
Reference Issues/PRs
Fixes #23596
What does this implement/fix? Explain your changes.
pytest -vl sklearn/tests/test_docstrings.py -k test_docstring
throws a ValueError forsklearn.externals._lobpcg.lobpcg
. A quick fix would be to add the function to FUNCTION_DOCSTRING_IGNORE_LIST and simply exclude it from the test. A proper fix would be to actually fix the errors on the docstring:E # Errors
E
E - GL03: Double line break found; please use only one blank line to separate sections or paragraphs, and do not leave blank lines at the end of docstrings
E - SS03: Summary does not end with a period
E - PR08: Parameter "Y" description should start with a capital letter
E - RT05: Return value description should finish with "."
Edit: Fixing the docstring wasn't that hard. Therefore I suggest to go for that solution.
Any other comments?
I started by simply adding the function to the ignore list. Then I fixed the docstring and removed the function from the ignore list. Now the tests run successfully.
EDIT: The externals module should actually be excluded from docstring tests. It is unknown, why it happens on my local machine. Since there is already a function from the externals module listet in FUNCTION_DOCSTRING_IGNORE_LIST, this probably happened before. Therefore simply adding it to the ignored list is preferred.