During sonar analysis cannot generate ucfg for file

Must-share information (formatted with Markdown):

  • SonarQube version: 8.6.0
  • During project analysis I receive many errors

[ERROR] Cannot generate ucfg for file /builds/lku-git/******/target/sonar/jsp/org/apache/jsp/WEB_002dINF/jsp/cp/pay/edit_jsp.java for method at line 682 java.lang.NullPointerException: null

Hi @Rokas_S,

Welcome to SonarSource community! :wave:

Can you create a small reproducer project that reproduces the issue with a minimal set of code? Or the file that is having issues (edit_jsp.java)? You can zip it and attach it here.

Joe

Hello I am adding a file. An this happens with all _jsp.java files. I don’t want to analyse these file at all

2021-01-19, an, 00:40 Joe via SonarSource Community <sscommunity@discoursemail.com> rašė:

edit_jsp.zip (4.3 KB)

@Rokas_S: Since you don’t want to analyze these files, you can add a exclusion parameter as described in Narrowing the Focus:

sonar.exclusions=**/*_jsp.java

The exclusion doesn’t help to prevent file scanning.

2021-01-21, kt, 17:42 Joe via SonarSource Community <sscommunity@discoursemail.com> rašė:

Hello @Rokas_S ,

Thank you for your patience. Our SonarJava team has logged this as an issue here: https://jira.sonarsource.com/browse/SONARJAVA-3693

Thank you for reporting this. Please watch that ticket for any further notification.

Joe

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