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

dev(ingest): use ruff instead of flake8 #12359

Merged
merged 7 commits into from
Jan 16, 2025

Conversation

anshbansal
Copy link
Collaborator

@anshbansal anshbansal commented Jan 15, 2025

Once this is in then can replace black and isort one by one in followup PRs

Checklist

  • The PR conforms to DataHub's Contributing Guideline (particularly Commit Message Format)
  • Links to related issues (if applicable)
  • Tests for the changes have been added/updated (if applicable)
  • Docs related to the changes have been added/updated (if applicable). If a new feature has been added a Usage Guide has been added for the same.
  • For any breaking change/potential downtime/deprecation/big changes an entry has been made in Updating DataHub

@github-actions github-actions bot added the ingestion PR or Issue related to the ingestion of metadata label Jan 15, 2025
@datahub-cyborg datahub-cyborg bot added the needs-review Label for PRs that need review from a maintainer. label Jan 15, 2025
Copy link

codecov bot commented Jan 15, 2025

Codecov Report

Attention: Patch coverage is 77.77778% with 2 lines in your changes missing coverage. Please review.

✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
...ion/source/powerbi/rest_api_wrapper/powerbi_api.py 66.66% 2 Missing ⚠️
Files with missing lines Coverage Δ
...n/src/datahub/ingestion/source/ge_data_profiler.py 72.12% <ø> (+0.15%) ⬆️
...ata-ingestion/src/datahub/ingestion/source/mode.py 86.08% <ø> (ø)
...tion/src/datahub/ingestion/source/sql/sql_types.py 78.46% <ø> (ø)
...ngestion/src/datahub/utilities/memory_footprint.py 95.45% <100.00%> (+0.21%) ⬆️
...ion/source/powerbi/rest_api_wrapper/powerbi_api.py 90.59% <66.66%> (ø)

... and 1 file with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a3c7a33...72bfce2. Read the comment docs.

Copy link
Collaborator

@hsheth2 hsheth2 left a comment

Choose a reason for hiding this comment

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

Looking good so far

Eventual goal is to remove black and isort entirely across all of our plugins. We should probably think about how to standardize lint rules/configs across all of our python packages - but that's not a blocker for this

metadata-ingestion/setup.py Show resolved Hide resolved
@@ -267,7 +267,6 @@ def _is_single_row_query_method(query: Any) -> bool:
"get_column_max",
"get_column_mean",
"get_column_stdev",
"get_column_stdev",
Copy link
Collaborator

Choose a reason for hiding this comment

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

?

Copy link
Collaborator Author

@anshbansal anshbansal Jan 15, 2025

Choose a reason for hiding this comment

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

There were duplicates in this just above on line 269.

@@ -384,7 +384,6 @@ def resolve_snowflake_modified_type(type_string: str) -> Any:
"varchar": StringType,
"char": StringType,
"varbinary": BytesType,
"json": RecordType,
Copy link
Collaborator

Choose a reason for hiding this comment

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

why'd we remove this?

Copy link
Collaborator Author

@anshbansal anshbansal Jan 15, 2025

Choose a reason for hiding this comment

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

Duplicate in this dictionary. See the last element

metadata-ingestion/pyproject.toml Show resolved Hide resolved
metadata-ingestion/pyproject.toml Outdated Show resolved Hide resolved
@datahub-cyborg datahub-cyborg bot added pending-submitter-response Issue/request has been reviewed but requires a response from the submitter and removed needs-review Label for PRs that need review from a maintainer. labels Jan 15, 2025
@datahub-cyborg datahub-cyborg bot added needs-review Label for PRs that need review from a maintainer. and removed pending-submitter-response Issue/request has been reviewed but requires a response from the submitter labels Jan 16, 2025
@anshbansal anshbansal requested a review from hsheth2 January 16, 2025 00:15
"C90",
"E",
"F",
"TID",
Copy link
Collaborator

Choose a reason for hiding this comment

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

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

added

@datahub-cyborg datahub-cyborg bot added pending-submitter-merge and removed needs-review Label for PRs that need review from a maintainer. labels Jan 16, 2025
@anshbansal anshbansal merged commit 2226820 into master Jan 16, 2025
193 of 195 checks passed
@anshbansal anshbansal deleted the ab-2025-jan-16-flake8-to-ruff branch January 16, 2025 02:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ingestion PR or Issue related to the ingestion of metadata pending-submitter-merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants