You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Michael Osipov (JIRA)" <ji...@apache.org> on 2015/12/29 00:32:49 UTC

[jira] [Updated] (MNG-4723) scope="system" errors are difficult to diagnose because the error message is wrong

     [ https://issues.apache.org/jira/browse/MNG-4723?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Michael Osipov updated MNG-4723:
--------------------------------
    Fix Version/s:     (was: Issues to be reviewed for 3.x)

> scope="system" errors are difficult to diagnose because the error message is wrong
> ----------------------------------------------------------------------------------
>
>                 Key: MNG-4723
>                 URL: https://issues.apache.org/jira/browse/MNG-4723
>             Project: Maven
>          Issue Type: Bug
>          Components: POM
>    Affects Versions: 2.2.1
>         Environment: Apache Maven 2.2.1 (r801777; 2009-08-06 20:16:01+0100)
> Java version: 1.6.0_20
> Java home: C:\jdk1.6.0_20\jre
> Default locale: en_GB, platform encoding: Cp1252
> OS name: "windows xp" version: "5.1" arch: "x86" Family: "windows"
>            Reporter: Sebb
>
> The following pom contents:
> {code:xml}
>   <dependencies>
>     <dependency>
>       <groupId>junit</groupId>
>       <artifactId>junit</artifactId>
>       <version>3.8.1</version>
>       <scope>system</scope>
>       <systemPath>c:/x/y/x</systemPath>
>     </dependency>
>   </dependencies>
> {code}
> generates the output:
> {noformat}
> [INFO] Failed to resolve artifact.
> Missing:
> ----------
> 1) junit:junit:jar:3.8.1
>   Try downloading the file manually from the project website.
>   Then, install it using the command:
>       mvn install:install-file -DgroupId=junit -DartifactId=junit -Dversion=3.8.1 -Dpackaging=jar -Dfile=/path/to/file
>   Alternatively, if you host your own repository you can deploy the file there:
>       mvn deploy:deploy-file -DgroupId=junit -DartifactId=junit -Dversion=3.8.1 -Dpackaging=jar -Dfile=/path/to/file -Du
> rl=[url] -DrepositoryId=[id]
>   Path to dependency:
>         1) org.home.mvnsample:mvnsample:jar:1.0-ALPHA2
>         2) junit:junit:jar:3.8.1
> ----------
> 1 required artifact is missing.
> for artifact:
>   org.home.mvnsample:mvnsample:jar:1.0-ALPHA2
> from the specified remote repositories:
>   central (http://repo1.maven.org/maven2)
> {noformat}
> This implies that the {{junit.jar}} is being sought in Maven Central, whereas in fact it is supposed to be in a local directory.
> It would be a lot easier to debug errors in the systemPath if the error message showed where Maven was actually looking for it.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)