-
Notifications
You must be signed in to change notification settings - Fork 123
Bug 564787 - NPE when resolving remote Filesystem project with Eclips… #5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug 564787 - NPE when resolving remote Filesystem project with Eclips… #5
Conversation
4f1db1d
to
a313386
Compare
contains the same patch as gerrit change 4: https://git.eclipse.org/r/plugins/gitiles/m2e/m2e-core/+/3d0483677a293ab948cccc658c794732fe1c1a98 |
* @deprecated use {@link #readMavenModel(InputStream)} instead. | ||
*/ | ||
@SuppressWarnings("deprecation") | ||
@Deprecated | ||
public org.apache.maven.model.Model readMavenModel(File pomFile) throws CoreException { | ||
return maven.readModel(pomFile); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's use
try (InputStream is = new FileInputStream(pomFile)) {
return maven.readModel(is);
} catch (IOException ex) {
throw new CoreException(new Status(IStatus.ERROR, IMavenConstants.PLUGIN_ID, -1, null, ex));
}
and get rid of the @SuppressWarnings.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
actually, it's ok like this, let's not bother more than necessary ;)
This change looks good. I hope I'll be able to fix the CI job today to get it running the tests and so on to validate it before we can merge. |
An important patch fixing some versioning issue was merged and make the build behave a bit better. Can you please rebase your patch and |
a313386
to
4001cb5
Compare
Yes sure, I've just rebased on top of the m2e-core/master should be up to date now. |
That's better ;) However, as described in https://github.com/eclipse-m2e/m2e-core/blob/master/CONTRIBUTING.md#%EF%B8%8F-version-bump , you need to increase the version of the bundle you modified (and of including references) in case no change did happen since last release. |
The last commit is mostly to be discarded. Please first rebase on top of master, and then only update the version of the bundles you modified. |
The thing is that almost every bundle has a dependency to m2e.core .... which I have changed. So I thought they must be adjusted too. |
…eWorkspaceArtifactRepository - Use EFS cache to create real local java.io.File representations of remotely available POM.xml files - Avoid conversion to java.io.File at all and prefer InputStream reading since that works also for remote FS. Change-Id: I0000000000000000000000000000000000000000 Signed-off-by: Reguel Wermelinger <reguel.wermelinger@ivyteam.ch>
Signed-off-by: Reguel Wermelinger <reguel.wermelinger@ivyteam.ch>
b7287e9
to
19f4348
Compare
Yes, it's a flaky test and can be ignored. |
Thanks a lot for your help and guidance @mickaelistria |
…eWorkspaceArtifactRepository
Change-Id: I0000000000000000000000000000000000000000
Signed-off-by: Reguel Wermelinger reguel.wermelinger@ivyteam.ch