Fix #367 for Maven 3.x - #419
Open
wilx wants to merge 2 commits into
Open
Conversation
Model Maven 3.10's empty default lifecycle map and verify that help:describe uses the packaging-specific lifecycle mapping.
Treat an empty default lifecycle map like a missing map so Maven 3.10 falls back to packaging-specific bindings. Replace the deprecated string mappings with the typed lifecycle APIs available since Maven 3.6.3.
wilx
marked this pull request as ready for review
August 10, 2026 22:40
8 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes #367 for 3.x branch.
This backports the lifecycle-mapping part of #372 to the
maven-help-plugin-3.4.xmaintenance branch. Maven 3.10 represents the default lifecycle's built-in bindings as an empty map. The 3.x implementation only fell back to the packaging-specific mapping when that map wasnull, sohelp:describe -Dcmd=deployreported every phase asNot definedand the existingdescribe-cmdintegration test failed in this Actions job.The change treats both null and empty built-in mappings as packaging-specific and replaces the deprecated string lifecycle APIs with their typed equivalents. Those APIs were verified against Maven 3.6.3, the minimum version declared by this branch.
The commits are intentionally split: the first adds a unit regression that fails without the runtime change, and the second applies the fix. The existing
describe-cmdIT provides end-to-end coverage of the reported failure.Validation
mvn clean verify -P run-its— 24 unit tests and all 34 ITs passedmvn clean verify -P run-its— 24 unit tests and all 34 ITs passedmvn clean verify -P run-its— 24 unit tests and all 34 ITs passed, includingdescribe-cmdChecklist
This pull request addresses one issue without unrelated changes.
The description explains what changed, how, and why.
Each commit has a meaningful subject line and body.
A regression unit test fails without the runtime change.
mvn verifywas run successfully.The integration tests were run successfully with
mvn -Prun-its verify.I hereby declare this contribution to be licenced under the Apache License Version 2.0, January 2004.
In any other case, an Apache Individual Contributor License Agreement has been filed.