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

fix: sonarcloud issues #243

Closed
wants to merge 9 commits into from
Closed

fix: sonarcloud issues #243

wants to merge 9 commits into from

Conversation

rishi-raj-jain
Copy link

fix #163
/claim #163

@rishi-raj-jain
Copy link
Author

@riderx

The current state shall bring down the number of issues nearly to resolved. How can I have a look at analysis of the PR I just contributed with your settings so that I can see the remaining sonar issues to solve?

@riderx
Copy link
Collaborator

riderx commented Aug 28, 2023

Thanks @rishi-raj-jain,
I think there some things your fixed, but the rule should be fixed I believe.
Like the code is done the same way for Android and IOS to try to make it easier to follow/read for both.
So for example if you change TAG it should be change both or keep in both but rule ignore/changed

@rishi-raj-jain
Copy link
Author

So either I can update both ios & android or I can

To ignore SonarCloud code smells for specific lines or blocks of code in a Swift project, you can one can use comments called "issue" or "noissue" comments. These comments allow you to provide information to SonarCloud regarding code smells that should be ignored or reported.

Here's how you can use these comments in Swift:

  1. Ignore a Specific Issue:

    To ignore a specific issue on a particular line of code, you can add a comment like this above the line of code:

    // NOSONAR
    // Your code here

    Replace "NOSONAR" with the specific issue key that you want to ignore. You can find the issue key in SonarCloud's interface.

  2. Ignore All Issues in a Block:

    To ignore all issues within a block of code, you can use the // NOSONAR comment at the beginning of the block, like this:

    // NOSONAR
    {
        // Code with issues
    }
  3. Re-enable Issue Reporting:

    To re-enable issue reporting after ignoring them, you can use the // SONAR_ON comment. For example:

    // SONAR_ON
    // Code where you want issues to be reported

@rishi-raj-jain
Copy link
Author

Let me know which way makes sense to you

@sonarcloud
Copy link

sonarcloud bot commented Aug 29, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

@riderx
Copy link
Collaborator

riderx commented Aug 30, 2023

It seems having static is uppercase is good practice in android, so I think for that one is better the Java way.
Do you see others cases where we have conflicting ?

@rishi-raj-jain
Copy link
Author

Hey @riderx,

Yeah that makes me wonder if we should only make changes to Swift?

@rishi-raj-jain rishi-raj-jain closed this by deleting the head repository Oct 10, 2023
@WcaleNieWolny
Copy link
Contributor

@rishi-raj-jain are you 100% sure you wanted to close this?

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.

bug: Fix sonarcloud issues
3 participants