Environment:
- SonarLint: * 10.4.87286
After upgrading SQ to 10.4 all of a sudden I’ve got 10 new issues. After examining them seems like SQ stopped accepting @SuppressWarnings
annotations. Example code, that is issue.
@SuppressWarnings("java:S1118") // Spring nuance
@Configuration
public class BuildMetadataConfig {
@Bean
public static PropertySourcesPlaceholderConfigurer placeholderConfigurer() {
PropertySourcesPlaceholderConfigurer propsConfig = new PropertySourcesPlaceholderConfigurer();
propsConfig.setLocations(
new ClassPathResource("git.properties"),
new ClassPathResource("META-INF/build-info.properties"));
propsConfig.setIgnoreResourceNotFound(true);
propsConfig.setIgnoreUnresolvablePlaceholders(true);
return propsConfig;
}
}