Maven 2 & 3

Invalid systemPath allows build to continue--failing in later phase.

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Minor Minor
  • Resolution: Fixed
  • Affects Version/s: 2.0.7
  • Fix Version/s: 2.0.9
  • Component/s: Dependencies
  • Labels:
    None
  • Number of attachments :
    1

Description

When the system scoped dependency is specified as follows:

<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>system</scope>
<systemPath>${env.USERPROFILE}/.m2/repository/junit/junit/3.8.1/junit-3.8.2.jar</systemPath>
</dependency>

Maven fails and complains correctly (junit-3.8.2.jar is incorrect, and should be junit-3.8.1.jar).

However, when the following is used:

<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>system</scope>
<systemPath>${env.USERPROFILE}/.m2/repository/junit/junit</systemPath>
</dependency>

Maven DOES NOT COMPLAIN, the build process proceeds and fails later in the compile/testCompile build phases since the dependency is not available. You can see attached minimal project.

FYI-This was tested on a Windows XP system, I have not yet tried to replicate this issue on *nix.

Issue Links

Activity

Hide
Vincent Siveton added a comment -

verify that the system-scoped artifact is a file: fixed in r60896

Show
Vincent Siveton added a comment - verify that the system-scoped artifact is a file: fixed in r60896

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: