groovy-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mike Robinet (JIRA)" <j...@apache.org>
Subject [jira] [Created] (GROOVY-8655) Grapes fails to download artifact if POM exists in m2 local, but jar does not
Date Wed, 20 Jun 2018 17:02:00 GMT
Mike Robinet created GROOVY-8655:
------------------------------------

             Summary: Grapes fails to download artifact if POM exists in m2 local, but jar
does not
                 Key: GROOVY-8655
                 URL: https://issues.apache.org/jira/browse/GROOVY-8655
             Project: Groovy
          Issue Type: Bug
          Components: Grape
    Affects Versions: 2.5.0
         Environment: Groovy Version: 2.5.0 JVM: 1.8.0_172 Vendor: Azul Systems, Inc. OS:
Mac OS X
            Reporter: Mike Robinet
         Attachments: grapeError.log

 

*Steps to reproduce:*
 * These instructions use slf4j-api as an example, but it is reproducible with any artifact.
 * Remove local Grapes cache: {{rm -rf ~/.groovy/Grapes}}
 * Remove org.slf4j:slf4j-api artifacts from Maven local cache: {{rm -rf ~/.m2/repository/org/slf4j/slf4j-api}}
 * Remove any custom Ivy or Grapes config
 * Download POM only for slf4j-api: {{mvn dependency:get -Dartifact=org.slf4j:slf4j-api:1.7.25:pom
-Dtransitive=false}}
 * Attempt to install slf4j-api using Grapes: {{grape -V install org.slf4j slf4j-api 1.7.25}}

*Expected behavior:*
 * slf4j-api 1.7.25 jar is downloaded from jcenter

*Actual Behavior:*
 * Fails to retrieve jar with NOT FOUND error (verbose log attached):

 
{noformat}
:: problems summary ::
:::: WARNINGS
 [NOT FOUND  ] org.slf4j#slf4j-api;1.7.25!slf4j-api.jar (0ms)
 ==== localm2: tried
   file:/Users/Mike/.m2/repository/org/slf4j/slf4j-api/1.7.25/slf4j-api-1.7.25.jar
{noformat}

*Workaround:*
 * Delete slf4j-api/1.7.25 folder in Maven local and Grapes cache folder and reinstall.

*Additional notes:*

It is fairly common to only have the POM file for artifacts in your Maven local. I use the
[gradle-versions-plugin|https://github.com/ben-manes/gradle-versions-plugin] frequently which
is just one example of a tool that downloads only POM files for artifacts. 



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message