-
Notifications
You must be signed in to change notification settings - Fork 5
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
numpy-ify doctstrings #339
Comments
Adds a docstring in the style discussed in psyinfra#339. This test modifies an asset in OnyoRepo with an external function so that the cache is not up-to-date, and then tests the function `OnyoRepo.clear_caches()` to re-load the cache.
Gives the function a new docstring in the style discussed in issue psyinfra#339. The test modifies an OnyoRepo with the python implementations of the commands and then calls `generate_commit_message()` and checks the default commit message that was generated.
Gives the function a new docstring in the style discussed in issue psyinfra#339. The test modifies an OnyoRepo with the python implementations of the commands and then calls `generate_commit_message()` and checks the default commit message that was generated. There is the idea to change the commit message body in a future PR. This would impact parts of the test function written now, and I assume the current test should help as a starting point to test the new format.
Gives the function a new docstring in the style discussed in issue psyinfra#339.
Gives the function a new docstring in the style discussed in issue psyinfra#339. Also normalizes type hints e.g. usage of `Optional`, and other code style aspects.
Adds a docstring in the style discussed in psyinfra#339. This test modifies an asset in OnyoRepo with an external function so that the cache is not up-to-date, and then tests the function `OnyoRepo.clear_caches()` to re-load the cache.
Gives the function a new docstring in the style discussed in issue psyinfra#339. The test modifies an OnyoRepo with the python implementations of the commands and then calls `generate_commit_message()` and checks the default commit message that was generated. There is the idea to change the commit message body in a future PR. This would impact parts of the test function written now, and I assume the current test should help as a starting point to test the new format.
Gives the function a new docstring in the style discussed in issue psyinfra#339. The test modifies an OnyoRepo with the python implementations of the commands and then calls `generate_commit_message()` and checks the default commit message that was generated. There is the idea to change the commit message body in a future PR. This would impact parts of the test function written now, and I assume the current test should help as a starting point to test the new format.
In the absence of a strong opinion, I like going with your experience. :-) It looks like the numpy style is already introduced to the codebase, so I'd say it's fairly well decided to use it. Regarding the type hints, there's a numpy issue about this (of course, Yarik has already weighed in ;-). There's no resolution, but some have success with sphinx-autodoc-typehints. |
I have updated the issue title. If you feel that was premature, please share your objections. :-) |
As far as I see, we decided to go redundant with the type hints after all, and begin applying it to all functions we touch. Since we have more specific issues regarding documentation/docstrings, I close this issue. |
In order to have
we should decide on a style that works for us. Generally, I like the numpy style. With type hints being implemented already, it would be nice to figure whether this can easily be rendered and linted if we simply leave out the types in the docstrings.
Generally, actually rendering developer docs is a different task, but should probably be considered in conjunction with this issue.
README
(or aCONTRIBUTING
doc)The text was updated successfully, but these errors were encountered: