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

ci: Use Ruff to lint project #1462

Merged
merged 1 commit into from
Mar 1, 2023
Merged

Conversation

edgarrmondragon
Copy link
Collaborator

@edgarrmondragon edgarrmondragon commented Feb 27, 2023

This PR introduces a few Ruff checks without being too aggressive. We can add more rules progressively.

In the meantime:

  • Auto-fixed unused imports (F401)
  • Fixed some unused variables and redefined test functions
  • Fixed docstring conventions in singer_sdk/helpers/_state.py
  • Fixed some imports and removed isort from pre-commit

Can't get rid of flake8 entirely yet due to astral-sh/ruff#458

Closes #1242


📚 Documentation preview 📚: https://meltano-sdk--1462.org.readthedocs.build/en/1462/

@edgarrmondragon edgarrmondragon linked an issue Feb 27, 2023 that may be closed by this pull request
@codecov
Copy link

codecov bot commented Feb 27, 2023

Codecov Report

Merging #1462 (2029dd8) into main (10ff04f) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main    #1462   +/-   ##
=======================================
  Coverage   85.46%   85.46%           
=======================================
  Files          57       57           
  Lines        4760     4760           
  Branches      809      809           
=======================================
  Hits         4068     4068           
  Misses        501      501           
  Partials      191      191           
Impacted Files Coverage Δ
singer_sdk/helpers/_flattening.py 72.72% <ø> (ø)
singer_sdk/helpers/_state.py 69.44% <ø> (ø)
singer_sdk/typing.py 94.94% <ø> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@edgarrmondragon edgarrmondragon force-pushed the 1242-feature-lint-code-with-ruff branch 2 times, most recently from e8d9cd5 to e0feb44 Compare March 1, 2023 04:40
@edgarrmondragon edgarrmondragon marked this pull request as ready for review March 1, 2023 04:40
- Auto-fixed unused imports (F401)
- Fixed some unused variables and redefined test functions
- Fixed docstring conventions in `singer_sdk/helpers/_state.py`
- Fixed some imports and removed `isort` from pre-commit

Can't get rid of flake8 entirely yet due to astral-sh/ruff#2459
@edgarrmondragon edgarrmondragon force-pushed the 1242-feature-lint-code-with-ruff branch from e0feb44 to 2029dd8 Compare March 1, 2023 18:28
Copy link
Contributor

@aaronsteers aaronsteers left a comment

Choose a reason for hiding this comment

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

Nice. 👍

I'd love to have another engineer also approve, but this looks good to me.

@edgarrmondragon edgarrmondragon merged commit dc64d27 into main Mar 1, 2023
@edgarrmondragon edgarrmondragon deleted the 1242-feature-lint-code-with-ruff branch March 1, 2023 21:28
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.

[Feature]: Lint code with Ruff
3 participants