Closed George-Elhamy closed 5 days ago
To see the built version: https://qudi-core-testing.readthedocs.io/en/george/index.html
Sorry for again making numerous changes and for the force push. I rebased the PR with 2a3f75e41e47b4225abe9f3d6da8f8c2476ced87 and manually made the various fixes. This was a mess unfortunately. Hopefully the PR is easier to review now. I've tried to remove all the double quote changes and other formatting changes and other mistakes in the docstrings and licenses etc.
Runs on dummy with "load all modules". So indentation in (non-docstring) code seems fine.
Is the double-dot ..
in the license/copyright disclaimer needed? Seems weird to introduce this in all files since it is not required for a simple text body as far as I understand.
It's indicating to sphinx to not render the license for the documentation of every class. Is there another way for achieving the same?
It's indicating to sphinx to not render the license for the documentation of every class. Is there another way for achieving the same?
Not from the top of my head but this documentation on docstring preprocessing seems promising. See also this post on stackoverflow as example.
It assumes that text at the top of the file is the module docstring and so the license also gets rendered along with the module docstring (if any). There might be some kind of workaround using regex to intercept the text and remove the license after Sphinx reads the text but before it starts parsing.
As discussed, we should revert ..
in the license text to make this PR mergeable now, as it's a undocumented workaround. Most likely, we can later add some ignore escape sequence to Sphinx's conf.py, like:
"""(c)
This file contains ...
"""(c)
Ok, I think this is ready to merge now. Fixed a few more docstrings that were not converted. Reverted the license back to remove the leading ..
. As discussed, a style guide is necessary for things like when and where to use newlines in docstrings as Ruff will not handle these. I will add a brief description of it to the Ruff config.
Check that it still runs on dummy with "load all modules".
@Neverhorst We've addressed the remaining changes but can't merge till you approve.
Description
These changes are mainly on converting the already found docstrings in src into numpydoc style which is more readable and better looking when rendered in sphinx and this has been done in two different commits. Along with that, the license have also been hidden from rendering (it still shows in the code in every rst file in the src & it also still shows in the documentation but only in the license section) and this has been done on two commits. There is also two python scripts included in the first commit that claculate the documentation coverage in the whole project so that we can track the coverage as we go on with adding the missing documentation for methods and classes.
Motivation and Context
How Has This Been Tested?
Screenshots (only if appropriate, delete if not):
Types of changes
Checklist:
/docs/changelog.md
.