False positive java:S110 with JavaFx

  • What language is this for?
    • Java
  • Which rule?
    • java:S110
  • Why do you believe it’s a false-positive?
  • I’m using SonarLint
    • in Intellij IDEA 2023.1.2 Build #IU-231.9011.34
    • SonarLint plugin version is 8.3.0.71062 (current as of writing)
    • not connected to SonarQube nor SonarCloud
  • How can we reproduce the problem?
import javafx.scene.layout.BorderPane;

public class ExampleClass extends BorderPane {

}

ExampleClass here raises Major Code Smell java:S110 for inheriting from javafx.scene.layout.BorderPane.
Same warning is shown for many other JavaFX layouts including HBox, Label, TextField, etc.

Hey Martin, welcome to our community!

I think it’s reasonable to consider this library another exception to the rule, I created a ticket to fix this.
Thank you for the report!

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.