Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 339329

Summary: exclude refactoring results in broken pom(s)
Product: z_Archived Reporter: Milos Kleint <mkleint>
Component: m2eAssignee: Project Inbox <m2e.core-inbox>
Status: CLOSED INVALID QA Contact:
Severity: normal    
Priority: P3 CC: igor
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Mac OS X - Carbon (unsup.)   
Whiteboard:

Description Milos Kleint CLA 2011-03-09 04:29:09 EST
have a POM A which is a parent of POM B.

in POM B have a dependency both in managed section and as dependency.

attempt to exclude a transitive dependency from B (transitive via the managed dependency added above)
in the refactoring's selection page select the POM A as the place for exclusion.

click finish. 

ERROR: You end up with both POM A and B being broken. Because the dependency was pulled up while the managed section was not. Therefore the dependency version is missing.

This issue is related to my comment here: https://bugs.eclipse.org/bugs/show_bug.cgi?id=337565#c10

I consider not moving dependencies up a better solution than moving the managed definition up as well.

A variant to this issue is when the parent already has a managed definition as well, but with different version. Then you don't end up with errors but still get unwanted side-effect of  using different set of dependencies (instead of just excluding a transitive one)
Comment 1 Igor Fedorenko CLA 2013-09-28 22:42:11 EDT
closing old/stale bugreports
Comment 2 Denis Roy CLA 2021-04-19 13:26:38 EDT
Moved to https://github.com/eclipse-m2e/m2e-core/issues/