Skip to content

Commit 2b8b63e

Browse files
committed
Prepare pmd release 7.14.0
1 parent 5800f65 commit 2b8b63e

File tree

2 files changed

+189
-4
lines changed

2 files changed

+189
-4
lines changed

_config.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,15 +25,15 @@ exclude:
2525
# PMD vars #
2626
# ----------------------- #
2727
pmd:
28-
latestVersion: 7.13.0
29-
latestVersionDate: 25-April-2025
28+
latestVersion: 7.14.0
29+
latestVersionDate: 30-May-2025
3030
downloads:
31+
- version: 7.13.0
32+
date: 25-April-2025
3133
- version: 7.12.0
3234
date: 28-March-2025
3335
- version: 7.11.0
3436
date: 28-February-2025
35-
- version: 7.10.0
36-
date: 31-January-2025
3737

3838
# ----------------------- #
3939
# Jekyll & Plugins #

_posts/2025-05-30-PMD-7.14.0.md

Lines changed: 185 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,185 @@
1+
---
2+
layout: post
3+
title: PMD 7.14.0 released
4+
---
5+
6+
7+
8+
## 30-May-2025 - 7.14.0
9+
10+
The PMD team is pleased to announce PMD 7.14.0.
11+
12+
This is a minor release.
13+
14+
### Table Of Contents
15+
16+
* [🚀 New and noteworthy](#new-and-noteworthy)
17+
* [PMD CLI now uses threaded execution by default](#pmd-cli-now-uses-threaded-execution-by-default)
18+
* [New Rule UnnecessaryWarningSuppression (experimental)](#new-rule-unnecessarywarningsuppression-experimental)
19+
* [Migrating to Central Publisher Portal](#migrating-to-central-publisher-portal)
20+
* [More CLI parameters shared between PMD and CPD](#more-cli-parameters-shared-between-pmd-and-cpd)
21+
* [🐛 Fixed Issues](#fixed-issues)
22+
* [🚨 API Changes](#api-changes)
23+
* [CLI](#cli)
24+
* [Deprecations](#deprecations)
25+
* [Experimental](#experimental)
26+
* [✨ Merged pull requests](#merged-pull-requests)
27+
* [📦 Dependency updates](#dependency-updates)
28+
* [📈 Stats](#stats)
29+
30+
### 🚀 New and noteworthy
31+
32+
#### PMD CLI now uses threaded execution by default
33+
34+
In the PMD CLI, the `--threads` (`-t`) option can now accept a thread
35+
count given relative to the number of cores of the machine. For instance,
36+
it is now possible to write `-t 1C` to spawn one thread per core, or `-t 0.5C`
37+
to spawn one thread for every other core.
38+
39+
The thread count option now defaults to `1C`, meaning parallel execution
40+
is used by default. You can disable this by using `-t 1`.
41+
42+
#### New Rule UnnecessaryWarningSuppression (experimental)
43+
44+
This new Java rule [`UnnecessaryWarningSuppression`](https://docs.pmd-code.org/pmd-doc-7.14.0/pmd_rules_java_bestpractices.html#unnecessarywarningsuppression) reports unused suppression
45+
annotations and comments. Violations of this rule cannot be suppressed.
46+
47+
How to use it? Just include it in your ruleset:
48+
49+
```xml
50+
<rule ref="category/java/bestpractices.xml/UnnecessaryWarningSuppression" />
51+
```
52+
53+
Note: This rule is currently experimental. It is available for now only for Java.
54+
The rule for now only reports annotations specific to PMD, like `@SuppressWarnings("PMD")`.
55+
In the future we might be able to check for other common ones like `@SuppressWarnings("unchecked")` or `"fallthrough"`.
56+
Since violations of this rule cannot be suppressed, we opted here on the side of false-negatives and
57+
don't report every unused case yet.
58+
However, suppressing specific PMD rules is working as expected.
59+
60+
#### Migrating to Central Publisher Portal
61+
62+
We've now migrated to [Central Publisher Portal](https://central.sonatype.org/publish/publish-portal-guide/).
63+
Snapshots of PMD are still available, however the repository URL changed. To consume these with maven, you can
64+
use the following snippet:
65+
66+
```xml
67+
<repositories>
68+
<repository>
69+
<name>Central Portal Snapshots</name>
70+
<id>central-portal-snapshots</id>
71+
<url>https://central.sonatype.com/repository/maven-snapshots/</url>
72+
<releases>
73+
<enabled>false</enabled>
74+
</releases>
75+
<snapshots>
76+
<enabled>true</enabled>
77+
</snapshots>
78+
</repository>
79+
</repositories>
80+
```
81+
82+
Releases of PMD are available on [Maven Central](https://central.sonatype.com/) as before without change.
83+
84+
#### More CLI parameters shared between PMD and CPD
85+
86+
When executing PMD or CPD, the same parameters are now understood for selecting which files should
87+
be analyzed. See [File collection options](https://docs.pmd-code.org/pmd-doc-7.14.0/pmd_userdocs_cli_reference.html#file-collection-options)
88+
for a list of common, shared parameters that are valid for both commands.
89+
90+
### 🐛 Fixed Issues
91+
* core
92+
* [#648](https://github.com/pmd/pmd/issues/648): \[core] Warn on unneeded suppression
93+
* [#5700](https://github.com/pmd/pmd/pull/5700): \[core] Don't accidentally catch unexpected runtime exceptions in CpdAnalysis
94+
* [#5705](https://github.com/pmd/pmd/issues/5705): \[cli] PMD's start script fails if PMD_HOME is set
95+
* java-bestpractices
96+
* [#5061](https://github.com/pmd/pmd/issues/5061): \[java] UnusedLocalVariable false positive when variable is read as side effect of an assignment
97+
* [#5621](https://github.com/pmd/pmd/issues/5621): \[java] UnusedPrivateMethod with method ref
98+
* [#5724](https://github.com/pmd/pmd/issues/5724): \[java] ImplicitFunctionalInterface should not be reported on sealed interfaces
99+
* java-codestyle
100+
* [#2462](https://github.com/pmd/pmd/issues/2462): \[java] LinguisticNaming must ignore setters that returns current type (Builder pattern)
101+
* [#5634](https://github.com/pmd/pmd/issues/5634): \[java] CommentDefaultAccessModifier doesn't recognize /* package */ comment at expected location for constructors
102+
* java-design
103+
* [#5568](https://github.com/pmd/pmd/issues/5568): \[java] High NPathComplexity in `switch` expression
104+
* [#5647](https://github.com/pmd/pmd/issues/5647): \[java] NPathComplexity does not account for `return`s
105+
* java-errorprone
106+
* [#5702](https://github.com/pmd/pmd/issues/5702): \[java] InvalidLogMessageFormat: Lombok @<!-- -->Slf4j annotation is not interpreted by PMD
107+
* java-performance
108+
* [#5711](https://github.com/pmd/pmd/issues/5711): \[java] UseArraysAsList false positive with Sets
109+
* visualforce
110+
* [#5476](https://github.com/pmd/pmd/issues/5476): \[visualforce] NPE when analyzing standard field references in visualforce page
111+
112+
### 🚨 API Changes
113+
#### CLI
114+
* CPD now supports `--report-file` (-r) and `--exclude-file-list`.
115+
* PMD now supports `--exclude` and `--non-recursive`.
116+
* The option `--ignore-list` in PMD is renamed to `--exclude-file-list`.
117+
118+
#### Deprecations
119+
* CLI
120+
* The option `--ignore-list` has been deprecated. Use `--exclude-file-list` instead.
121+
* core
122+
* <a href="https://docs.pmd-code.org/apidocs/pmd-core/7.14.0/net/sourceforge/pmd/lang/ast/AstInfo.html#getSuppressionComments()"><code>AstInfo#getSuppressionComments</code></a>: Use <a href="https://docs.pmd-code.org/apidocs/pmd-core/7.14.0/net/sourceforge/pmd/lang/ast/AstInfo.html#getAllSuppressionComments()"><code>getAllSuppressionComments</code></a>
123+
or <a href="https://docs.pmd-code.org/apidocs/pmd-core/7.14.0/net/sourceforge/pmd/lang/ast/AstInfo.html#getSuppressionComment(int)"><code>getSuppressionComment</code></a>.
124+
* <a href="https://docs.pmd-code.org/apidocs/pmd-core/7.14.0/net/sourceforge/pmd/lang/ast/AstInfo.html#withSuppressMap()"><code>AstInfo#withSuppressMap</code></a>: Use <a href="https://docs.pmd-code.org/apidocs/pmd-core/7.14.0/net/sourceforge/pmd/lang/ast/AstInfo.html#withSuppressionComments(java.util.Collection)"><code>withSuppressionComments</code></a>
125+
* <a href="https://docs.pmd-code.org/apidocs/pmd-core/7.14.0/net/sourceforge/pmd/lang/ast/impl/javacc/AbstractTokenManager.html#suppressMap"><code>AbstractTokenManager#suppressMap</code></a>: Don't use this map directly anymore. Instead,
126+
use <a href="https://docs.pmd-code.org/apidocs/pmd-core/7.14.0/net/sourceforge/pmd/lang/ast/impl/javacc/AbstractTokenManager.html#getSuppressionComments()"><code>getSuppressionComments</code></a>.
127+
* <a href="https://docs.pmd-code.org/apidocs/pmd-core/7.14.0/net/sourceforge/pmd/lang/ast/impl/javacc/AbstractTokenManager.html#getSuppressMap()"><code>AbstractTokenManager#getSuppressMap</code></a>: Use
128+
<a href="https://docs.pmd-code.org/apidocs/pmd-core/7.14.0/net/sourceforge/pmd/lang/ast/impl/javacc/AbstractTokenManager.html#getSuppressionComments()"><code>getSuppressionComments</code></a> instead.
129+
* pmd-java
130+
* <a href="https://docs.pmd-code.org/apidocs/pmd-java/7.14.0/net/sourceforge/pmd/lang/java/ast/ASTCompactConstructorDeclaration.html#getDeclarationNode()"><code>ASTCompactConstructorDeclaration#getDeclarationNode</code></a>: This method just returns `this` and isn't useful.
131+
* <a href="https://docs.pmd-code.org/apidocs/pmd-java/7.14.0/net/sourceforge/pmd/lang/java/metrics/JavaMetrics.html#NPATH"><code>JavaMetrics#NPATH</code></a>: Use <a href="https://docs.pmd-code.org/apidocs/pmd-java/7.14.0/net/sourceforge/pmd/lang/java/metrics/JavaMetrics.html#NPATH_COMP"><code>NPATH_COMP</code></a>, which is available on more nodes,
132+
and uses Long instead of BigInteger.
133+
134+
#### Experimental
135+
* core
136+
* <a href="https://docs.pmd-code.org/apidocs/pmd-core/7.14.0/net/sourceforge/pmd/lang/ast/impl/SuppressionCommentImpl.html#"><code>SuppressionCommentImpl</code></a>
137+
* <a href="https://docs.pmd-code.org/apidocs/pmd-core/7.14.0/net/sourceforge/pmd/lang/rule/impl/UnnecessaryPmdSuppressionRule.html#"><code>UnnecessaryPmdSuppressionRule</code></a>
138+
* <a href="https://docs.pmd-code.org/apidocs/pmd-core/7.14.0/net/sourceforge/pmd/reporting/RuleContext.html#addViolationNoSuppress(net.sourceforge.pmd.reporting.Reportable,net.sourceforge.pmd.lang.ast.AstInfo,java.lang.String,java.lang.Object...)"><code>RuleContext#addViolationNoSuppress</code></a>
139+
* <a href="https://docs.pmd-code.org/apidocs/pmd-core/7.14.0/net/sourceforge/pmd/reporting/ViolationSuppressor.SuppressionCommentWrapper.html#"><code>ViolationSuppressor.SuppressionCommentWrapper</code></a>
140+
* pmd-java
141+
* <a href="https://docs.pmd-code.org/apidocs/pmd-java/7.14.0/net/sourceforge/pmd/lang/java/types/OverloadSelectionResult.html#getTypeToSearch()"><code>OverloadSelectionResult#getTypeToSearch</code></a>
142+
143+
### ✨ Merged pull requests
144+
<!-- content will be automatically generated, see /do-release.sh -->
145+
* [#5584](https://github.com/pmd/pmd/pull/5584): \[ci] New workflow "Publish Snapshot" - [Andreas Dangel](https://github.com/adangel) (@adangel)
146+
* [#5599](https://github.com/pmd/pmd/pull/5599): \[java] Rewrite NPath complexity metric - [Clément Fournier](https://github.com/oowekyala) (@oowekyala)
147+
* [#5609](https://github.com/pmd/pmd/pull/5609): \[core] Add rule to report unnecessary suppression comments/annotations - [Clément Fournier](https://github.com/oowekyala) (@oowekyala)
148+
* [#5699](https://github.com/pmd/pmd/pull/5699): Fix #5702: \[java] First-class support for lombok @<!-- -->Slf4j - [Clément Fournier](https://github.com/oowekyala) (@oowekyala)
149+
* [#5700](https://github.com/pmd/pmd/pull/5700): \[core] Don't accidentally catch unexpected runtime exceptions in CpdAnalysis - [Elliotte Rusty Harold](https://github.com/elharo) (@elharo)
150+
* [#5712](https://github.com/pmd/pmd/pull/5712): Fix #5711: \[java] UseArrayAsList - only consider List.add - [Andreas Dangel](https://github.com/adangel) (@adangel)
151+
* [#5715](https://github.com/pmd/pmd/pull/5715): Fix #5476: \[visualforce] Resolve data types of standard object fields - [Andreas Dangel](https://github.com/adangel) (@adangel)
152+
* [#5716](https://github.com/pmd/pmd/pull/5716): Fix #5634: \[java] CommentDefaultAccessModifier: Comment between annotation and constructor not recognized - [Lukas Gräf](https://github.com/lukasgraef) (@lukasgraef)
153+
* [#5726](https://github.com/pmd/pmd/pull/5726): Fix #5724: \[java] Implicit functional interface FP with sealed interface - [Clément Fournier](https://github.com/oowekyala) (@oowekyala)
154+
* [#5727](https://github.com/pmd/pmd/pull/5727): Fix #5621: \[java] Fix FPs with UnusedPrivateMethod - [Clément Fournier](https://github.com/oowekyala) (@oowekyala)
155+
* [#5728](https://github.com/pmd/pmd/pull/5728): \[ci] Improvements for "Publish Pull Requests" - [Andreas Dangel](https://github.com/adangel) (@adangel)
156+
* [#5730](https://github.com/pmd/pmd/pull/5730): \[ci] Refactor git-repo-sync - [Andreas Dangel](https://github.com/adangel) (@adangel)
157+
* [#5731](https://github.com/pmd/pmd/pull/5731): \[cli] Share more CLI options between CPD and PMD - [Clément Fournier](https://github.com/oowekyala) (@oowekyala)
158+
* [#5736](https://github.com/pmd/pmd/pull/5736): Fix #5061: \[java] UnusedLocalVariable FP when using compound assignment - [Lukas Gräf](https://github.com/lukasgraef) (@lukasgraef)
159+
* [#5741](https://github.com/pmd/pmd/pull/5741): \[cli] Make CLI default to multithreaded - [Clément Fournier](https://github.com/oowekyala) (@oowekyala)
160+
* [#5742](https://github.com/pmd/pmd/pull/5742): \[ci] publish-snapshot/old build: migrate to central portal - [Andreas Dangel](https://github.com/adangel) (@adangel)
161+
* [#5743](https://github.com/pmd/pmd/pull/5743): \[ci] Make build a reuseable workflow - [Andreas Dangel](https://github.com/adangel) (@adangel)
162+
* [#5744](https://github.com/pmd/pmd/pull/5744): Fix #5705: \[cli] Always determine PMD_HOME based on script location - [Andreas Dangel](https://github.com/adangel) (@adangel)
163+
* [#5748](https://github.com/pmd/pmd/pull/5748): \[core] Reformat SarifLog to comply to coding standards - [Andreas Dangel](https://github.com/adangel) (@adangel)
164+
* [#5763](https://github.com/pmd/pmd/pull/5763): \[java] Support annotated constructor return type in symbol API - [Clément Fournier](https://github.com/oowekyala) (@oowekyala)
165+
* [#5764](https://github.com/pmd/pmd/pull/5764): Fix #2462: \[java] LinguisticNaming should ignore setters for Builders - [Lukas Gräf](https://github.com/lukasgraef) (@lukasgraef)
166+
167+
### 📦 Dependency updates
168+
<!-- content will be automatically generated, see /do-release.sh -->
169+
* [#5706](https://github.com/pmd/pmd/pull/5706): Bump PMD from 7.12.0 to 7.13.0
170+
* [#5709](https://github.com/pmd/pmd/pull/5709): Bump com.google.code.gson:gson from 2.13.0 to 2.13.1
171+
* [#5710](https://github.com/pmd/pmd/pull/5710): Bump com.puppycrawl.tools:checkstyle from 10.23.0 to 10.23.1
172+
* [#5717](https://github.com/pmd/pmd/pull/5717): Bump scalameta.version from 4.13.4 to 4.13.5
173+
* [#5718](https://github.com/pmd/pmd/pull/5718): Bump org.checkerframework:checker-qual from 3.49.2 to 3.49.3
174+
* [#5719](https://github.com/pmd/pmd/pull/5719): Bump org.jsoup:jsoup from 1.19.1 to 1.20.1
175+
* [#5751](https://github.com/pmd/pmd/pull/5751): Bump scalameta.version from 4.13.5 to 4.13.6
176+
* [#5754](https://github.com/pmd/pmd/pull/5754): Bump com.google.protobuf:protobuf-java from 4.30.2 to 4.31.0
177+
* [#5766](https://github.com/pmd/pmd/pull/5766): Bump io.github.git-commit-id:git-commit-id-maven-plugin from 9.0.1 to 9.0.2
178+
* [#5767](https://github.com/pmd/pmd/pull/5767): Bump org.mockito:mockito-core from 5.17.0 to 5.18.0
179+
* [#5768](https://github.com/pmd/pmd/pull/5768): Bump com.puppycrawl.tools:checkstyle from 10.23.1 to 10.24.0
180+
181+
### 📈 Stats
182+
<!-- content will be automatically generated, see /do-release.sh -->
183+
* 165 commits
184+
* 33 closed tickets & PRs
185+
* Days since last release: 35

0 commit comments

Comments
 (0)