goutamadwant opened a new pull request, #1500:
URL: https://github.com/apache/maven-release/pull/1500
Fixes #1004 (MRELEASE-799).
`release:update-versions` fails when a plugin dependency references a
reactor artifact's previous release through a property, while the equivalent
literal version is preserved. For example, a project at `2.0-SNAPSHOT` using
its own `1.0` release through `${previous.version}` cannot advance to
`2.1-SNAPSHOT`.
Preserve locally defined literal property values that refer to a different
original artifact version. Cache original values as version references are
visited, including CI-friendly properties before project-version rewriting.
After rewriting, reject shared properties that would change a preserved
reference. This retains conflict detection regardless of reference order and
applies through the shared POM rewrite phases.
Validation:
- Reproduced the failure with the unchanged master plugin; the patched
`release:update-versions` advances the project and retains
`${previous.version}` at `1.0`.
- Added native POM rewrite regressions across update-versions, release,
development, and branch phases, including current-version updates, literal
references, shared-property conflicts in both orders, and CI-friendly version
conflicts.
- `mvn -Prun-its verify` passed with Maven 3.9.16 and Java 21.
- Final focused regressions passed on Java 8 and Java 21.
This change is limited to locally resolvable literal property values; it
does not add resolution of inherited properties or composed expressions.
Checklist:
- [x] This pull request addresses one issue.
- [x] The description explains what changed, how, and why.
- [x] The commit has a meaningful subject and body.
- [x] Added regression tests that fail without the production fix.
- [x] Basic verification passed through `mvn -Prun-its verify`.
- [x] Integration tests passed with `mvn -Prun-its verify`.
- [ ] I hereby declare this contribution to be licenced under the [Apache
License Version 2.0, January 2004](https://www.apache.org/licenses/LICENSE-2.0).
- [ ] In any other case, please file an [Apache Individual Contributor
License Agreement](https://www.apache.org/licenses/icla.pdf).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]