gnodet commented on PR #456:
URL: 
https://github.com/apache/maven-install-plugin/pull/456#issuecomment-5804206827

   After investigating the reviewer's observation: the IT is indeed a false 
green, not a false negative from a missing fix.
   
   Root cause: in `DefaultProject.getArtifacts()`, for a `pom`-packaged 
project, `ArtifactIdUtils.equalsVersionlessId(pomArtifact, projectArtifact)` is 
`true` (same coordinates), so the returned list has only one element — the POM 
artifact. `getMainArtifact()` returns `Optional.empty()`.
   
   This means `install:install` only ever deals with the POM artifact, whose 
path comes from `project.getPomPath()` via `setPath(project.getPomArtifact(), 
project.getPomPath())` — and the install proceeds correctly regardless of the 
`DefaultArtifactManager.getPath()` fix.
   
   So the bug either does not manifest on Maven 4 with `pom` packaging + 
`jar:jar`, or it only manifests in a specific scenario I haven't yet 
identified. Closing this PR — the core fix in apache/maven#13256 stands (it's a 
correctness issue in the priority order of the `paths` map vs project artifact 
file), but I'll need to either find a concrete reproducer or re-scope the fix 
accordingly.


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