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

Linting and Formatting #44

Merged
merged 12 commits into from
Jan 11, 2024
Merged

Linting and Formatting #44

merged 12 commits into from
Jan 11, 2024

Conversation

havok2063
Copy link
Collaborator

This PR runs the ruff linting and formatting (which uses black) across the DRP. Where it couldn't apply automatic fixes, I tried to resolve all the linting errors as best I could. The linting errors fell into the following categories:

  • use of from x import * - I tried to resolve these as best I could.
  • use of bare except: in try block - I changed these to except Exception: to catch generally but that shouldn't be done either. I wasn't sure what exception to catch on.
  • gmosMethod and vimosMethod - These modules don't seem used anymore. Some functions referenced in these do not exist.
  • lots of variable xxx is defined but unused, and variable xxx undefined - I commented out these lines to keep the original line, in case these should be in.
  • missing function definitions in core/fluxcal.py - these still need to be resolved. Not sure what to do here? See the Action error log. Looks like this is a straight IDL ports. Maybe missing functions?

I have turned on the ruff linting in the Github Action workflow, so it will run on every commit now. If it finds errors it will fail and they'll need to be resolved so the checks pass, before we can merge any PR.

@ajmejia you may want to do some spot checks to make sure I didn't mess anything up

@havok2063 havok2063 added the enhancement New feature or request label Nov 29, 2023
@havok2063 havok2063 self-assigned this Nov 29, 2023
@havok2063 havok2063 requested a review from ajmejia as a code owner November 29, 2023 22:16
@ajmejia ajmejia merged commit 3bdf1e4 into master Jan 11, 2024
8 checks passed
@ajmejia ajmejia deleted the linting branch January 11, 2024 13:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants