Dennis Lundberg wrote:
Hi
I've tracked it down to the new URIPathDescriptor class in
doxia-decoration-model.
Here are some debug output from a simple test:
base=file:///C:/Foo/
link=bar
uriPathDescriptor.getBaseURI()=file:///C:/Foo/
uriPathDescriptor.getBaseURI().normalize()=file:///C:/Foo/
uriPathDescriptor.getBaseURI().resolve(link)=file:/C:/Foo/bar
uriPathDescriptor.toString()=file:/C:/Foo/bar
As you can see resolve() and toString() (which calls the former) doesn't
quite return what you'd expect, at least not what I expect. They strip
two slashes // from the input, rendering an invalid URI.
The test cases for the class have tests for this, but they expect the
file URI:s to have only a single slash after the first colon, like this one
compare = new URIPathDescriptor( "file:///C:\\Foo\\bar1", "" );
assertEquals( "file:/C:/Foo/bar1/", compare.toString() );
I think this is wrong, but perhaps Lukas can shed some light on it. In
my mind this should return "file:///C:/Foo/bar1/".
You are right, that's what I would expect as well, but apparently that's
the behavior of the resolve(link) method in java.net.URI [1]. Anyway, I
would like to understand how this affects the problem we see in the site
plugin, are you saying that these tests should fail on windows? They are
fine on jenkins [2].
Thanks for looking into it!
-Lukas
[1]
http://download.oracle.com/javase/6/docs/api/java/net/URI.html#resolve(java.net.URI)
[2]
https://builds.apache.org/hudson/view/M-R/view/Maven/job/Maven-Doxia-Sitetools/
On 2011-03-12 13:17, Dennis Lundberg wrote:
I figured it was a Windows issue since you hadn't caught it before.
Thanks for the hint. I'll do some more testing to see if I can track it
down.
On 2011-03-12 11:12, Lukas Theussl wrote:
all it's pass for me locally on branch and trunk, but I can't test on
windows. if it's a relative link issue, it should be caused by
DefaultDecorationModelInheritanceAssembler, where the link
relitivization is done (method resolvePaths()).
HTH,
-Lukas
Dennis Lundberg wrote:
Hi
The failing IT was merged from trunk in r1078835 [1], together with the
its MSITE-159, MSITE-322, MSITE-537, site-stage-deploy.
I get the same failure on trunk locally on my Windows machine.
[1]
http://svn.apache.org/viewvc?limit_changes=0&view=revision&revision=1078835
On 2011-03-11 19:25, GRiD .ORG wrote:
See<https://grid.sonatype.org/ci/job/maven-site-plugin-3.x/./jdk=java-5x,label=windows/141/changes>
Changes:
[Dennis Lundberg] o Merge r1039749 from trunk.
[Dennis Lundberg] o Merge r1039748 from trunk.
[Dennis Lundberg] o Adjust white space.
------------------------------------------
[...truncated 6899 lines...]
[INFO] [INFO] Maven Rocks Plugin ................................
SUCCESS [7.642s]
[INFO] [INFO] Plugins ...........................................
SUCCESS [1.925s]
[INFO] [INFO] Aggregator ........................................
SUCCESS [0.230s]
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] BUILD SUCCESS
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] Total time: 10.233s
[INFO] [INFO] Finished at: Fri Mar 11 10:25:02 PST 2011
[INFO] [INFO] Final Memory: 10M/38M
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] Running post-build script:
x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\site-stage-deploy\verify.bsh
[INFO] Finished post-build script:
x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\site-stage-deploy\verify.bsh
[INFO] ..SUCCESS (13.9 s)
[INFO] Building: surefire-report\pom.xml
[INFO] Apache Maven 3.0.4-SNAPSHOT (r1076920; 2011-03-03 18:19:10-0800)
[INFO] Maven home: x:\slave\maven-it\3.0.x
[INFO] Java version: 1.5.0_22, vendor: Sun Microsystems Inc.
[INFO] Java home: x:\slave\tools\java-5x\jre
[INFO] Default locale: en_US, platform encoding: Cp1252
[INFO] OS name: "windows 7", version: "6.1", arch: "x86", family:
"windows"
[INFO] [INFO] Scanning for projects...
[INFO] [INFO]
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] Building surefire-report IT 1.0-SNAPSHOT
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO]
[INFO] [INFO] --- maven-clean-plugin:2.4.1:clean (default-clean) @
surefire-report ---
[INFO] [INFO]
[INFO] [INFO] --- maven-site-plugin:3.0-beta-4-SNAPSHOT:site
(default-cli) @ surefire-report ---
[INFO] [INFO] configuring report plugin
org.apache.maven.plugins:maven-surefire-report-plugin:2.4.3
[INFO] [INFO]
[INFO] [INFO]>>> maven-surefire-report-plugin:2.4.3:report
(report:report) @ surefire-report>>>
[INFO] [INFO]
[INFO] [INFO] --- maven-resources-plugin:2.4.3:resources
(default-resources) @ surefire-report ---
[INFO] [WARNING] Using platform encoding (Cp1252 actually) to copy
filtered resources, i.e. build is platform dependent!
[INFO] [INFO] skip non existing resourceDirectory
X:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\surefire-report\src\main\resources
[INFO] [INFO]
[INFO] [INFO] --- maven-compiler-plugin:2.3.2:compile
(default-compile) @ surefire-report ---
[INFO] [WARNING] File encoding has not been set, using platform
encoding Cp1252, i.e. build is platform dependent!
[INFO] [INFO] Compiling 1 source file to
X:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\surefire-report\target\classes
[INFO] [INFO]
[INFO] [INFO] --- maven-resources-plugin:2.4.3:testResources
(default-testResources) @ surefire-report ---
[INFO] [WARNING] Using platform encoding (Cp1252 actually) to copy
filtered resources, i.e. build is platform dependent!
[INFO] [INFO] skip non existing resourceDirectory
X:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\surefire-report\src\test\resources
[INFO] [INFO]
[INFO] [INFO] --- maven-compiler-plugin:2.3.2:testCompile
(default-testCompile) @ surefire-report ---
[INFO] [WARNING] File encoding has not been set, using platform
encoding Cp1252, i.e. build is platform dependent!
[INFO] [INFO] Compiling 1 source file to
X:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\surefire-report\target\test-classes
[INFO] [INFO]
[INFO] [INFO] --- maven-surefire-plugin:2.7.2:test (default-test) @
surefire-report ---
[INFO] [INFO] Surefire report directory:
X:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\surefire-report\target\surefire-reports
[INFO]
[INFO] -------------------------------------------------------
[INFO] T E S T S
[INFO] -------------------------------------------------------
[INFO] Running org.apache.maven.plugins.site.its.AppTest
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0, Time
elapsed: 0.013 sec
[INFO]
[INFO] Results :
[INFO]
[INFO] Tests run: 1, Failures: 0, Errors: 0, Skipped: 0
[INFO]
[INFO] [INFO]
[INFO] [INFO]<<< maven-surefire-report-plugin:2.4.3:report
(report:report) @ surefire-report<<<
[INFO] [INFO]
[INFO] [INFO]>>> maven-surefire-report-plugin:2.4.3:report-only
(report:report-only) @ surefire-report>>>
[INFO] [INFO]
[INFO] [INFO]<<< maven-surefire-report-plugin:2.4.3:report-only
(report:report-only) @ surefire-report<<<
[INFO] [INFO] Relativizing decoration links with respect to project
URL: http://maven.apache.org
[INFO] [INFO] Rendering site with
org.apache.maven.skins:maven-default-skin:jar:1.0 skin.
[INFO] [INFO] Skipped "Surefire Report" report, file
"surefire-report.html" already exists for the English version.
[INFO] [INFO] Generating "Surefire Report" report ---
maven-surefire-report-plugin:2.4.3
[INFO] [WARNING] Unable to locate Test Source XRef to link to - DISABLED
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] BUILD SUCCESS
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] Total time: 6.157s
[INFO] [INFO] Finished at: Fri Mar 11 10:25:10 PST 2011
[INFO] [INFO] Final Memory: 9M/34M
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] Running post-build script:
x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\surefire-report\verify.groovy
[INFO] Finished post-build script:
x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\surefire-report\verify.groovy
[INFO] ..SUCCESS (7.7 s)
[INFO] Building: top-parent-no-site\pom.xml
[INFO] Apache Maven 3.0.4-SNAPSHOT (r1076920; 2011-03-03 18:19:10-0800)
[INFO] Maven home: x:\slave\maven-it\3.0.x
[INFO] Java version: 1.5.0_22, vendor: Sun Microsystems Inc.
[INFO] Java home: x:\slave\tools\java-5x\jre
[INFO] Default locale: en_US, platform encoding: Cp1252
[INFO] OS name: "windows 7", version: "6.1", arch: "x86", family:
"windows"
[INFO] [INFO] Scanning for projects...
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] Reactor Build Order:
[INFO] [INFO]
[INFO] [INFO] main
[INFO] [INFO] module 1
[INFO] [INFO]
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] Building main 1.0-SNAPSHOT
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO]
[INFO] [INFO] --- maven-clean-plugin:2.4.1:clean (default-clean) @
main ---
[INFO] [INFO]
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] Building module 1 1.0-SNAPSHOT
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO]
[INFO] [INFO] --- maven-clean-plugin:2.4.1:clean (default-clean) @
module1 ---
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] Reactor Summary:
[INFO] [INFO]
[INFO] [INFO] main ..............................................
SUCCESS [0.251s]
[INFO] [INFO] module 1 ..........................................
SUCCESS [0.005s]
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] BUILD SUCCESS
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] Total time: 0.428s
[INFO] [INFO] Finished at: Fri Mar 11 10:25:12 PST 2011
[INFO] [INFO] Final Memory: 1M/3M
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] Apache Maven 3.0.4-SNAPSHOT (r1076920; 2011-03-03 18:19:10-0800)
[INFO] Maven home: x:\slave\maven-it\3.0.x
[INFO] Java version: 1.5.0_22, vendor: Sun Microsystems Inc.
[INFO] Java home: x:\slave\tools\java-5x\jre
[INFO] Default locale: en_US, platform encoding: Cp1252
[INFO] OS name: "windows 7", version: "6.1", arch: "x86", family:
"windows"
[INFO] [INFO] Scanning for projects...
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] Reactor Build Order:
[INFO] [INFO]
[INFO] [INFO] main
[INFO] [INFO] module 1
[INFO] [INFO]
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] Building main 1.0-SNAPSHOT
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO]
[INFO] [INFO] --- maven-site-plugin:3.0-beta-4-SNAPSHOT:site
(default-cli) @ main ---
[INFO] [INFO] configuring report plugin
org.apache.maven.plugins:maven-project-info-reports-plugin:2.3.1
[INFO] [INFO] Relativizing decoration links with respect to project
URL: http://dummy.com/
[INFO] [INFO] Rendering site with
org.apache.maven.skins:maven-default-skin:jar:1.0 skin.
[INFO] [INFO] Generating "About" report ---
maven-project-info-reports-plugin:2.3.1
[INFO] [INFO]
[INFO] [INFO] --- maven-site-plugin:3.0-beta-4-SNAPSHOT:deploy
(default-cli) @ main ---
[INFO]
file://x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target/it/top-parent-no-site/deploy/
- Session: Opened
[INFO]
file://x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target/it/top-parent-no-site/deploy/
- Session: Disconnecting
[INFO]
file://x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target/it/top-parent-no-site/deploy/
- Session: Disconnected
[INFO] [INFO]
[INFO] [INFO] --- maven-site-plugin:3.0-beta-4-SNAPSHOT:stage
(default-cli) @ main ---
[INFO] [INFO] Using this directory for staging:
X:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\top-parent-no-site\target/staging
[INFO]
file://X:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\top-parent-no-site\target\staging
- Session: Opened
[INFO]
file://X:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\top-parent-no-site\target\staging
- Session: Disconnecting
[INFO]
file://X:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\top-parent-no-site\target\staging
- Session: Disconnected
[INFO] [INFO]
[INFO] [INFO] --- maven-site-plugin:3.0-beta-4-SNAPSHOT:stage-deploy
(default-cli) @ main ---
[INFO] [INFO] Using this URL for stage deploy:
file://x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target/it/top-parent-no-site/deploy//staging
[INFO]
file://x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target/it/top-parent-no-site/deploy//staging
- Session: Opened
[INFO]
file://x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target/it/top-parent-no-site/deploy//staging
- Session: Disconnecting
[INFO]
file://x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target/it/top-parent-no-site/deploy//staging
- Session: Disconnected
[INFO] [INFO]
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] Building module 1 1.0-SNAPSHOT
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO]
[INFO] [INFO] --- maven-site-plugin:3.0-beta-4-SNAPSHOT:site
(default-cli) @ module1 ---
[INFO] [INFO] configuring report plugin
org.apache.maven.plugins:maven-project-info-reports-plugin:2.3.1
[INFO] [INFO] Relativizing decoration links with respect to project
URL: http://dummy.com/module1/
[INFO] [INFO] Rendering site with
org.apache.maven.skins:maven-default-skin:jar:1.0 skin.
[INFO] [INFO] Generating "About" report ---
maven-project-info-reports-plugin:2.3.1
[INFO] [INFO]
[INFO] [INFO] --- maven-site-plugin:3.0-beta-4-SNAPSHOT:deploy
(default-cli) @ module1 ---
[INFO]
file://x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target/it/top-parent-no-site/deploy/
- Session: Opened
[INFO]
file://x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target/it/top-parent-no-site/deploy/
- Session: Disconnecting
[INFO]
file://x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target/it/top-parent-no-site/deploy/
- Session: Disconnected
[INFO] [INFO]
[INFO] [INFO] --- maven-site-plugin:3.0-beta-4-SNAPSHOT:stage
(default-cli) @ module1 ---
[INFO] [INFO] Using this directory for staging:
X:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\top-parent-no-site\target/staging
[INFO]
file://X:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\top-parent-no-site\target\staging
- Session: Opened
[INFO]
file://X:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\top-parent-no-site\target\staging
- Session: Disconnecting
[INFO]
file://X:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\top-parent-no-site\target\staging
- Session: Disconnected
[INFO] [INFO]
[INFO] [INFO] --- maven-site-plugin:3.0-beta-4-SNAPSHOT:stage-deploy
(default-cli) @ module1 ---
[INFO] [INFO] Using this URL for stage deploy:
file://x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target/it/top-parent-no-site/deploy//staging
[INFO]
file://x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target/it/top-parent-no-site/deploy//staging
- Session: Opened
[INFO]
file://x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target/it/top-parent-no-site/deploy//staging
- Session: Disconnecting
[INFO]
file://x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target/it/top-parent-no-site/deploy//staging
- Session: Disconnected
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] Reactor Summary:
[INFO] [INFO]
[INFO] [INFO] main ..............................................
SUCCESS [3.828s]
[INFO] [INFO] module 1 ..........................................
SUCCESS [0.530s]
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] BUILD SUCCESS
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] [INFO] Total time: 4.816s
[INFO] [INFO] Finished at: Fri Mar 11 10:25:18 PST 2011
[INFO] [INFO] Final Memory: 10M/22M
[INFO] [INFO]
------------------------------------------------------------------------
[INFO] Running post-build script:
x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\top-parent-no-site\verify.bsh
[INFO] Finished post-build script:
x:\slave\workspace\maven-site-plugin-3.x\jdk\java-5x\label\windows\trunk\target\it\top-parent-no-site\verify.bsh
[INFO] ..SUCCESS (8.5 s)
[INFO] -------------------------------------------------
[INFO] Build Summary:
[INFO] Passed: 24, Failed: 1, Errors: 0, Skipped: 0
[INFO] -------------------------------------------------
[ERROR] The following builds failed:
[ERROR] * site-inheritance\pom.xml
[INFO] -------------------------------------------------
[INFO]
------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO]
------------------------------------------------------------------------
[INFO] Total time: 17:37.770s
[INFO] Finished at: Fri Mar 11 10:25:18 PST 2011
[INFO] Final Memory: 14M/35M
[INFO]
------------------------------------------------------------------------
[ERROR] Failed to execute goal
org.apache.maven.plugins:maven-invoker-plugin:1.5:run
(integration-test) on project maven-site-plugin: 1 build failed. ->
[Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to
execute goal org.apache.maven.plugins:maven-invoker-plugin:1.5:run
(integration-test) on project maven-site-plugin: 1 build failed.
at
org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:213)
at
org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at
org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at
org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
at
org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
at
org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
at
org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:319)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:156)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:537)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:196)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:141)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:592)
at
org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
at
org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
at
org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
at
org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
Caused by: org.apache.maven.plugin.MojoFailureException: 1 build failed.
at
org.apache.maven.plugin.invoker.InvokerSession.handleFailures(InvokerSession.java:263)
at
org.apache.maven.plugin.invoker.InvokerMojo.processResults(InvokerMojo.java:58)
at
org.apache.maven.plugin.invoker.AbstractInvokerMojo.execute(AbstractInvokerMojo.java:620)
at
org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)
at
org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
... 19 more
[ERROR]
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions,
please read the following articles:
[ERROR] [Help 1]
http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]