-
Notifications
You must be signed in to change notification settings - Fork 373
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
[lint] Remove pylint and switch to ruff for Hue backend linting #3703
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Harshg999
requested review from
wing2fly,
amitsrivastava,
tabraiz12,
JohanAhlen,
bjornalm,
ranade1,
athithyaaselvam and
agl29
April 17, 2024 12:58
Harshg999
force-pushed
the
introduce-ruff
branch
from
April 17, 2024 16:11
0cc4a22
to
8b04d77
Compare
Harshg999
changed the title
[ruff] Introduce ruff and remove pylint from Hue
[lint] Remove pylint and switch to ruff for Hue backend linting
Apr 17, 2024
… the lint command
amitsrivastava
approved these changes
Apr 17, 2024
bjornalm
approved these changes
Apr 17, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, see comments and questions :-)
wing2fly
approved these changes
Apr 17, 2024
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good to move to MIT kind of lib!
athithyaaselvam
pushed a commit
that referenced
this pull request
Jun 10, 2024
…inting (#3703) - Current pylint setup in Hue was linting staged changes only by checking for 3 rules. - Also pylint is comparatively slow and GPL licensed. - Switching to ruff has its own perks which are mentioned on: https://docs.astral.sh/ruff/ and it's MIT licensed. - For starters, it's waaayyy faster, can auto-fix errors and work as both linter and formatter replacing a lot of latest packages (like a all-in-one solution). - It is also supporting pylint rules which is WIP: astral-sh/ruff#970 - Currently this PR only targets the minimal transition from pylint to ruff. Iteratively, we will extend the rules to improve the Hue codebase, add its pre-commit and play around auto-fixing errors capability. This will also help in making our codebase more PEP8 compliant. - Ruff still does not support pylint's `W0311(bad-indentation)` rule which was present earlier with pylint in Hue. We will update it later when the support lands in a future release. - Manually in local setup. (cherry picked from commit 264a267) (cherry picked from commit 8aa919d946ba8d49add26261a3789b7013ef8566) Change-Id: Ia5388cabfea5a2fa491738e86f2ce49e3dd0fe0a (cherry picked from commit 76e9ad2b0aab0cc7e062ef3fd9a3e4b698f7bbe9)
Alterrien
pushed a commit
to Alterrien/hue
that referenced
this pull request
Dec 19, 2024
…dera#3703) ## What changes were proposed in this pull request? - Current pylint setup in Hue was linting staged changes only by checking for 3 rules. - Also pylint is comparatively slow and GPL licensed. - Switching to ruff has its own perks which are mentioned on: https://docs.astral.sh/ruff/ and it's MIT licensed. - For starters, it's waaayyy faster, can auto-fix errors and work as both linter and formatter replacing a lot of latest packages (like a all-in-one solution). - It is also supporting pylint rules which is WIP: astral-sh/ruff#970 - Currently this PR only targets the minimal transition from pylint to ruff. Iteratively, we will extend the rules to improve the Hue codebase, add its pre-commit and play around auto-fixing errors capability. This will also help in making our codebase more PEP8 compliant. #### Note - Ruff still does not support pylint's `W0311(bad-indentation)` rule which was present earlier with pylint in Hue. We will update it later when the support lands in a future release. ## How was this patch tested? - Manually in local setup.
tabraiz12
pushed a commit
that referenced
this pull request
Jan 27, 2025
…inting (#3703) - Current pylint setup in Hue was linting staged changes only by checking for 3 rules. - Also pylint is comparatively slow and GPL licensed. - Switching to ruff has its own perks which are mentioned on: https://docs.astral.sh/ruff/ and it's MIT licensed. - For starters, it's waaayyy faster, can auto-fix errors and work as both linter and formatter replacing a lot of latest packages (like a all-in-one solution). - It is also supporting pylint rules which is WIP: astral-sh/ruff#970 - Currently this PR only targets the minimal transition from pylint to ruff. Iteratively, we will extend the rules to improve the Hue codebase, add its pre-commit and play around auto-fixing errors capability. This will also help in making our codebase more PEP8 compliant. - Ruff still does not support pylint's `W0311(bad-indentation)` rule which was present earlier with pylint in Hue. We will update it later when the support lands in a future release. - Manually in local setup. (cherry picked from commit 264a267) (cherry picked from commit 8aa919d946ba8d49add26261a3789b7013ef8566) Change-Id: Ia5388cabfea5a2fa491738e86f2ce49e3dd0fe0a
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What changes were proposed in this pull request?
Note
W0311(bad-indentation)
rule which was present earlier with pylint in Hue. We will update it later when the support lands in a future release.How was this patch tested?