StackOverflowError when building maven multimodule

Hi,
I am trying to configure sonarcloud but I get a java.lang.StackOverflowError if I use a multi-module Java maven project.

  • Repository: github
  • CI: Github actions
  • Language Java
  • Error log in github action executed when doing a pull request:
Exception in thread "main" java.lang.StackOverflowError
	at org.sonar.api.batch.fs.internal.DefaultInputComponent.hashCode(DefaultInputComponent.java:43)
	at java.base/java.util.HashMap.hash(HashMap.java:339)
	at java.base/java.util.HashMap.getOrDefault(HashMap.java:1052)
	at java.base/java.util.Collections$UnmodifiableMap.getOrDefault(Collections.java:1500)
	at org.sonar.scanner.scan.DefaultInputModuleHierarchy.children(DefaultInputModuleHierarchy.java:56)
	at org.sonar.scanner.scan.WorkDirectoriesInitializer.cleanAllWorkingDirs(WorkDirectoriesInitializer.java:35)
	at org.sonar.scanner.scan.WorkDirectoriesInitializer.cleanAllWorkingDirs(WorkDirectoriesInitializer.java:36)
	at org.sonar.scanner.scan.WorkDirectoriesInitializer.cleanAllWorkingDirs(WorkDirectoriesInitializer.java:36)
	at org.sonar.scanner.scan.WorkDirectoriesInitializer.cleanAllWorkingDirs(WorkDirectoriesInitializer.java:36)
	at org.sonar.scanner.scan.WorkDirectoriesInitializer.cleanAllWorkingDirs(WorkDirectoriesInitializer.java:36)
  • steps to reproduce:
    • Configure a Java multi-module project. If the sub project set parent artifact, then I see the errors. eg. child pom:

<parent>
		<groupId>com.ibm.whc.deid</groupId>
		<artifactId>de-identification</artifactId>
		<version>0.0.1.master-SNAPSHOT</version>
	</parent>```

If I have a multi-module project and I don’t specify the parent in the child, then I do not see the stackoverflow exception.