Sergey Bondarenko | 6 Sep 18:55

[groovy-user] possible bug/regression in GroovyConsole

It seems like there is a minor regression in GroovyConsole.
In previous versions it was possible to run several pieces of code,
and binging variables were preserved between invocations.
Now binding seams to be empty for each next invocation. I tried using
snapshot 20080906095551.

Steps to reproduce:
open groovyConsole, and paste this script:
x = 1
println x

Select and execute first line, then select and execute second line.
You will get groovy.lang.MissingPropertyException.
In all previous GroovyConsole versions you would get "1".

Is it a bug or intended behaviour?

Best regards,
Sergey Bondarenko.

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email

Guillaume Laforge | 6 Sep 19:12
Gravatar

Re: [groovy-user] possible bug/regression in GroovyConsole

Which version are you using?
For instance, with 1.6-beta-1, no exception's thrown.

On Sat, Sep 6, 2008 at 6:56 PM, Sergey Bondarenko <enterit@...> wrote:
> It seems like there is a minor regression in GroovyConsole.
> In previous versions it was possible to run several pieces of code,
> and binging variables were preserved between invocations.
> Now binding seams to be empty for each next invocation. I tried using
> snapshot 20080906095551.
>
> Steps to reproduce:
> open groovyConsole, and paste this script:
> x = 1
> println x
>
> Select and execute first line, then select and execute second line.
> You will get groovy.lang.MissingPropertyException.
> In all previous GroovyConsole versions you would get "1".
>
> Is it a bug or intended behaviour?
>
> Best regards,
> Sergey Bondarenko.
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>    http://xircles.codehaus.org/manage_email
>
>
(Continue reading)

Sergey Bondarenko | 6 Sep 19:21

Re: [groovy-user] possible bug/regression in GroovyConsole

I am using 1.6-beta-2-SNAPSHOT (20080906095551).

Sergey.

2008/9/6 Guillaume Laforge <glaforge@...>:
> Which version are you using?
> For instance, with 1.6-beta-1, no exception's thrown.
>
> On Sat, Sep 6, 2008 at 6:56 PM, Sergey Bondarenko <enterit@...> wrote:
>> It seems like there is a minor regression in GroovyConsole.
>> In previous versions it was possible to run several pieces of code,
>> and binging variables were preserved between invocations.
>> Now binding seams to be empty for each next invocation. I tried using
>> snapshot 20080906095551.
>>
>> Steps to reproduce:
>> open groovyConsole, and paste this script:
>> x = 1
>> println x
>>
>> Select and execute first line, then select and execute second line.
>> You will get groovy.lang.MissingPropertyException.
>> In all previous GroovyConsole versions you would get "1".
>>
>> Is it a bug or intended behaviour?
>>
>> Best regards,
>> Sergey Bondarenko.
>>
>> ---------------------------------------------------------------------
(Continue reading)

Guillaume Laforge | 6 Sep 20:51
Gravatar

Re: [groovy-user] possible bug/regression in GroovyConsole

It was indeed fine in 1.6-beta-1, but fails with Trunk.
Could you please open a JIRA ticket?

I got the following stacktrace in the console:

6 sept. 2008 20:49:54 org.codehaus.groovy.runtime.StackTraceUtils sanitize
ATTENTION: Sanitizing stacktrace:
groovy.lang.MissingPropertyException: No such property: x for class: Script1
	at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.unwrap(ScriptBytecodeAdapter.java:49)
	at Script1.run(Script1:1)
	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:585)
	at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:86)
	at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:234)
	at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:994)
	at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:845)
	at org.codehaus.groovy.runtime.InvokerHelper.invokePogoMethod(InvokerHelper.java:772)
	at org.codehaus.groovy.runtime.InvokerHelper.invokeMethod(InvokerHelper.java:753)
	at org.codehaus.groovy.runtime.InvokerHelper.runScript(InvokerHelper.java:381)
	at org.codehaus.groovy.runtime.InvokerHelper$runScript.call(Unknown Source)
	at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:41)
	at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
	at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:128)
	at Script1.main(Script1)
	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:585)
(Continue reading)

Sergey Bondarenko | 6 Sep 21:33

Re: [groovy-user] possible bug/regression in GroovyConsole

http://jira.codehaus.org/browse/GROOVY-3031

Sergey.

2008/9/6 Guillaume Laforge <glaforge@...>:
> It was indeed fine in 1.6-beta-1, but fails with Trunk.
> Could you please open a JIRA ticket?
>
> I got the following stacktrace in the console:
>
> 6 sept. 2008 20:49:54 org.codehaus.groovy.runtime.StackTraceUtils sanitize
> ATTENTION: Sanitizing stacktrace:
> groovy.lang.MissingPropertyException: No such property: x for class: Script1
>        at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.unwrap(ScriptBytecodeAdapter.java:49)
>        at Script1.run(Script1:1)
>        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:585)
>        at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:86)
>        at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:234)
>        at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:994)
>        at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:845)
>        at org.codehaus.groovy.runtime.InvokerHelper.invokePogoMethod(InvokerHelper.java:772)
>        at org.codehaus.groovy.runtime.InvokerHelper.invokeMethod(InvokerHelper.java:753)
>        at org.codehaus.groovy.runtime.InvokerHelper.runScript(InvokerHelper.java:381)
>        at org.codehaus.groovy.runtime.InvokerHelper$runScript.call(Unknown Source)
>        at org.codehaus.groovy.runtime.callsite.CallSiteArray.defaultCall(CallSiteArray.java:41)
>        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:116)
>        at org.codehaus.groovy.runtime.callsite.AbstractCallSite.call(AbstractCallSite.java:128)
(Continue reading)


Gmane