[ 
https://issues.apache.org/jira/browse/MNG-7771?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17795390#comment-17795390
 ] 

Tamas Cservenak commented on MNG-7771:
--------------------------------------

There are several of these:

[https://github.com/apache/maven/blob/master/maven-artifact/src/main/java/org/apache/maven/artifact/resolver/ArtifactResolutionException.java]

But we talk about resolver one:

[https://github.com/apache/maven-resolver/blob/master/maven-resolver-api/src/main/java/org/eclipse/aether/resolution/ArtifactResolutionException.java]

Yes, Resolver 2.0.0 makes possible now to create more meaningful (and precise) 
messages, as this new method is added:

https://github.com/apache/maven-resolver/blob/master/maven-resolver-api/src/main/java/org/eclipse/aether/resolution/ArtifactResult.java#L141

> Don't use ArtifactResolutionException#getMessage() w/o knowing whether there 
> are other exceptions or not
> --------------------------------------------------------------------------------------------------------
>
>                 Key: MNG-7771
>                 URL: https://issues.apache.org/jira/browse/MNG-7771
>             Project: Maven
>          Issue Type: Sub-task
>    Affects Versions: 3.8.8, 3.9.1, 4.0.0-alpha-5
>            Reporter: Michael Osipov
>            Priority: Major
>             Fix For: 3.9.x-candidate, 4.0.x-candidate, 4.0.0, 4.0.0-alpha-10
>
>
> {{ArtifactResolutionException#getMessage()}} only considers the message from 
> the first cause, completely ignoring other causes. So it is order-dependent 
> and can be misleading. Create an expeception-agnotic message and all 
> submessages shall be retrieved through API.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to