Skip to content

I can't ignore ConditionalRegexpMultilineCheck from checkstyle #1328

@Marat-Tim

Description

@Marat-Tim

I use this version of the plugin with the following settings

<plugin>
  <groupId>com.qulice</groupId>
  <artifactId>qulice-maven-plugin</artifactId>
  <version>0.24.0</version>
  <configuration>
    <excludes>
      <exclude>pmd:/src/it/.*</exclude>
      <exclude>checkstyle:/src/it/.*</exclude>
      <exclude>duplicatefinder:.*</exclude>
      <exclude>dependencies:.*</exclude>
    </excludes>
  </configuration>
  <executions>
    <execution>
      <goals>
        <goal>check</goal>
      </goals>
    </execution>
  </executions>
</plugin>

And there is a code snippet like this

...
* @checkstyle ConditionalRegexpMultilineCheck (30 lines)
 */
final class LtAsciiOnly implements Lint<XML> {

    @Override
    public Collection<Defect> defects(final XML xmir) throws IOException {
        final Collection<Defect> defects = new ArrayList<>();
...

When building, I get this problem

[INFO] --- qulice-maven-plugin:0.24.0:check (jcabi-qulice-check) @ lints ---
[INFO] Checkstyle: C:\Users\User\Desktop\lints\src\main\java\org\eolang\lints\LtAsciiOnly.java[37]: ArrayList should be initialized with a size parameter (ConditionalRegexpMultilineCheck)

Although I expect that it should be ignored

You can view the code and error in more detail here LtAsciiOnly.java and here Job with error

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions