SonarQube
  1. SonarQube
  2. SONAR-3032

When the "Redundant Throws" Checkstyle check can't manage to get a class information, a runtime exception is thrown and the analysis of this file is stopped

    Details

    • Type: Bug Bug
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.0
    • Component/s: None
    • Labels:
      None
    • Number of attachments :
      3

      Issue Links

        Activity

        Freddy Mallet made changes -
        Field Original Value New Value
        Assignee Freddy Mallet [ freddy.mallet ]
        Evgeny Mandrikov made changes -
        Assignee Evgeny Mandrikov [ godin ]
        Hide
        Evgeny Mandrikov added a comment - - edited

        Seems that behaviour of this check has been changed after migration to Checkstyle 5.5 (SONAR-1836), i.e. I can't reproduce this issue in Sonar 2.13.

        Show
        Evgeny Mandrikov added a comment - - edited Seems that behaviour of this check has been changed after migration to Checkstyle 5.5 ( SONAR-1836 ), i.e. I can't reproduce this issue in Sonar 2.13.
        Evgeny Mandrikov made changes -
        Status Open [ 1 ] In Progress [ 3 ]
        Hide
        David RACODON added a comment -

        You seem to confirm what we thought. See http://markmail.org/message/rvgjbykdalhyu4p4

        Show
        David RACODON added a comment - You seem to confirm what we thought. See http://markmail.org/message/rvgjbykdalhyu4p4
        Hide
        Evgeny Mandrikov added a comment -

        I just confirm that behaviour was changed, however would be better to understand how I'll come back to this thread tomorrow.

        Show
        Evgeny Mandrikov added a comment - I just confirm that behaviour was changed, however would be better to understand how I'll come back to this thread tomorrow.
        Evgeny Mandrikov made changes -
        Attachment SONAR-3032.zip [ 59342 ]
        Evgeny Mandrikov made changes -
        Link This issue relates to SONAR-1836 [ SONAR-1836 ]
        Evgeny Mandrikov made changes -
        Attachment sonar-2.13.png [ 59343 ]
        Attachment sonar-2.12.png [ 59344 ]
        Hide
        Evgeny Mandrikov added a comment -

        Here is an explanation of changes from release notes for Checkstyle 5.3 :

        Changed the default value of the property logLoadErrors to be true for the checks RedundantThrows and JavadocMethod to ensure consistent behaviour.

        Which means that violation will be shown, when Checkstyle is unable to load class, and processing of file will continue.
        Also should be noted that Sonar doesn't allow to change value of this property, because it isn't presented in rules.

        Show
        Evgeny Mandrikov added a comment - Here is an explanation of changes from release notes for Checkstyle 5.3 : Changed the default value of the property logLoadErrors to be true for the checks RedundantThrows and JavadocMethod to ensure consistent behaviour. Which means that violation will be shown, when Checkstyle is unable to load class, and processing of file will continue. Also should be noted that Sonar doesn't allow to change value of this property, because it isn't presented in rules.
        Hide
        Evgeny Mandrikov added a comment - - edited

        I've added parameter "suppressLoadErrors" with default value "true" to Checkstyle rules "RedundantThrows" and "JavadocMethod" in order to not produce false-positive violations - 7d5b618. Also should be noted that default value for this parameter in Checkstyle 5.5 set to false.

        Show
        Evgeny Mandrikov added a comment - - edited I've added parameter "suppressLoadErrors" with default value "true" to Checkstyle rules "RedundantThrows" and "JavadocMethod" in order to not produce false-positive violations - 7d5b618 . Also should be noted that default value for this parameter in Checkstyle 5.5 set to false.
        Evgeny Mandrikov made changes -
        Status In Progress [ 3 ] Resolved [ 5 ]
        Assignee Evgeny Mandrikov [ godin ] Freddy Mallet [ freddy.mallet ]
        Fix Version/s 2.15 [ 18255 ]
        Resolution Fixed [ 1 ]
        Hide
        Freddy Mallet added a comment -

        Manually tested

        Show
        Freddy Mallet added a comment - Manually tested
        Freddy Mallet made changes -
        Assignee Freddy Mallet [ freddy.mallet ] Evgeny Mandrikov [ godin ]
        Freddy Mallet made changes -
        Link This issue is duplicated by SONAR-1746 [ SONAR-1746 ]
        Hide
        Evgeny Mandrikov added a comment -

        Integration test added.

        Show
        Evgeny Mandrikov added a comment - Integration test added.
        Evgeny Mandrikov made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Freddy Mallet made changes -
        Link This issue is related to SONAR-3502 [ SONAR-3502 ]
        Fabrice Bellingard made changes -
        Component/s Checkstyle [ 13818 ]

          People

          • Assignee:
            Evgeny Mandrikov
            Reporter:
            Freddy Mallet
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: