You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ant.apache.org by "Jaikiran Pai (Jira)" <ji...@apache.org> on 2019/11/22 01:48:00 UTC

[jira] [Commented] (IVY-1616) useOrigin="true" fails with file-based ibiblio

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

Jaikiran Pai commented on IVY-1616:
-----------------------------------

Hello Eric, just to be sure, this metadata in the cache was generated by this new version of Ivy 2.5.0, right? I mean, the cache was new when this project was built? We had some issues in a previous version of Ivy which would cause metadata parsing issues, so just checking, before I look more into this.

> useOrigin="true" fails with file-based ibiblio
> ----------------------------------------------
>
>                 Key: IVY-1616
>                 URL: https://issues.apache.org/jira/browse/IVY-1616
>             Project: Ivy
>          Issue Type: Bug
>    Affects Versions: 2.5.0
>            Reporter: Eric Milles
>            Assignee: Jaikiran Pai
>            Priority: Major
>
> We are trying to use Maven's artifacts if they have already been downloaded.  To that end, we have a file-based {{ibiblio}} resolver that points to the local .m2 repository directory.  If maven is used to download an artifact so that it is in .m2 and not in Ivy's cache, we are getting errors from the origin check in {{DefaultRepositoryCacheManager}}.
> {code}
>     java.lang.IllegalArgumentException: org.apache.maven.shared#maven-shared-utils;3.2.1!maven-shared-utils.jar origin location must be absolute: file:/C:/Users/Name/.m2/repository/org/apache/maven/shared/maven-shared-utils/3.2.1/maven-shared-utils-3.2.1.jar
>         at org.apache.ivy.util.Checks.checkAbsolute(Checks.java:57)
>         at org.apache.ivy.core.cache.DefaultRepositoryCacheManager.getArchiveFileInCache(DefaultRepositoryCacheManager.java:410)
>         at org.apache.ivy.core.cache.DefaultRepositoryCacheManager.download(DefaultRepositoryCacheManager.java:996)
>         at org.apache.ivy.plugins.resolver.BasicResolver.download(BasicResolver.java:836)
>         at org.apache.ivy.plugins.resolver.RepositoryResolver.download(RepositoryResolver.java:305)
>         at org.apache.ivy.plugins.resolver.IBiblioResolver.download(IBiblioResolver.java:563)
>         at org.apache.ivy.core.resolve.ResolveEngine.downloadArtifacts(ResolveEngine.java:405)
>         at org.apache.ivy.core.resolve.ResolveEngine.resolve(ResolveEngine.java:351)
>         at org.apache.ivy.Ivy.resolve(Ivy.java:522)
> {code}
> {code:xml}
> <ivysettings>
>   <caches useOrigin="true"/>
>   <resolvers>
>     <chain name="X" returnFirst="true">
>       <ibiblio name="localm2" root="file:/C:/Users/Name/.m2/repository/" checkmodified="true" changingPattern=".*" changingMatcher="regexp" m2compatible="true"/>
>       <ibiblio name="ibiblio" m2compatible="true"/>
>     </chain>
>   </resolvers>
>   <settings defaultResolver="X"/>
> </ivysettings>
> {code}



--
This message was sent by Atlassian Jira
(v8.3.4#803005)