You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@maven.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2016/05/28 21:03:13 UTC

[jira] [Commented] (MRELEASE-834) release:prepare fails when a system property starting with dependency is given

    [ https://issues.apache.org/jira/browse/MRELEASE-834?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15305621#comment-15305621 ] 

ASF GitHub Bot commented on MRELEASE-834:
-----------------------------------------

Github user pono closed the pull request at:

    https://github.com/apache/maven-release/pull/3


> release:prepare fails when a system property starting with dependency is given
> ------------------------------------------------------------------------------
>
>                 Key: MRELEASE-834
>                 URL: https://issues.apache.org/jira/browse/MRELEASE-834
>             Project: Maven Release Plugin
>          Issue Type: Bug
>          Components: prepare
>    Affects Versions: 2.4.1
>            Reporter: Mirko Friedenhagen
>            Assignee: Robert Scholte
>              Labels: github-pullrequest
>             Fix For: 2.5.2
>
>         Attachments: MRELEASE-834-formatted-and-with-assertion.patch, MRELEASE-834.patch
>
>
> When invoking {{mvn release:prepare}} with a system property starting with dependency is set, the invocation will fail:
> Sample:
> {{mvn -e release:prepare -DdryRun=true -Ddependency.locations.enabled=false}}
> {code}
> [ERROR] Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.4.1:prepare (default-cli) on project tljunit-parent: Execution default-cli of goal org.apache.maven.plugins:maven-release-plugin:2.4.1:prepare failed: String index out of range: -12 -> [Help 1]
> org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-release-plugin:2.4.1:prepare (default-cli) on project tljunit-parent: Execution default-cli of goal org.apache.maven.plugins:maven-release-plugin:2.4.1:prepare failed: String index out of range: -12
> 	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:225)
> 	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:320)
> 	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:57)
> 	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
> 	at java.lang.reflect.Method.invoke(Method.java:601)
> 	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.PluginExecutionException: Execution default-cli of goal org.apache.maven.plugins:maven-release-plugin:2.4.1:prepare failed: String index out of range: -12
> 	at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:110)
> 	at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:209)
> 	... 19 more
> Caused by: java.lang.StringIndexOutOfBoundsException: String index out of range: -12
> 	at java.lang.String.substring(String.java:1911)
> 	at org.apache.maven.shared.release.config.ReleaseUtils.loadResolvedDependencies(ReleaseUtils.java:256)
> 	at org.apache.maven.shared.release.config.ReleaseUtils.copyPropertiesToReleaseDescriptor(ReleaseUtils.java:172)
> 	at org.apache.maven.plugins.release.PrepareReleaseMojo.prepareRelease(PrepareReleaseMojo.java:271)
> 	at org.apache.maven.plugins.release.PrepareReleaseMojo.execute(PrepareReleaseMojo.java:232)
> 	at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:101)
> 	... 20 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/PluginExecutionException
> {code}
> We did set {{dependency.locations.enabled=false}} in {{MAVEN_OPTS}} to speed up {{site}} generation. As can be seen it is sufficient to set this as system property during invocation.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)