Skip to content
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

Add module for converting docstrings to numpydoc format #101

Merged
merged 6 commits into from
Sep 18, 2023

Conversation

taldcroft
Copy link
Member

Description

This provides a module (and eventually a command line script) to convert from ReST format docstrings to numpydocs format.

I spent some time trying to use the pyment package but found that it does not handle any docstring with inline examples. After an hour trying to make that package work I bailed. In the end some customization was useful -- we have used non-standard conventions in docstrings over the years and this code tries to do the best with what's there.

The ReST format which is used in most Ska packages is unsatisfactory because it does not really support indicating the type of input parameters. It is also a bit tired and doesn't look nice.

Interface impacts

None

Testing

Unit tests

  • No unit tests

Functional tests

See sot/chandra_aca#156 and rendered output in the description.

@taldcroft taldcroft changed the title WIP: Add module for converting docstrings to numpydoc format Add module for converting docstrings to numpydoc format Sep 13, 2023
@taldcroft
Copy link
Member Author

@javierggt - this includes some unrelated changes which fix ruff warnings. These are obvious in the diffs. Let me know if these are not OK.

@taldcroft taldcroft merged commit 1bedcec into master Sep 18, 2023
2 checks passed
@taldcroft taldcroft deleted the convert-numpydoc branch September 18, 2023 15:26
@javierggt javierggt mentioned this pull request Oct 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants