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 ruff lint and style checks #76

Merged
merged 5 commits into from
Apr 17, 2024
Merged

Add ruff lint and style checks #76

merged 5 commits into from
Apr 17, 2024

Conversation

jonchang
Copy link
Collaborator

@jonchang jonchang commented Apr 12, 2024

Pull Request

Description

This implements the ruff formatter and linter for automatic style checks using github actions.

Related Issues

See https://github.com/CDCgov/IDWA/blob/main/open_practices.md#recommended-practices, configuration for linters.

Additional Notes

Line length 118 was chosen because (at least last time I checked) it is the maximum width that the github diff viewer has before soft wrapping.

Checklist

Please review and complete the following checklist before submitting your pull request:

  • I have ensured that the pull request is of a manageable size, allowing it to be reviewed within a single session.
  • I have reviewed my changes to ensure they are clear, concise, and well-documented.
  • I have updated the documentation, if applicable.
  • I have added or updated test cases to cover my changes, if applicable.
  • I have minimized the number of reviewers to include only those essential for the review.
  • I have notified teammates in the review thread to build awareness.

Checklist for Reviewers

Please review and complete the following checklist during the review process:

  • The code follows best practices and conventions.
  • The changes implement the desired functionality or fix the reported issue.
  • The tests cover the new changes and pass successfully.
  • Any potential edge cases or error scenarios have been considered.

We aren't linting or formatting dedupe work.
@jonchang jonchang marked this pull request as ready for review April 16, 2024 18:22
@jonchang
Copy link
Collaborator Author

jonchang commented Apr 16, 2024

@derekadombek ready for review, I think. It should only check in the ocr/ directory now. dedupe/ can opt in by specifying something in pyproject.toml or ruff.toml, though I still think we should just have one standard for the entire repository to simplify things

@derekadombek
Copy link
Collaborator

@derekadombek ready for review, I think. It should only check in the ocr/ directory now. dedupe/ can opt in by specifying something in pyproject.toml or ruff.toml, though I still think we should just have one standard for the entire repository to simplify things

I personally don't mind either way how the workflows get divided. This will work but It's usually good to keep things uniform and standard across a repo and sticking with one method of doing it.

@derekadombek derekadombek self-requested a review April 16, 2024 21:30
Copy link
Collaborator

@zdeveloper zdeveloper left a comment

Choose a reason for hiding this comment

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

LGTM! Thank you!

@jonchang jonchang added this pull request to the merge queue Apr 17, 2024
Merged via the queue into main with commit c90d1e9 Apr 17, 2024
2 checks passed
@jonchang jonchang deleted the ruff-python-fixes branch April 17, 2024 16: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.

3 participants