Maven 2.x and 3.x Site Plugin

site not reading properly with properties

Details

  • Type: Bug Bug
  • Status: Closed Closed
  • Priority: Critical Critical
  • Resolution: Won't Fix
  • Affects Version/s: 2.0-beta-6, 2.0
  • Fix Version/s: None
  • Component/s: property interpolation
  • Labels:
    None
  • Environment:
    Ubuntu 8.0.4, Windows XP, Sun JDK 1.6, Sun JDK 1.5
  • Testcase included:
    yes
  • Number of attachments :
    1

Description

The site goal does not read the correct properties from a parent pom if the properties are used to set the version of the artifact.

For the attached project "mvn install" works but "mvn site" fails.

Issue Links

Activity

Hide
Brett Porter added a comment -

moving to site plugin to confirm whether the issue is in there or core

Show
Brett Porter added a comment - moving to site plugin to confirm whether the issue is in there or core
Hide
Dennis Lundberg added a comment -

I have verified that running 'mvn site' fails with 2.0-beta-6:

[INFO] [site:site]
Downloading: http://repo1.maven.org/maven2/group/artifact/${version.major}.${version.minor}/artifact-${version.major}.${version.minor}.pom
[INFO] Parent project loaded from repository.
Downloading: http://repo1.maven.org/maven2/group/artifact/${version.major}.${version.minor}/artifact-${version.major}.${version.minor}-site_en.xml
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR

With 2.0-beta-7 'mvn site' succeeds, but it's still trying to download the site descriptor using unresolved properties:

[INFO] [site:site]
Downloading: http://repo1.maven.org/maven2/group/artifact/${version.major}.${version.minor}/artifact-${version.major}.${version.minor}.pom
[INFO] Parent project loaded from repository.
Downloading: http://repo1.maven.org/maven2/group/artifact/${version.major}.${version.minor}/artifact-${version.major}.${version.minor}-site_en.xml
Downloading: http://repo1.maven.org/maven2/group/artifact/${version.major}.${version.minor}/artifact-${version.major}.${version.minor}-site.xml
[WARNING] No URL defined for the project - decoration links will not be resolved
[INFO] Generating "Issue Tracking" report.
...
Show
Dennis Lundberg added a comment - I have verified that running 'mvn site' fails with 2.0-beta-6:
[INFO] [site:site]
Downloading: http://repo1.maven.org/maven2/group/artifact/${version.major}.${version.minor}/artifact-${version.major}.${version.minor}.pom
[INFO] Parent project loaded from repository.
Downloading: http://repo1.maven.org/maven2/group/artifact/${version.major}.${version.minor}/artifact-${version.major}.${version.minor}-site_en.xml
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
With 2.0-beta-7 'mvn site' succeeds, but it's still trying to download the site descriptor using unresolved properties:
[INFO] [site:site]
Downloading: http://repo1.maven.org/maven2/group/artifact/${version.major}.${version.minor}/artifact-${version.major}.${version.minor}.pom
[INFO] Parent project loaded from repository.
Downloading: http://repo1.maven.org/maven2/group/artifact/${version.major}.${version.minor}/artifact-${version.major}.${version.minor}-site_en.xml
Downloading: http://repo1.maven.org/maven2/group/artifact/${version.major}.${version.minor}/artifact-${version.major}.${version.minor}-site.xml
[WARNING] No URL defined for the project - decoration links will not be resolved
[INFO] Generating "Issue Tracking" report.
...
Hide
Erlend Hamnaberg added a comment -

I can verify that this still occurs using 2.0

Show
Erlend Hamnaberg added a comment - I can verify that this still occurs using 2.0
Hide
Lukas Theussl added a comment -

I don't know why 'install' works in this case, it shouldn't IMO. The module defines its parent version via properties that are only defined in the parent, which is impossible to resolve. Maven 3 emits a warning for this setup, but I guess it only works to keep some historic feature.

Show
Lukas Theussl added a comment - I don't know why 'install' works in this case, it shouldn't IMO. The module defines its parent version via properties that are only defined in the parent, which is impossible to resolve. Maven 3 emits a warning for this setup, but I guess it only works to keep some historic feature.

People

Vote (5)
Watch (7)

Dates

  • Created:
    Updated:
    Resolved: