Skip to content

[maven-4.0.x] Fix #12080: mvnup - comment out dependencies with undefined property expressions#12099

Open
gnodet wants to merge 2 commits into
maven-4.0.xfrom
backport-12083-to-4.0.x
Open

[maven-4.0.x] Fix #12080: mvnup - comment out dependencies with undefined property expressions#12099
gnodet wants to merge 2 commits into
maven-4.0.xfrom
backport-12083-to-4.0.x

Conversation

@gnodet
Copy link
Copy Markdown
Contributor

@gnodet gnodet commented May 19, 2026

Backport of #12083 to maven-4.0.x.

Fixes #12080: mvnup now comments out dependencies with undefined property expressions instead of failing.

Note: This PR depends on #12082 (domtrip migration on 4.0.x).

Claude Code on behalf of Guillaume Nodet

gnodet added a commit that referenced this pull request May 19, 2026
@gnodet gnodet added this to the 4.0.0-rc-6 milestone May 19, 2026
…expressions

Add a new compatibility fix to CompatibilityFixStrategy that detects
dependencies whose coordinate fields (groupId, artifactId, version)
contain ${...} expressions referencing properties not defined in any
project POM. These orphan dependencies cause Maven 4's validator to
reject them with "Not fully interpolated dependency" errors.

The fix collects all properties from <properties> sections across the
reactor (including profiles), skips well-known built-in properties
(project.*, env.*, settings.*, maven.*, revision, sha1, changelist,
etc.), and comments out dependencies with truly undefined expressions
using <!-- mvnup: commented out - undefined property '...' --> format.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@gnodet gnodet force-pushed the backport-12083-to-4.0.x branch from 1403fc8 to 242d990 Compare May 19, 2026 20:01
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
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