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

Tweak docstrings to fix rendered docs #923

Merged
merged 3 commits into from Feb 21, 2024
Merged

Conversation

ml-evs
Copy link
Contributor

@ml-evs ml-evs commented Feb 18, 2024

In a similar vein to materialsproject/api#863, this PR makes several docstring fixes that are otherwise breaking the rendered mkdocs, making it quite hard for users to use the API without digging into the code.

  • Enable D411 ruff rule in pre-commit to ensure that sections are properly demarcated
  • Fix D415 missing punctuation at end of summary so that docstring formats get properly detected
  • Manually fix some broken docstrings in cases where indented code was erroneously treated as code snippets

Example from deployed docs:

2024-02-18-121757_705x632_scrot

Which will now look like:

2024-02-18-121734_781x657_scrot

There are still hundreds of pydocstyle warnings but I think this at least fixes the ones that mkdocs(trings) will care about.

Copy link

codecov bot commented Feb 21, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (53867d9) 81.56% compared to head (60d2622) 81.56%.
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #923   +/-   ##
=======================================
  Coverage   81.56%   81.56%           
=======================================
  Files          46       46           
  Lines        3938     3938           
=======================================
  Hits         3212     3212           
  Misses        726      726           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@rkingsbury rkingsbury merged commit f5f5593 into materialsproject:main Feb 21, 2024
10 checks passed
@rkingsbury
Copy link
Collaborator

Thanks very much @ml-evs !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants