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 Doc Linting to CI #280

Merged
merged 2 commits into from
Apr 4, 2020
Merged

Add Doc Linting to CI #280

merged 2 commits into from
Apr 4, 2020

Conversation

kidrahahjo
Copy link
Collaborator

Description

We are using pydocstyle to check that our document strings are in the numpy docstring style. The configuration for pydocstyle is in setup.cfg. I chose flow/utils/template_filters.py as the first file for testing this, feel free to suggest another file if you think there is a better candidate

Motivation and Context

Replicates glotzerlab/signac#294 for signac-flow
Fixes glotzerlab/signac-flow#276

Types of Changes

  • Documentation update
  • Bug fix
  • New feature
  • Breaking change1

1The change breaks (or has the potential to break) existing functionality.

Checklist:

If necessary:

  • I have updated the API documentation as part of the package doc-strings.
  • I have created a separate pull request to update the framework documentation on signac-docs and linked it here.
  • I have updated the changelog.

@kidrahahjo kidrahahjo requested review from a team as code owners April 1, 2020 15:37
@kidrahahjo
Copy link
Collaborator Author

I guess the pre-test-checks test won't fail because flow/utils/template_filters.py is documented according to the numpy docstring style.

@vyasr
Copy link
Contributor

vyasr commented Apr 1, 2020

If you look at the pydocstyle documentation, you'll see that it autodetects the style of docstrings. So for now it's working by detecting our current style, but as docstrings change to numpy style it should automatically detect that and switch. It's not immediately clear from the documentation if it detects on a per-docstring, per-file, or per-project level. It suggests that it's per-docstring, but we'll have to figure that out as we go along. As @CryoZEUS starts converting files we can start testing them by whitelisting the appropriate files.

@vyasr vyasr requested review from a team, klywang and vyasr and removed request for a team April 1, 2020 16:54
Copy link
Contributor

@vyasr vyasr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@klywang I'm going to go ahead and merge this PR since it's a pretty small one.

@vyasr vyasr merged commit 215b252 into glotzerlab:master Apr 4, 2020
@kidrahahjo kidrahahjo deleted the doclint branch April 4, 2020 17:44
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.

Add doc linting to CI
2 participants