maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Gene Smith (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (MNG-6368) Maven 3.5.2 breaks the Maven Invoker Plugin on Windows
Date Wed, 28 Feb 2018 23:05:00 GMT

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

Gene Smith commented on MNG-6368:
---------------------------------

It still breaks with maven "cmd" (Windows Command Processor):
 * works with
 **  maven 3.0.5 and Java  1.8.0_151
 **  maven 3.5.0 and Java  1.8.0_151
 * breaks with
 ** maven 3.5.2 and Java  1.8.0_151

But with that I was able to identify the cause, and a work around is easy.

If I install with this:
 * wget [http://mirror.olnevhost.net/pub/apache/maven/maven-3/3.5.2/binaries/apache-maven-3.5.2-bin.zip]
unzip apache-maven-3.5.2-bin.zip

I get a mix of executable and non executable files in the bin directory:
{quote}{{$ ll apache-maven-3.5.2/bin/}}
{{total 29}}
{{-rw-r--r-- 1 gsmith Domain Users  228 Oct 18 08:55 m2.conf}}
{{-rwxr-xr-x 1 gsmith Domain Users 5969 Oct 18 08:55 mvn}}
{{-rw-r--r-- 1 gsmith Domain Users 6354 Oct 18 08:55 mvn.cmd}}
{{-rwxr-xr-x 1 gsmith Domain Users 1485 Oct 18 08:55 mvnDebug}}
{{-rw-r--r-- 1 gsmith Domain Users 1668 Oct 18 08:55 mvnDebug.cmd}}
{{-rwxr-xr-x 1 gsmith Domain Users 1532 Oct 18 08:55 mvnyjp}}{{ and place a work around.}}
{{My work around suggests it may break with 3.5.0 and a fresh}}
{{install, but other issues force the work around anyway.}}
{quote}
If I make everything in that directory executable (with chmod or the long standing trick of
using jar to extract instead of unzip) then it works.

So if I want to use 3.5.2, I can put enforcement on "mvn.cmd" being executable, and get a
clear fast failure instead of a no message late failure.

> Maven 3.5.2 breaks the Maven Invoker Plugin on Windows
> ------------------------------------------------------
>
>                 Key: MNG-6368
>                 URL: https://issues.apache.org/jira/browse/MNG-6368
>             Project: Maven
>          Issue Type: Bug
>    Affects Versions: 3.5.2
>         Environment: Windows 7
> run from cygwin with January 2017 updates
>            Reporter: Gene Smith
>            Priority: Major
>         Attachments: test-maven-invoker-plugin.zip
>
>
> With Maven 3.5.2 on Windows 7,. the Maven Invoker Plugin breaks:
>  * reporting 
> _The Maven invocation failed. Error while executing process._
>  * leaving empty log files, and streaming nothing from the invoked process
> I have multiple uses in a large project, which have has been working for us through many
version of Maven.  They all break, *on Windows with:*
>  * a simple clean attempt to upgrade to Maven 3.5.2.
> (without changing any plugin versions)
>  * a complex upgrade attempt, advancing forward as many plugin versions as can be pushed.
> The complex upgrade attempt works with Maven 3.5.0.
> And on testing to isolate it, Maven 3.5.2 + Maven Invoker Plugin 2+ breaks even in simplest
form invoking:
>  * an empty jar project with no inheritance
>  * an empty pom project with no inheritance
>  * an empty jar project with direct inheritance from the invoker
>  * an empty pom project with direct inheritance from the invoker
> The attached zip very simple test project, which
>  * works with:
>  ** Maven 3.0.5, 3.1.1, 3.2.1, 3.3.3, 3.3.9
>  *** maven-invoker-plugin 1.6, 1.7, 1.8, 1.9, 2.0.0, 3.0.0, 3.0.1
>  ** Maven 3.5.0
>  *** maven-invoker-plugin 2.0.0, 3.0.0, 3.0.1
>  * *breaks with:*
>  ** Maven 3.5.2
>  *** maven-invoker-plugin 1.6, 1.7, 1.8, 1.9, 2.0.0, 3.0.0, 3.0.1
> I looked through sources and was able to test with this built locally (but my task is
timeboxed and I have not been able to get Maven built from sources in the time I have):
>  * [http://svn.apache.org/repos/asf/maven/plugins/tags/maven-invoker-plugin-3.0.1]
> and traced it as far as the call to:
>  * org.apache.maven.shared.invoker.Invoker
>                 try
>                 {
>                     result = invoker.execute( request );
>                 }
>                 catch ( final MavenInvocationException e )
>                 {
>                     getLog().debug( "Error invoking Maven: " + e.getMessage(),
e );
>                     throw new RunFailureException( "Maven invocation
failed. " + e.getMessage(),
>                                                   
BuildJob.Result.FAILURE_BUILD );
>                 }
> but it invoker hides all trace, and I do not have time (I am time boxed this week) to
get Maven built from sources to trace it into the Invoker.
>  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Mime
View raw message