Issue Details (XML | Word | Printable)

Key: MNG-3448
Type: Bug Bug
Status: Open Open
Priority: Major Major
Assignee: Unassigned
Reporter: Hilco Wijbenga
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Maven 2

Infinite Loop When Using project.version in Modules Build

Created: 07/Mar/08 01:10 PM   Updated: 12/Jun/08 06:03 PM
Component/s: POM
Affects Version/s: 2.0.8
Fix Version/s: 2.0.x

Time Tracking:
Not Specified


 Description  « Hide
I have the following setup:

org.example.pom/pom.xml:
<?xml version="1.0" encoding="UTF-8"?>
<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
>
<modelVersion>4.0.0</modelVersion>
<groupId>org.example</groupId>
<artifactId>pom</artifactId>
<packaging>pom</packaging>
<version>1</version>
<name>POM</name>
<properties>
<webapp.version>${project.version}</webapp.version>
</properties>
</project>

and org.example.jar/pom.xml:
<?xml version="1.0" encoding="UTF-8"?>
<project
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
>
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>org.example</groupId>
<artifactId>pom</artifactId>
<version>1</version>
<relativePath>../org.example.pom/pom.xml</relativePath>
</parent>
<groupId>org.example</groupId>
<artifactId>jar</artifactId>
<packaging>jar</packaging>
<version>${webapp.version}</version>
<name>JAR</name>
</project>

Running "mvn clean" in org.example.jar yields just

[INFO] Scanning for projects...

and then Maven hangs. Replacing "${project.version}" with a simple "0.1" allows things to work properly.

My environment:
Maven version: 2.0.8
Java version: 1.5.0_14
OS name: "linux" version: "2.6.24-gentoo-r2" arch: "i386" Family: "unix"



 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
There are no comments yet on this issue.