gnodet commented on PR #13086:
URL: https://github.com/apache/maven/pull/13086#issuecomment-5686093314

   Addressing gnodet-bot's second finding re: the FATAL escalation for explicit 
`<relativePath>`:
   
   The behavioral change (WARNING → FATAL when `<relativePath>` is explicitly 
set to a mismatched POM) is **intentional**. The original WARNING was, frankly, 
too silent for a case where the user has made a deliberate, explicit 
configuration error: they wrote `<relativePath>../wrong-pom.xml</relativePath>` 
and that POM has the wrong GA. There is no ambiguity — Maven is not guessing 
here, it is checking what the user explicitly told it to check.
   
   The null case (omitted `<relativePath>`) is different: Maven fills in the 
default `../pom.xml` itself, so a mismatch there is expected in common layouts 
(multi-project builds where not every module is a child of its directory 
neighbour). A WARNING and fallback to repository resolution is the right 
behavior there.
   
   Keeping FATAL for the explicit case aligns with the Maven 4 
`DefaultModelBuilder` spirit (strict when the user is explicit, lenient when 
Maven is guessing) and closes a real correctness gap. Projects that relied on 
the WARNING for an explicit mismatch should fix their POM structure — that was 
always a misconfiguration.


-- 
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]

Reply via email to