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

Dig into sonarcloud code smells reports #986

Closed
jcoupey opened this issue Sep 8, 2023 · 2 comments
Closed

Dig into sonarcloud code smells reports #986

jcoupey opened this issue Sep 8, 2023 · 2 comments

Comments

@jcoupey
Copy link
Collaborator

jcoupey commented Sep 8, 2023

Now that the workflow is in place after #984 and the most severe reports are fixed, there are different follow-up tasks here:

  1. identifying the rules we really want to comply to;
  2. find a way to silence the rules we do not want to take into account;
  3. update the codebase to gradually remove the remaining reports.
This was referenced Sep 18, 2023
@jcoupey jcoupey added this to the v1.14.0 milestone Sep 19, 2023
@jcoupey
Copy link
Collaborator Author

jcoupey commented Sep 20, 2023

So I did a lot of refactoring based on the code smell reports. There are probably remaining reports that could be easily fixed and I'll probably do that along the way with other PR. For now the most important remaining reports category are:

  1. Control flow statements nesting
  2. Use std::format instead of manual concatenations
  3. Cognitive complexity of functions

I don't want to address 1. and 3. right now because they would require deeper changes. Maybe those are the right places to use the improve-as-you-code approach targeted with the "new code" score.

I'd like to handle 2. but sadly support for format is not available in gcc 11 which is our current reference version on CI.

@jcoupey
Copy link
Collaborator Author

jcoupey commented Sep 20, 2023

Closing here as I don't think we want to silence any reports for now. We can just live with them and try to fix them as we go.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant