Re: rm servlet-api.jar?

2017-01-09 Thread Romain Manni-Bucau
Le 10 janv. 2017 01:44, "Jochen Theodorou"  a écrit :

On 06.01.2017 10:54, Romain Manni-Bucau wrote:

> Hi guys,
>
> Using groovy bundle (export PATH=$GROOVY_HOME/bin:$PATH) I often hit a
> blocker: servlet-api is there. It means that if you use tomcat you will
> use the wrong servlet api and get some troubles (missing message bundle,
> wrong version etc...).
>
> It can be overriden with setting up a custom groovy-starter.conf and
> setting the system property groovy.starter.conf.override but this is not
> very convenient.
>
> How to get rid of most of convenient dependencies from groovy/lib?
>
> Idea can be to use grapes to resolve them later when needed from groovy
> classloader(s) which makes it quite dynamic but a simpler solution can
> also be to have some profile and add them in the cli to control the
> classpath like:
>
> ./bin/groovy --light myscript.groovy
> ./bin/groovy --all myscript.groovy
>

wouldn´t it be better to be able to set the configuration in a more
convenient way?


Hmm, proposed this way cause it was tthe most convenient for me (light and
fluent on the CLI)




> etc
>
> With this last option we need to define which profiles we want and also
> if we want to have a regex support:
>
> ./bin/groovy --root-loader={groovy.home}/lib/*.jar myscript.groovy
>
>
> any thoughts on this?
>

I think * and ** are supported in the starter configurations. Does it have
to be on the command line?


Yes it does but you need to share a starter.conf + a command line as a
framework. Not very user friendly.

Thinking to it wonder if grapes shouldnt be able to handle it. Until you
execute the script you didnt load these polluting classes/jar so you should
be able to remove them from the classloader or at least exclude the classes
just throwing ClassNotFoundException from the RootLoader.






bye Jochen


Re: [VOTE] Release Groovy 2.4.8

2017-01-09 Thread John Wagenleitner
With the downloaded source I was using gradle 2.14.  I also fetched the
GROOVY_2_4_8 tag and ran gradlew from there which is 2.3.  I get the error
with both.  Not sure if I need to set up a property to point to gpg keys,
but haven't had to do that in the past.

On Mon, Jan 9, 2017 at 7:42 PM, Paul King  wrote:

> Can you check the version of gradle that is running? The artifacts are
> built using install and install works fine for me from the src zip.
>
> On Tue, Jan 10, 2017 at 12:33 PM, John Wagenleitner
>  wrote:
> > When I run `gradlew install` from source (both from the downloaded zip
> and
> > from the GROOVY_2_4_8 tag) I get the error below.  Looks like prior to
> > commit 9fa4b015e4a80ef03 [1] this was a warning but now it fails the
> build
> > and wont install the artifacts in the local maven repo.
> >
> > [1]
> > https://github.com/apache/groovy/commit/9fa4b015e4a80ef036ef32aa48158f
> 8360663000
> >
> > ---
> > :groovy-groovydoc:javadoc
> > :groovy-ant:javadoc
> > /ASF/groovy/subprojects/groovy-ant/src/main/java/org/
> codehaus/groovy/ant/Groovyc.java:42:
> > error: cannot find symbol
> > import org.apache.commons.cli.GroovyInternalPosixParser;
> >  ^
> >   symbol:   class GroovyInternalPosixParser
> >   location: package org.apache.commons.cli
> > 1 warning
> > :groovy-ant:javadocJar
> > :groovy-ant:install FAILED
> >
> > FAILURE: Build failed with an exception.
> >
> > * What went wrong:
> > Execution failed for task ':groovy-ant:install'.
> >> Could not publish configuration 'archives'
> >> Cannot publish artifact 'groovy-ant.jar.asc
> > (org.codehaus.groovy:groovy-ant:2.4.8)'
> > (/ASF/groovy/subprojects/groovy-ant/target/libs/groovy-ant-2.4.8.jar.asc)
> as
> > it does not exist.
> >
> > * Try:
> > Run with --stacktrace option to get the stack trace. Run with --info or
> > --debug option to get more log output.
> >
> > BUILD FAILED
> > ---
> >
> >
> > On Sun, Jan 8, 2017 at 10:33 PM, Paul King  wrote:
> >>
> >> Dear community,
> >>
> >> I am happy to start the VOTE thread for a Groovy 2.4.8 release!
> >>
> >> This release includes 84 bug fixes/improvements as outlined in the
> >> changelog:
> >>
> >> https://issues.apache.org/jira/secure/ReleaseNote.jspa?
> projectId=12318123=12335950
> >>
> >> Tag:
> >> https://git1-us-west.apache.org/repos/asf?p=groovy.git;a=
> tag;h=refs/tags/GROOVY_2_4_8
> >> Tag commit id: a1dc0fabb39feb2410d00c7919965557c7841ed6
> >>
> >> The artifacts to be voted on are located as follows (r17713).
> >> Source release:
> >> https://dist.apache.org/repos/dist/dev/groovy/2.4.8/sources
> >> Convenience binaries:
> >> https://dist.apache.org/repos/dist/dev/groovy/2.4.8/distribution
> >>
> >> Release artifacts are signed with a key from the following file:
> >> https://dist.apache.org/repos/dist/dev/groovy/KEYS
> >>
> >> Please vote on releasing this package as Apache Groovy 2.4.8.
> >>
> >> The vote is open for the next 72 hours and passes if a majority of at
> >> least three +1 PMC votes are cast.
> >>
> >> [ ] +1 Release Apache Groovy 2.4.8
> >> [ ]  0 I don't have a strong opinion about this, but I assume it's ok
> >> [ ] -1 Do not release Apache Groovy 2.4.8 because...
> >>
> >> Here is my vote:
> >>
> >> +1 (binding)
> >
> >
>


Re: [VOTE] Release Groovy 2.4.8

2017-01-09 Thread Paul King
Can you check the version of gradle that is running? The artifacts are
built using install and install works fine for me from the src zip.

On Tue, Jan 10, 2017 at 12:33 PM, John Wagenleitner
 wrote:
> When I run `gradlew install` from source (both from the downloaded zip and
> from the GROOVY_2_4_8 tag) I get the error below.  Looks like prior to
> commit 9fa4b015e4a80ef03 [1] this was a warning but now it fails the build
> and wont install the artifacts in the local maven repo.
>
> [1]
> https://github.com/apache/groovy/commit/9fa4b015e4a80ef036ef32aa48158f8360663000
>
> ---
> :groovy-groovydoc:javadoc
> :groovy-ant:javadoc
> /ASF/groovy/subprojects/groovy-ant/src/main/java/org/codehaus/groovy/ant/Groovyc.java:42:
> error: cannot find symbol
> import org.apache.commons.cli.GroovyInternalPosixParser;
>  ^
>   symbol:   class GroovyInternalPosixParser
>   location: package org.apache.commons.cli
> 1 warning
> :groovy-ant:javadocJar
> :groovy-ant:install FAILED
>
> FAILURE: Build failed with an exception.
>
> * What went wrong:
> Execution failed for task ':groovy-ant:install'.
>> Could not publish configuration 'archives'
>> Cannot publish artifact 'groovy-ant.jar.asc
> (org.codehaus.groovy:groovy-ant:2.4.8)'
> (/ASF/groovy/subprojects/groovy-ant/target/libs/groovy-ant-2.4.8.jar.asc) as
> it does not exist.
>
> * Try:
> Run with --stacktrace option to get the stack trace. Run with --info or
> --debug option to get more log output.
>
> BUILD FAILED
> ---
>
>
> On Sun, Jan 8, 2017 at 10:33 PM, Paul King  wrote:
>>
>> Dear community,
>>
>> I am happy to start the VOTE thread for a Groovy 2.4.8 release!
>>
>> This release includes 84 bug fixes/improvements as outlined in the
>> changelog:
>>
>> https://issues.apache.org/jira/secure/ReleaseNote.jspa?projectId=12318123=12335950
>>
>> Tag:
>> https://git1-us-west.apache.org/repos/asf?p=groovy.git;a=tag;h=refs/tags/GROOVY_2_4_8
>> Tag commit id: a1dc0fabb39feb2410d00c7919965557c7841ed6
>>
>> The artifacts to be voted on are located as follows (r17713).
>> Source release:
>> https://dist.apache.org/repos/dist/dev/groovy/2.4.8/sources
>> Convenience binaries:
>> https://dist.apache.org/repos/dist/dev/groovy/2.4.8/distribution
>>
>> Release artifacts are signed with a key from the following file:
>> https://dist.apache.org/repos/dist/dev/groovy/KEYS
>>
>> Please vote on releasing this package as Apache Groovy 2.4.8.
>>
>> The vote is open for the next 72 hours and passes if a majority of at
>> least three +1 PMC votes are cast.
>>
>> [ ] +1 Release Apache Groovy 2.4.8
>> [ ]  0 I don't have a strong opinion about this, but I assume it's ok
>> [ ] -1 Do not release Apache Groovy 2.4.8 because...
>>
>> Here is my vote:
>>
>> +1 (binding)
>
>


Re: [VOTE] Release Groovy 2.4.8

2017-01-09 Thread John Wagenleitner
When I run `gradlew install` from source (both from the downloaded zip and
from the GROOVY_2_4_8 tag) I get the error below.  Looks like prior to
commit 9fa4b015e4a80ef03 [1] this was a warning but now it fails the build
and wont install the artifacts in the local maven repo.

[1]
https://github.com/apache/groovy/commit/9fa4b015e4a80ef036ef32aa48158f8360663000

---
:groovy-groovydoc:javadoc
:groovy-ant:javadoc
/ASF/groovy/subprojects/groovy-ant/src/main/java/org/codehaus/groovy/ant/Groovyc.java:42:
error: cannot find symbol
import org.apache.commons.cli.GroovyInternalPosixParser;
 ^
  symbol:   class GroovyInternalPosixParser
  location: package org.apache.commons.cli
1 warning
:groovy-ant:javadocJar
:groovy-ant:install FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':groovy-ant:install'.
> Could not publish configuration 'archives'
   > Cannot publish artifact 'groovy-ant.jar.asc
(org.codehaus.groovy:groovy-ant:2.4.8)'
(/ASF/groovy/subprojects/groovy-ant/target/libs/groovy-ant-2.4.8.jar.asc)
as it does not exist.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or
--debug option to get more log output.

BUILD FAILED
---


On Sun, Jan 8, 2017 at 10:33 PM, Paul King  wrote:

> Dear community,
>
> I am happy to start the VOTE thread for a Groovy 2.4.8 release!
>
> This release includes 84 bug fixes/improvements as outlined in the
> changelog:
> https://issues.apache.org/jira/secure/ReleaseNote.jspa?
> projectId=12318123=12335950
>
> Tag: https://git1-us-west.apache.org/repos/asf?p=groovy.git;a=
> tag;h=refs/tags/GROOVY_2_4_8
> Tag commit id: a1dc0fabb39feb2410d00c7919965557c7841ed6
>
> The artifacts to be voted on are located as follows (r17713).
> Source release: https://dist.apache.org/repos/
> dist/dev/groovy/2.4.8/sources
> Convenience binaries:
> https://dist.apache.org/repos/dist/dev/groovy/2.4.8/distribution
>
> Release artifacts are signed with a key from the following file:
> https://dist.apache.org/repos/dist/dev/groovy/KEYS
>
> Please vote on releasing this package as Apache Groovy 2.4.8.
>
> The vote is open for the next 72 hours and passes if a majority of at
> least three +1 PMC votes are cast.
>
> [ ] +1 Release Apache Groovy 2.4.8
> [ ]  0 I don't have a strong opinion about this, but I assume it's ok
> [ ] -1 Do not release Apache Groovy 2.4.8 because...
>
> Here is my vote:
>
> +1 (binding)
>


Re: MavenGrapeEngine?

2017-01-09 Thread Jochen Theodorou

well... contributions are welcome ;)

On 06.01.2017 15:36, Romain Manni-Bucau wrote:



2017-01-06 15:33 GMT+01:00 Jochen Theodorou >:

On 06.01.2017 15:00, Romain Manni-Bucau wrote:
[...]

Means SNAPSHOT patterns needs to be identified (likely a flag in the
@Grab(snapshot=true)?) and groovy should clean up the artifacts
before
resolving to avoid to let ivy mess up its repo.


which means it is more than just a change in the configuration file.


Both options are valid but I think you had a good point and it can be
API intrusive

For maven based artifact
it also means you run copies instead of maven repository ones
which is
leading to unexpected runtime sometimes.


can you explain a bit more? you mean the local ivy repo with copy?


Yes, if you don't remove the snapshot copy from ~/.groovy/grapes/ then
you use the last resolved one which is likely outdated with maven repo.

 - what kind of SPI groovy would use (ATM GrapeEngine
lookup is quite
 hardcoded): do we want a config in groovy installation
+ system
 property?

 would someone want to define the engine as part of the
annotation or
 should this be automatic in the background? We could also
think of
 using the Java service provider interface logic - of course
then we
 have to think about what to do if multiple engines are there

sounds good in @Grab with probably a default globally settable
in the
script.


yes I think we can do that

 - if we want another engine: how do we manage
dependencies? do we
 isolate them from groovy libs?


 they should be optional for the delivery and in the
light of
 that I think depending on spring-boot-cli is an option

Alternative is to implement it in groovy without maven in a light
fashion, with

https://github.com/apache/tomee/blob/master/container/openejb-loader/src/main/java/org/apache/openejb/loader/provisining/MavenResolver.java


and

https://github.com/apache/tomee/blob/master/container/openejb-loader/src/main/java/org/apache/openejb/loader/provisining/HttpResolver.java


you can resolve most of maven artifacts. This code needs to be
reworked
on its config side cause it is specific to tomee but my point is
in <
400 LOC you can get a maven resolver you own and therefore
supporting
snapshots is very doable there.


I would prefer depending on something existing, but 400 LOC is not
much and if that goes without further dependencies... well then we
should consider doing that


Agree, I only know aether (or its forks) which are far from 400 LOC but
alternatives welcomed as well if they exist

bye Jochen






Re: [VOTE] Release Groovy 2.4.8

2017-01-09 Thread Jochen Theodorou

+1

On 09.01.2017 07:33, Paul King wrote:

Dear community,

I am happy to start the VOTE thread for a Groovy 2.4.8 release!

This release includes 84 bug fixes/improvements as outlined in the changelog:
https://issues.apache.org/jira/secure/ReleaseNote.jspa?projectId=12318123=12335950

Tag: 
https://git1-us-west.apache.org/repos/asf?p=groovy.git;a=tag;h=refs/tags/GROOVY_2_4_8
Tag commit id: a1dc0fabb39feb2410d00c7919965557c7841ed6

The artifacts to be voted on are located as follows (r17713).
Source release: https://dist.apache.org/repos/dist/dev/groovy/2.4.8/sources
Convenience binaries:
https://dist.apache.org/repos/dist/dev/groovy/2.4.8/distribution

Release artifacts are signed with a key from the following file:
https://dist.apache.org/repos/dist/dev/groovy/KEYS

Please vote on releasing this package as Apache Groovy 2.4.8.

The vote is open for the next 72 hours and passes if a majority of at
least three +1 PMC votes are cast.

[ ] +1 Release Apache Groovy 2.4.8
[ ]  0 I don't have a strong opinion about this, but I assume it's ok
[ ] -1 Do not release Apache Groovy 2.4.8 because...

Here is my vote:

+1 (binding)





Re: [VOTE] Release Groovy 2.4.8

2017-01-09 Thread Jim Jagielski
+1 (binding)!
> On Jan 9, 2017, at 1:33 AM, Paul King  wrote:
> 
> Dear community,
> 
> I am happy to start the VOTE thread for a Groovy 2.4.8 release!
> 
> This release includes 84 bug fixes/improvements as outlined in the changelog:
> https://issues.apache.org/jira/secure/ReleaseNote.jspa?projectId=12318123=12335950
> 
> Tag: 
> https://git1-us-west.apache.org/repos/asf?p=groovy.git;a=tag;h=refs/tags/GROOVY_2_4_8
> Tag commit id: a1dc0fabb39feb2410d00c7919965557c7841ed6
> 
> The artifacts to be voted on are located as follows (r17713).
> Source release: https://dist.apache.org/repos/dist/dev/groovy/2.4.8/sources
> Convenience binaries:
> https://dist.apache.org/repos/dist/dev/groovy/2.4.8/distribution
> 
> Release artifacts are signed with a key from the following file:
> https://dist.apache.org/repos/dist/dev/groovy/KEYS
> 
> Please vote on releasing this package as Apache Groovy 2.4.8.
> 
> The vote is open for the next 72 hours and passes if a majority of at
> least three +1 PMC votes are cast.
> 
> [ ] +1 Release Apache Groovy 2.4.8
> [ ]  0 I don't have a strong opinion about this, but I assume it's ok
> [ ] -1 Do not release Apache Groovy 2.4.8 because...
> 
> Here is my vote:
> 
> +1 (binding)



Re: Old Groovy Stuff on Maven2

2017-01-09 Thread Jim Northrop
Ok, so basically, we let sleeping dogs lie. ✅☺️

Sent from my iPad

> On 9 Jan 2017, at 10:59, Cédric Champeau  wrote:
> 
> I see no good reason to remove any published artifact from a public 
> repository. This would cause more troubles than benefits (I look at you, 
> npm!).
> 
> 2017-01-09 10:58 GMT+01:00 jn0rthr :
>> Have found this old groovy download package on maven2:
>> 
>> http://repository.jboss.org/maven2/groovy/groovy-all/1.1-BETA-1/
>> 
>> and wonder if we have any responsibility to remove obsolete items like this
>> ?
>> 
>> 
>> 
>> --
>> View this message in context: 
>> http://groovy.329449.n5.nabble.com/Old-Groovy-Stuff-on-Maven2-tp5737613.html
>> Sent from the Groovy Dev mailing list archive at Nabble.com.
> 


Re: Old Groovy Stuff on Maven2

2017-01-09 Thread Cédric Champeau
I see no good reason to remove any published artifact from a public
repository. This would cause more troubles than benefits (I look at you,
npm!).

2017-01-09 10:58 GMT+01:00 jn0rthr :

> Have found this old groovy download package on maven2:
>
> http://repository.jboss.org/maven2/groovy/groovy-all/1.1-BETA-1/
>
> and wonder if we have any responsibility to remove obsolete items like this
> ?
>
>
>
> --
> View this message in context: http://groovy.329449.n5.
> nabble.com/Old-Groovy-Stuff-on-Maven2-tp5737613.html
> Sent from the Groovy Dev mailing list archive at Nabble.com.
>


Re: [VOTE] Release Groovy 2.4.8

2017-01-09 Thread Cédric Champeau
+1 (binding)

Signatures ok.
SHA256 sum ok.
Buildable from sources.

Good work, Paul!


2017-01-09 7:33 GMT+01:00 Paul King :

> Dear community,
>
> I am happy to start the VOTE thread for a Groovy 2.4.8 release!
>
> This release includes 84 bug fixes/improvements as outlined in the
> changelog:
> https://issues.apache.org/jira/secure/ReleaseNote.jspa?
> projectId=12318123=12335950
>
> Tag: https://git1-us-west.apache.org/repos/asf?p=groovy.git;a=
> tag;h=refs/tags/GROOVY_2_4_8
> Tag commit id: a1dc0fabb39feb2410d00c7919965557c7841ed6
>
> The artifacts to be voted on are located as follows (r17713).
> Source release: https://dist.apache.org/repos/
> dist/dev/groovy/2.4.8/sources
> Convenience binaries:
> https://dist.apache.org/repos/dist/dev/groovy/2.4.8/distribution
>
> Release artifacts are signed with a key from the following file:
> https://dist.apache.org/repos/dist/dev/groovy/KEYS
>
> Please vote on releasing this package as Apache Groovy 2.4.8.
>
> The vote is open for the next 72 hours and passes if a majority of at
> least three +1 PMC votes are cast.
>
> [ ] +1 Release Apache Groovy 2.4.8
> [ ]  0 I don't have a strong opinion about this, but I assume it's ok
> [ ] -1 Do not release Apache Groovy 2.4.8 because...
>
> Here is my vote:
>
> +1 (binding)
>