fix: interpolate properties in module/subproject path before filesystem resolution (backport #12734) - #12924
Merged
Conversation
…em resolution (apache#12734) * fix: interpolate properties in module/subproject path before filesystem resolution * fix: address review feedback for module path interpolation - Fix property lookup precedence: user → model → system (was inverted) - Use Interpolator.chain() instead of manual lambda for consistency - Remove redundant null guard on interpolator.interpolate() result - Fix comment reference from MNG-XXXX to apache#12729 - Add regression integration test for apachegh-12729 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> --------- Co-authored-by: Guillaume Nodet <gnodet@gmail.com> Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
The base class on maven-4.0.x requires a version range constructor argument and uses File/String instead of Path for extractResources and newVerifier. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
gnodet
commented
Aug 29, 2026
gnodet
left a comment
Contributor
Author
There was a problem hiding this comment.
Clean backport of #12734 (module/subproject path property interpolation fix) to maven-4.0.x. No issues found.
Backport observations:
- The interpolation code in
DefaultModelBuilder.javais identical between master and this backport — only surrounding line numbers differ due to branch divergence. - Integration test correctly adapted to the maven-4.0.x
AbstractMavenIntegrationTestCaseAPI:Filereturn type forextractResources()(vsPathon master)String-basednewVerifier()(vsPathon master)- Mandatory version-range constructor
super("[4.0.0-rc-1,)")
Interpolator.chain()is already used elsewhere inDefaultModelBuilderon maven-4.0.x (line 2441), confirming API availability.- All five findings from the original multi-round review of #12734 (property precedence,
Interpolator.chain(), regression test, placeholder reference, null guard) are reflected in the backported code. - No backport to maven-3.9.x / maven-3.10.x needed — this is a Maven 4 regression that restores behavior Maven 3 already had.
This review was generated by an AI agent and may contain inaccuracies. Please verify all suggestions before applying.
Claude Code on behalf of Guillaume Nodet
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
Backport of #12734 to
maven-4.0.x.${property}references in<module>/<subproject>paths before filesystem resolution, restoring Maven 3 behaviourInterpolator.chain()with correct user → model → system property precedenceFixes #12729