-
Notifications
You must be signed in to change notification settings - Fork 208
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
EPIC: SonarCloud error reduction #9878
Comments
#612 should probably be pointed out from here. |
I would strongly suggest reviewing the rules for Typescript files before starting any refactoring work based on it. From what I've seen so far, Sonarcloud has a bunch of arbitrary rules that don't align with our code style and the suggestions are not applicable. If possible, we would like to only use security related rules from Sonar, we mostly use ESLint and Prettier to enforce coding style on the frontend. |
Absolutely! I will start considering Java rules at the moment, then we'll tackle Typescript and Python with the same approach: find and discuss what rules should be removed, then fix the others. |
I already opened two PR about this issue, but I am thinking about completing this issue as soon as possible. can i take the lead in java? |
No, please wait. I have still to complete a lot of stuff there. We must proceed in an orderly manner, avoiding overlapping. |
I think I quoted the wrong comment. I want to quote @cbosdo’s comment about #612, but I will wait until your presentation. |
Taking the lead and completely remove them all is a huge task. I would rather recommend that you pick a class with issues and fix them. Once the PR is ready, move to another one. Small bites are the only way to go here. I believe there are other persons interested in this one. Better continue the discussion on the corresponding issue to avoid polluting this general one. |
Short description
Current status of the overall issues and errors detected by the SonarCloud instance running on the Uyuni project (https://sonarcloud.io/project/overview?id=uyuni-project_uyuni) shows more than 7000 issues/errors.
With this number of issues, the usability of the tool becomes much less effective.
The overall idea is to tackle the problems to reduce them over time at a manageable number, so that any issue due to new code can be immediately spotted.
How to tackle the problem
A possible approach should be "one slice at a time". Here below are some proposed steps after a first analysis:
It is worth fixing the last 3 languages at the start, and we should focus on tackling the Java issues as first step.
These 11 rules should be put under public discussion and a poll for removal should be issued. The rules that receive the majority of votes to be removed, will be deactivated on SonarCloud analysis for Uyuni.
Analysis by rule/removal candidate/good first issue
A spreadsheet with a first analysis of the affected rules, classified by number of issues, rule, removal candidate, good first issue, can be downloaded here: #9881
Polls and discussions on potential removal candidate rules:
Issues and PRs fixing SonarCloud errors
#9884 SonarCloud error reduction: HTML issues
#9885 SonarCloud security hotspot fix: using https instead of http
#612 Fix unchecked types warnings
All open pull requests
https://github.com/uyuni-project/uyuni/pulls?q=is%3Aopen+is%3Apr+label%3Asonar-cloud-error-reduction
All open issues
https://github.com/uyuni-project/uyuni/issues?q=is%3Aissue%20state%3Aopen%20label%3Asonar-cloud-error-reduction%20no%3Atype
The text was updated successfully, but these errors were encountered: