File: spotbugs-exclude.xml

package info (click to toggle)
checkstyle 8.36.1-1
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, bullseye, forky, sid, trixie
  • size: 32,964 kB
  • sloc: java: 234,352; xml: 75,743; javascript: 258; sh: 115; sql: 6; makefile: 5
file content (259 lines) | stat: -rw-r--r-- 11,889 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
<?xml version="1.0" encoding="UTF-8"?>
<FindBugsFilter>
  <Match>
    <!-- That code is auto generated -->
    <Package name="~com\.puppycrawl\.tools\.checkstyle\.grammar.*" />
  </Match>
  <Match>
    <!-- We are not aware of encoding of files that user has, so using user encoding is ok -->
    <Class name="com.puppycrawl.tools.checkstyle.checks.LineSeparatorOption" />
    <Bug pattern="DM_DEFAULT_ENCODING" />
  </Match>
  <Match>
    <!-- see a reason of suppression at #910 -->
    <Class name="com.puppycrawl.tools.checkstyle.checks.UniquePropertiesCheck$UniqueProperties" />
    <Bug pattern="EQ_DOESNT_OVERRIDE_EQUALS" />
  </Match>
  <Match>
    <!-- false-positive, as Map will return null if key is not found -->
    <Class name="com.puppycrawl.tools.checkstyle.checks.indentation.LineWrappingHandler" />
    <Method name="collectFirstNodes" />
    <Bug pattern="RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE" />
  </Match>
  <Match>
    <!-- it is ok here, as business meaning of that cases is not the same,
           it is occasional similarity -->
    <Class name="com.puppycrawl.tools.checkstyle.checks.blocks.RightCurlyCheck" />
    <Method name="visitToken" />
    <Bug pattern="DB_DUPLICATE_SWITCH_CLAUSES" />
  </Match>
  <Match>
    <!-- false positive, condition elements are not the same -->
    <Class name="com.puppycrawl.tools.checkstyle.checks.indentation.LineWrappingHandler" />
    <Method name="collectFirstNodes" />
    <Bug pattern="RpC_REPEATED_CONDITIONAL_TEST" />
  </Match>
  <Match>
    <!-- false positive, "preceded" is returned from method as result -->
    <Class name="com.puppycrawl.tools.checkstyle.checks.whitespace.NoWhitespaceAfterCheck" />
    <Method name="getPreceded" />
    <Bug pattern="DLS_DEAD_LOCAL_STORE" />
  </Match>
  <Match>
    <!-- that CLI class so we need system exit code there, but only in main(...) method -->
    <Class name="com.puppycrawl.tools.checkstyle.Main" />
    <Method name="main" />
    <Bug pattern="DM_EXIT" />
  </Match>
  <Match>
    <!-- till https://github.com/spotbugs/spotbugs/issues/259 -->
    <Class name="com.puppycrawl.tools.checkstyle.Main" />
    <Method name="loadProperties" />
    <Bug pattern="RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE" />
  </Match>
  <Match>
    <!-- till https://github.com/spotbugs/spotbugs/issues/259 -->
    <Class name="com.puppycrawl.tools.checkstyle.PropertyCacheFile" />
    <Method name="load" />
    <Bug pattern="RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE" />
  </Match>
  <Match>
    <!-- till https://github.com/spotbugs/spotbugs/issues/259 -->
    <Class name="com.puppycrawl.tools.checkstyle.PropertyCacheFile" />
    <Method name="loadExternalResource" />
    <Bug pattern="RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE" />
  </Match>
  <Match>
    <!-- till https://github.com/spotbugs/spotbugs/issues/259 -->
    <Class name="com.puppycrawl.tools.checkstyle.PropertyCacheFile" />
    <Method name="persist" />
    <Bug pattern="RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE" />
  </Match>
  <Match>
    <!-- till https://github.com/spotbugs/spotbugs/issues/259 -->
    <Class name="com.puppycrawl.tools.checkstyle.ant.CheckstyleAntTask" />
    <Method name="createOverridingProperties" />
    <Bug pattern="RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE" />
  </Match>
  <Match>
    <!-- till https://github.com/spotbugs/spotbugs/issues/259 -->
    <Class name="com.puppycrawl.tools.checkstyle.checks.OrderedPropertiesCheck" />
    <Method name="processFiltered" />
    <Bug pattern="RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE" />
  </Match>
  <Match>
    <!-- till https://github.com/spotbugs/spotbugs/issues/259 -->
    <Class name="com.puppycrawl.tools.checkstyle.checks.TranslationCheck" />
    <Method name="getTranslationKeys" />
    <Bug pattern="RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE" />
  </Match>
  <Match>
    <!-- till https://github.com/spotbugs/spotbugs/issues/259 -->
    <Class name="com.puppycrawl.tools.checkstyle.checks.UniquePropertiesCheck" />
    <Method name="processFiltered" />
    <Bug pattern="RCN_REDUNDANT_NULLCHECK_OF_NONNULL_VALUE" />
  </Match>
  <Match>
    <!-- till https://github.com/spotbugs/spotbugs/issues/259 -->
    <Class name="com.puppycrawl.tools.checkstyle.PropertyCacheFile" />
    <Method name="loadExternalResource" />
    <Bug pattern="RCN_REDUNDANT_NULLCHECK_WOULD_HAVE_BEEN_A_NPE" />
  </Match>
  <Match>
    <!-- till https://github.com/spotbugs/spotbugs/issues/259 -->
    <Class name="com.puppycrawl.tools.checkstyle.meta.MetadataGeneratorUtil" />
    <Method name="dumpMetadata" />
    <Bug pattern="RCN_REDUNDANT_NULLCHECK_WOULD_HAVE_BEEN_A_NPE" />
  </Match>
  <Match>
    <!-- have never been a case for years, Eclipse does not show any other classes
           inherited from CommonASTWithHiddenTokens -->
    <Class name="com.puppycrawl.tools.checkstyle.DetailAstImpl" />
    <Bug pattern="BC_UNCONFIRMED_CAST" />
  </Match>
  <Match>
    <!-- The structure of frames relies on the AST structure which relies on correct/compilable
           java files. It is ok to have direct casts to subtypes there. Any problems at runtime do
           mean serious problems in the algorithm or AST generation. -->
    <Class name="com.puppycrawl.tools.checkstyle.checks.coding.RequireThisCheck"/>
    <Or>
      <Bug pattern="BC_UNCONFIRMED_CAST"/>
      <Bug pattern="BC_UNCONFIRMED_CAST_OF_RETURN_VALUE"/>
    </Or>
  </Match>
  <Match>
    <!-- false positive, beginTree is a kind of constructor for Checks -->
    <Or>
      <Class name="com.puppycrawl.tools.checkstyle.checks.AvoidEscapedUnicodeCharactersCheck" />
      <Class name="com.puppycrawl.tools.checkstyle.checks.coding.RequireThisCheck" />
      <Class name="com.puppycrawl.tools.checkstyle.checks.coding.DeclarationOrderCheck" />
      <Class name="com.puppycrawl.tools.checkstyle.checks.OuterTypeFilenameCheck" />
      <Class name="com.puppycrawl.tools.checkstyle.checks.regexp.RegexpCheck" />
      <!-- createJavadocNode is private and can not be launched without visitToken -->
      <Class name="com.puppycrawl.tools.checkstyle.checks.javadoc.AbstractJavadocCheck" />
      <!-- has only one public method and all initialized in that method -->
      <Class name="com.puppycrawl.tools.checkstyle.checks.regexp.MultilineDetector" />
      <!-- beginProcessing() is kind of c-tor -->
      <Class name="com.puppycrawl.tools.checkstyle.checks.regexp.RegexpMultilineCheck" />
      <Class name="com.puppycrawl.tools.checkstyle.checks.regexp.RegexpSinglelineCheck" />
      <!-- Uses setters to set fields values -->
      <Class name="com.puppycrawl.tools.checkstyle.api.AbstractCheck" />
      <!-- We cannot modify fields since we won't have the values
             to create the instance until the setters are called -->
      <Class name="com.puppycrawl.tools.checkstyle.filters.SuppressionSingleFilter"/>
      <Class name="com.puppycrawl.tools.checkstyle.filters.SuppressionXpathSingleFilter"/>
    </Or>
    <Bug pattern="UWF_FIELD_NOT_INITIALIZED_IN_CONSTRUCTOR" />
  </Match>
  <Match>
    <!--
     False-positive. ExternalResource cannot be null there.
     FindBugs rise violation due to @Nullable annotation on 'apply' method.
     See
     https://stevewall123.wordpress.com/2014/12/18/findbugs-warning-with-guavas-predicate-interface/
     See
     http://stackoverflow.com/questions/12422473/nullable-input-in-google-guava-function-interface-triggers-findbugs-warning
     -->
    <Class name="com.puppycrawl.tools.checkstyle.PropertyCacheFile$1" />
    <Method name="apply" />
    <Bug pattern="NP_PARAMETER_MUST_BE_NONNULL_BUT_MARKED_AS_NULLABLE" />
  </Match>
  <Match>
    <!-- false-positive. Bugs reported even though casting is done only
           after verification using instanceof -->
    <Class name="com.puppycrawl.tools.checkstyle.JavadocDetailNodeParser"/>
    <Method name="parseJavadocAsDetailNode"/>
    <Bug pattern="BC_UNCONFIRMED_CAST_OF_RETURN_VALUE"/>
  </Match>
  <Match>
    <!-- false-positive. See details at https://github.com/checkstyle/checkstyle/pull/5403 -->
    <Class name="com.puppycrawl.tools.checkstyle.Main"/>
    <Method name="loadProperties"/>
    <Bug pattern="NP_NULL_PARAM_DEREF"/>
  </Match>
  <Match>
    <!-- won't fix: field values are injected by picocli -->
    <Or>
      <Class name="com.puppycrawl.tools.checkstyle.Main"/>
      <Class name="com.puppycrawl.tools.checkstyle.JavadocPropertiesGenerator"/>
    </Or>
    <Or>
      <Bug pattern="NP_UNWRITTEN_FIELD"/>
      <Bug pattern="UWF_UNWRITTEN_FIELD"/>
      <Bug pattern="MS_SHOULD_BE_FINAL"/>
      <Bug pattern="MS_SHOULD_BE_REFACTORED_TO_BE_FINAL"/>
      <Bug pattern="SS_SHOULD_BE_STATIC"/>
    </Or>
  </Match>
  <Match>
    <!-- false-positive. See details at https://github.com/checkstyle/checkstyle/pull/5403 -->
    <Class name="com.puppycrawl.tools.checkstyle.PackageNamesLoader"/>
    <Method name="processFile"/>
    <Bug pattern="NP_NULL_PARAM_DEREF"/>
  </Match>
  <Match>
    <!-- false-positive. See details at https://github.com/checkstyle/checkstyle/pull/5403 -->
    <Class name="com.puppycrawl.tools.checkstyle.PropertyCacheFile"/>
    <Method name="flushAndCloseOutStream"/>
    <Bug pattern="NP_NULL_PARAM_DEREF"/>
  </Match>
  <Match>
    <!-- false-positive. See details at https://github.com/checkstyle/checkstyle/pull/5403 -->
    <Class name="com.puppycrawl.tools.checkstyle.PropertyCacheFile"/>
    <Method name="load"/>
    <Bug pattern="NP_NULL_PARAM_DEREF"/>
  </Match>
  <Match>
    <!-- false-positive. See details at https://github.com/checkstyle/checkstyle/pull/5403 -->
    <Class name="com.puppycrawl.tools.checkstyle.checks.header.AbstractHeaderCheck"/>
    <Method name="loadHeaderFile"/>
    <Bug pattern="NP_NULL_PARAM_DEREF"/>
  </Match>
  <Match>
    <!-- false-positive. See details at https://github.com/checkstyle/checkstyle/pull/5403 -->
    <Class name="com.puppycrawl.tools.checkstyle.ant.CheckstyleAntTask"/>
    <Method name="createOverridingProperties"/>
    <Bug pattern="NP_NULL_PARAM_DEREF"/>
  </Match>
  <Match>
    <!-- false-positive. See details at https://github.com/checkstyle/checkstyle/pull/5403 -->
    <Class name="com.puppycrawl.tools.checkstyle.PropertyCacheFile"/>
    <Method name="persist"/>
    <Bug pattern="NP_GUARANTEED_DEREF_ON_EXCEPTION_PATH"/>
  </Match>
  <Match>
    <!-- false-positive. See details at https://github.com/checkstyle/checkstyle/pull/5403 -->
    <Class name="com.puppycrawl.tools.checkstyle.PropertyCacheFile"/>
    <Method name="persist"/>
    <Bug pattern="NP_NULL_PARAM_DEREF"/>
  </Match>
  <Match>
    <!-- false-positive. See details at https://github.com/checkstyle/checkstyle/pull/5403 -->
    <Class name="com.puppycrawl.tools.checkstyle.checks.TranslationCheck"/>
    <Method name="getTranslationKeys"/>
    <Bug pattern="NP_GUARANTEED_DEREF_ON_EXCEPTION_PATH"/>
  </Match>
  <Match>
    <!-- false-positive. See details at https://github.com/checkstyle/checkstyle/pull/5403 -->
    <Class name="com.puppycrawl.tools.checkstyle.checks.UniquePropertiesCheck"/>
    <Method name="processFiltered"/>
    <Bug pattern="NP_GUARANTEED_DEREF_ON_EXCEPTION_PATH"/>
  </Match>
  <Match>
    <!-- false-positive. See details at https://github.com/checkstyle/checkstyle/pull/6343 -->
    <Class
    name="com.puppycrawl.tools.checkstyle.checks.OrderedPropertiesCheck$SequencedProperties"/>
    <Bug pattern="EQ_DOESNT_OVERRIDE_EQUALS"/>
  </Match>
  <Match>
    <!-- It is better to catch all exceptions since it can throw a runtime exception. -->
    <Class name="com.puppycrawl.tools.checkstyle.checks.TranslationCheck"/>
    <Method name="getTranslationKeys"/>
    <Bug pattern="REC_CATCH_EXCEPTION"/>
  </Match>
  <Match>
    <!-- false-positive. See details at https://github.com/checkstyle/checkstyle/issues/8262 -->
    <Field name="$jacocoData"/>
    <Bug pattern="SE_TRANSIENT_FIELD_NOT_RESTORED"/>
  </Match>
</FindBugsFilter>