You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "Joerg Schaible (JIRA)" <ji...@codehaus.org> on 2006/05/12 12:25:40 UTC
[jira] Created: (MNG-2292) Properties have no scope
Properties have no scope
------------------------
Key: MNG-2292
URL: http://jira.codehaus.org/browse/MNG-2292
Project: Maven 2
Type: Bug
Components: Inheritence and Interpolation
Versions: 2.0.4
Reporter: Joerg Schaible
If a property is overwritten in a chiuld POM, the parent's property will also change! This leeds to unexpected results for interpolation.
Example:
Have a parent POM with:
{noformat}
...
<groupId>test</groupId>
<artifactId>parent</parent>
<version>1</version>
<url>${my.url}</url>
...
<modules>
<module>child</module>
</modules>
...
<properties>
<my.url>http://parent</my.url>
</properties>
...
{noformat}
and a child POM with:
{noformat}
...
<parent>
<groupId>test</groupId>
<artifactId>parent</parent>
<version>1</version>
</parent>
<url>${my.url}</url>
...
<properties>
<my.url>http://child</my.url>
</properties>
...
{noformat}
Look at the effective-pom for the parent, its URL is now also "http://child". The properties should have a scope and should not be backpropagated to the parent.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Closed: (MNG-2292) Properties have no scope
Posted by "Joerg Schaible (JIRA)" <ji...@codehaus.org>.
[ http://jira.codehaus.org/browse/MNG-2292?page=all ]
Joerg Schaible closed MNG-2292:
-------------------------------
Resolution: Cannot Reproduce
Invalid report, I was fooled by the output of help:effective-pom that contains the child pom as well as the parent pom.
> Properties have no scope
> ------------------------
>
> Key: MNG-2292
> URL: http://jira.codehaus.org/browse/MNG-2292
> Project: Maven 2
> Type: Bug
> Components: Inheritence and Interpolation
> Versions: 2.0.4
> Reporter: Joerg Schaible
>
>
> If a property is overwritten in a chiuld POM, the parent's property will also change! This leeds to unexpected results for interpolation.
> Example:
> Have a parent POM with:
> {noformat}
> ...
> <groupId>test</groupId>
> <artifactId>parent</parent>
> <version>1</version>
> <url>${my.url}</url>
> ...
> <modules>
> <module>child</module>
> </modules>
> ...
> <properties>
> <my.url>http://parent</my.url>
> </properties>
> ...
> {noformat}
> and a child POM with:
> {noformat}
> ...
> <parent>
> <groupId>test</groupId>
> <artifactId>parent</parent>
> <version>1</version>
> </parent>
> <url>${my.url}</url>
> ...
> <properties>
> <my.url>http://child</my.url>
> </properties>
> ...
> {noformat}
> Look at the effective-pom for the parent, its URL is now also "http://child". The properties should have a scope and should not be backpropagated to the parent.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira