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

[REF] Reformat rapidtide parser and usage documentation #46

Merged
merged 3 commits into from
Oct 27, 2020

Conversation

tsalo
Copy link
Contributor

@tsalo tsalo commented Oct 27, 2020

Closes None. I should have opened an issue about this before opening this PR, but I wanted exhibit some changes I was hoping to make to the package with a test case (the rapidtide parser).

Changes proposed in this pull request:

  • Run black on workflows/rapidtide_parser.py and workflows/parser_funcs.py. This standardizes the style a bit and should help with PEP8-related issues. Plus, it has the added benefit of minimizing future diffs, which will make it easier to review changes.
  • Switch from printing messages to logging them in workflows/rapidtide_parser.py (related to Switch from printing to logging messages #41).
  • Add some argument group-level descriptions (in addition to the titles) in workflows/rapidtide_parser.py.
  • Adopt UpperCamelCase for a class in workflows/parser_funcs.py, to match PEP8 convention.
  • Adopt CAPITALCASE for constants in workflows/parser_funcs.py, to match PEP8 convention.
  • Clean up a few heading levels in docs/usage.rst, and add a comment that documents the levels for easy reference (I kept confusing myself).
  • Use code formatting in a couple of places in docs/usage.rst, which might make referencing arguments a little easier.
  • Hide debugging-related arguments in the argparse-generated documentation in docs/usage.rst. I didn't actually know about this feature before now, and it's pretty cool!

docs/usage.rst Show resolved Hide resolved
@bbfrederick bbfrederick marked this pull request as ready for review October 27, 2020 17:54
@bbfrederick bbfrederick merged commit d8bc42e into bbfrederick:dev Oct 27, 2020
@tsalo tsalo deleted the reformat-parser branch October 27, 2020 18:20
@tsalo
Copy link
Contributor Author

tsalo commented Oct 27, 2020

Based on the pattern of changes you saw in this PR, how do you feel about running an automated code formatter like black on rapidtide? I was thinking that it might be good to run right before you do the official 2.0.0 release.

@bbfrederick
Copy link
Owner

All for it. Especially if it will shut PyCharm up about PEP8 violations.

@tsalo
Copy link
Contributor Author

tsalo commented Oct 27, 2020

Awesome! I'll open an issue, and it can wait until just prior to the official release of 2.0.0.

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