Skip to content

Conversation

@kwin
Copy link
Member

@kwin kwin commented Dec 5, 2025

This will also interpolate correctly.
Use ProjectBuilder instead of ModelProcessor to parse the POM. Encapsulate in a dedicated MavenExecutionContext.

This closes #1948

@kwin kwin force-pushed the bugfix/interpolate-model-prior-import branch from 3487642 to 39e00e7 Compare December 5, 2025 12:23
This will also interpolate correctly.
Use ProjectBuilder instead of ModelProcessor to parse the POM.
Encapsulate in a dedicated MavenExecutionContext.

This closes #1948
@kwin kwin force-pushed the bugfix/interpolate-model-prior-import branch from 39e00e7 to bfccdd3 Compare December 5, 2025 12:23
@laeubi
Copy link
Member

laeubi commented Dec 5, 2025

@kwin please be aware that at some places we might need the raw model as we can not create a full maven session now. Also interpolation is maybe not always wanted. So if project import is the use-case here, I would suggest to

  1. create a testcase for this particular case
  2. only change it there by starting a session beforehands

@kwin
Copy link
Member Author

kwin commented Dec 5, 2025

at some places we might need the raw model as we can not create a full maven session now. Also interpolation is maybe not always wanted

Can you elaborate? What are those places? Under which circumstances you don't want interpolation?

@github-actions
Copy link

github-actions bot commented Dec 5, 2025

Test Results

  327 files  ±0    327 suites  ±0   1h 26m 9s ⏱️ - 1m 4s
  692 tests ±0    660 ✅  - 14  16 💤 ±0   7 ❌ + 6   9 🔥 + 8 
2 076 runs  ±0  1 988 ✅  - 38  48 💤 ±0  17 ❌ +16  23 🔥 +22 

For more details on these failures and errors, see this check.

Results for commit f223e39. ± Comparison against base commit 3785255.

♻️ This comment has been updated with latest results.

@eclipse-m2e-bot
Copy link
Contributor

This pull request changes some projects for the first time in this development cycle.
Therefore the following files need a version increment:

org.eclipse.m2e.feature/feature.xml
org.eclipse.m2e.scm/META-INF/MANIFEST.MF
org.eclipse.m2e.sdk.feature/feature.xml
org.eclipse.m2e.tests.common/META-INF/MANIFEST.MF

An additional commit containing all the necessary changes was pushed to the top of this PR's branch. To obtain these changes (for example if you want to push more changes) either fetch from your fork or apply the git patch.

Git patch
From 762d3c29fad62a997fa37a8947a888464bb26fc1 Mon Sep 17 00:00:00 2001
From: Eclipse M2E Bot <[email protected]>
Date: Fri, 5 Dec 2025 12:31:39 +0000
Subject: [PATCH] Version bump(s) for null object or invalid expression stream


diff --git a/org.eclipse.m2e.feature/feature.xml b/org.eclipse.m2e.feature/feature.xml
index b637f8d3..2338b427 100644
--- a/org.eclipse.m2e.feature/feature.xml
+++ b/org.eclipse.m2e.feature/feature.xml
@@ -2,7 +2,7 @@
 <feature
       id="org.eclipse.m2e.feature"
       label="%featureName"
-      version="2.10.0.qualifier"
+      version="2.11.0.qualifier"
       provider-name="%providerName"
       plugin="org.eclipse.m2e.core"
       license-feature="org.eclipse.license"
diff --git a/org.eclipse.m2e.scm/META-INF/MANIFEST.MF b/org.eclipse.m2e.scm/META-INF/MANIFEST.MF
index 0c1560c2..bf7195e5 100644
--- a/org.eclipse.m2e.scm/META-INF/MANIFEST.MF
+++ b/org.eclipse.m2e.scm/META-INF/MANIFEST.MF
@@ -1,7 +1,7 @@
 Manifest-Version: 1.0
 Bundle-ManifestVersion: 2
 Bundle-SymbolicName: org.eclipse.m2e.scm;singleton:=true
-Bundle-Version: 2.1.100.qualifier
+Bundle-Version: 2.1.200.qualifier
 Bundle-RequiredExecutionEnvironment: JavaSE-21
 Bundle-Name: %Bundle-Name
 Bundle-Vendor: %Bundle-Vendor
diff --git a/org.eclipse.m2e.sdk.feature/feature.xml b/org.eclipse.m2e.sdk.feature/feature.xml
index e316e45d..c513f5c2 100644
--- a/org.eclipse.m2e.sdk.feature/feature.xml
+++ b/org.eclipse.m2e.sdk.feature/feature.xml
@@ -2,7 +2,7 @@
 <feature
       id="org.eclipse.m2e.sdk.feature"
       label="%featureName"
-      version="2.10.101.qualifier"
+      version="2.11.0.qualifier"
       provider-name="%providerName"
       license-feature="org.eclipse.license"
       license-feature-version="0.0.0">
diff --git a/org.eclipse.m2e.tests.common/META-INF/MANIFEST.MF b/org.eclipse.m2e.tests.common/META-INF/MANIFEST.MF
index 37eacaf9..840fe66a 100644
--- a/org.eclipse.m2e.tests.common/META-INF/MANIFEST.MF
+++ b/org.eclipse.m2e.tests.common/META-INF/MANIFEST.MF
@@ -2,7 +2,7 @@ Manifest-Version: 1.0
 Bundle-ManifestVersion: 2
 Bundle-Name: M2E Testing Helpers
 Bundle-SymbolicName: org.eclipse.m2e.tests.common;singleton:=true
-Bundle-Version: 2.1.1.qualifier
+Bundle-Version: 2.1.101.qualifier
 Require-Bundle: org.junit;bundle-version="4.0.0",
  org.eclipse.m2e.core;bundle-version="[2.0.0,3.0.0)",
  org.eclipse.m2e.maven.runtime;bundle-version="[3.9.900,4.0.0)",
-- 
2.52.0

Further information are available in Common Build Issues - Missing version increments.

* @deprecated Use {@link #readMavenModel(File, IProgressMonitor)} instead.
*/
@Deprecated
public org.apache.maven.model.Model readMavenModel(File pomFile) throws CoreException {
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@laeubi Are you suggesting to keep this as is (i.e. raw model) and rather introduce a new method for returning the effective model? The only consumer for the raw model I see within m2e is probably org.eclipse.m2e.tests.common/src/org/eclipse/m2e/tests/common/AbstractMavenProjectTestCase.java...

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.

"Import existing Maven projects" does not recognize modules leveraging interpolated properties

4 participants