Skip to content

RANGER-5688: maven-source-plugin.version property is referenced but never defined#1074

Open
magnuma3 wants to merge 1 commit into
apache:masterfrom
magnuma3:RANGER-5688
Open

RANGER-5688: maven-source-plugin.version property is referenced but never defined#1074
magnuma3 wants to merge 1 commit into
apache:masterfrom
magnuma3:RANGER-5688

Conversation

@magnuma3

@magnuma3 magnuma3 commented Jul 14, 2026

Copy link
Copy Markdown

What changes were proposed in this pull request?

RANGER-4076 replaced the hardcoded maven-source-plugin version in the root pom's pluginManagement with a property reference, but the property was never defined:

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-source-plugin</artifactId>
<version>${maven-source-plugin.version}</version>

git grep '<maven-source-plugin.version>' returns nothing.

Since pluginManagement entries are only resolved when the plugin is actually invoked, normal builds are unaffected. But any invocation of the plugin by prefix, e.g.:

mvn install source:jar -DskipTests -Denunciate.disable.sourcepath=true

fails at startup, because the undefined property survives as a literal and Maven tries to resolve version ${maven-source-plugin.version} from central:

[ERROR] Plugin org.apache.maven.plugins:maven-source-plugin:${maven-source-plugin.version} or one of its dependencies could not be resolved

Fix: define the property alongside the other plugin versions in the root pom, e.g. <maven-source-plugin.version>3.3.1</maven-source-plugin.version>.

How was this patch tested?

(Please explain how this patch was tested. Ex: unit tests, manual tests)
(If this patch involves UI changes, please attach a screen-shot; otherwise, remove this)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant