Menu

#343 Request increase in confidence of DM_CONVERT_CASE

3.x
closed-rejected
nobody
5
2017-10-22
2015-04-18
No

Really the only time that DM_CONVERT_CASE should not be considered a bug is when you are certain of the Locale(s) that code will be run in. For library developers at least, that is never the case.

In Hibernate, for example, this regression has continually crept into our codebase many times over the past few years

Discussion

  • Steve Ebersole

    Steve Ebersole - 2015-04-18

    Reference https://hibernate.atlassian.net/browse/HHH-9733 and its linked issues

     
  • Steve Ebersole

    Steve Ebersole - 2015-04-18

    Thanks Andrey! As far as Gradle integration anyway, the bigger hurdle is the confidence. For my concern, I'd like to say that these DM_CONVERT_CASE warnings have a high confidence of being a bug (I want to treat them as unconditionally a bug in our codebase). Is the a similar way to increase the confidence (priority) of a warning?

    I will look into using the BugRanker as well, because to me the rank ought to be higher (err, lower :) than 20 which is what FindBugs reports atm:

    <BugInstance type="DM_CONVERT_CASE" priority="3" rank="20" abbrev="Dm" category="I18N">
    
     
  • Steve Ebersole

    Steve Ebersole - 2015-04-21

    FWIW, someone pointed out -adjustPriority in the FindBugs code which I tried to add support for in the Gradle integration. But FindBugs does not like that from the command line:

    Caused by: java.lang.IllegalArgumentException: Unknown option: -adjustPriority DM_CONVERT_CASE=raise, DM_CONVERT_CASE=raise
            at edu.umd.cs.findbugs.config.CommandLine.parse(CommandLine.java:321)
            at edu.umd.cs.findbugs.config.CommandLine.expandOptionFiles(CommandLine.java:177)
            at edu.umd.cs.findbugs.FindBugs.processCommandLine(FindBugs.java:331)
            at org.gradle.api.plugins.quality.internal.findbugs.FindBugsExecuter.runFindbugs(FindBugsExecuter.java:43)
            ...
    

    So not sure from where -adjustPriority is actually considered valid.

     
  • Andrey Loskutov

    Andrey Loskutov - 2017-10-22
    • Labels: DM_CONVERT_CASE --> report on spotbugs, DM_CONVERT_CASE
    • Status: open --> closed-rejected
     

Log in to post a comment.