Uploaded image for project: 'SonarQube'
  1. SonarQube
  2. SONAR-3722

Misleading exception message when no l10n of rule name

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.2
    • Fix Version/s: 3.3
    • Component/s: l10n & i18n
    • Labels:
      None

      Description

      To reproduce - remove key "rule.checkstyle.com.puppycrawl.tools.checkstyle.checks.naming.MethodTypeParameterName.name" from plugins/sonar-l10n-en-plugin/src/main/resources/org/sonar/l10n/checkstyle.properties and start server. Exception in sonar.log :

      2012.08.08 03:33:10 ERROR o.s.s.p.Platform  The following rule (repository: checkstyle) must have a description: Rule[id=<null>,name=Method Type Parameter Name,key=com.puppycrawl.tools.checkstyle.checks.naming.MethodTypeParameterName,configKey=Checker/TreeWalker/MethodTypeParameterName,plugin=<null>,enabled=true,severity=MAJOR,cardinality=SINGLE]
      org.sonar.api.utils.SonarException: The following rule (repository: checkstyle) must have a description: Rule[id=<null>,name=Method Type Parameter Name,key=com.puppycrawl.tools.checkstyle.checks.naming.MethodTypeParameterName,configKey=Checker/TreeWalker/MethodTypeParameterName,plugin=<null>,enabled=true,severity=MAJOR,cardinality=SINGLE]
              at org.sonar.server.startup.RegisterRules.validateRule(RegisterRules.java:121) ~[RegisterRules.class:na]
              at org.sonar.server.startup.RegisterRules.registerRepository(RegisterRules.java:98) ~[RegisterRules.class:na]
              at org.sonar.server.startup.RegisterRules.start(RegisterRules.java:61) ~[RegisterRules.class:na]
      

      I expected that "name" will be mentioned instead of "description".

        Attachments

          Activity

            People

            Assignee:
            fabemn OLD - Fabrice Bellingard
            Reporter:
            godin OLD - Evgeny Mandrikov
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: