[groovy-user] Fail to launch groovyConsole under Ubuntu 8.04

7 views
Skip to first unread message

Daniel.Sun

unread,
May 2, 2008, 4:22:08 AM5/2/08
to us...@groovy.codehaus.org

Hi all,

When I tried to launch groovy console under Ubuntu 8.04, I got the following
exceptions.

The relevent environment variables:
JAVA_HOME=/usr/java/jdk1.6.0
GROOVY_HOME=/usr/groovy-1.5.6
PATH=/usr/java/jdk1.6.0/bin:/usr/groovy-1.5.6/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
CLASSPATH=.:/usr/java/jdk1.6.0/lib

Could you tell me what's wrong with my settings?

Any help is much appreciated!

Thanks in advance!
Daniel.Sun

daniel@daniel-laptop:~$ groovyConsole
Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
at
com.sun.java.swing.plaf.gtk.GTKLookAndFeel.initSystemColorDefaults(GTKLookAndFeel.java:1267)
at
com.sun.java.swing.plaf.gtk.GTKLookAndFeel.loadStyles(GTKLookAndFeel.java:1509)
at
com.sun.java.swing.plaf.gtk.GTKLookAndFeel.access$000(GTKLookAndFeel.java:37)
at
com.sun.java.swing.plaf.gtk.GTKLookAndFeel$WeakPCL$1.run(GTKLookAndFeel.java:1449)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
at
java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:273)
at
java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:183)
at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:173)
at
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:168)
at
java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:160)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:121)
java.lang.reflect.InvocationTargetException
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:597)
at
org.codehaus.groovy.tools.GroovyStarter.rootLoader(GroovyStarter.java:101)
at
org.codehaus.groovy.tools.GroovyStarter.main(GroovyStarter.java:130)
Caused by: java.lang.NullPointerException
at
javax.swing.plaf.synth.SynthLookAndFeel$AATextListener.propertyChange(SynthLookAndFeel.java:793)
at
java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:339)
at
java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:347)
at
java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:276)
at java.awt.Toolkit.setDesktopProperty(Toolkit.java:1784)
at
sun.awt.SunToolkit.fireDesktopFontPropertyChanges(SunToolkit.java:1714)
at
sun.awt.SunToolkit.setAAFontSettingsCondition(SunToolkit.java:1759)
at
sun.swing.SwingUtilities2$AATextInfo.getAATextInfo(SwingUtilities2.java:119)
at
com.sun.java.swing.plaf.gtk.GTKLookAndFeel.initComponentDefaults(GTKLookAndFeel.java:1258)
at
com.sun.java.swing.plaf.gtk.GTKLookAndFeel.getDefaults(GTKLookAndFeel.java:294)
at javax.swing.UIManager.setLookAndFeel(UIManager.java:537)
at javax.swing.UIManager.setLookAndFeel(UIManager.java:581)
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:597)
at
org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:86)
at groovy.lang.MetaMethod.doMethodInvoke(MetaMethod.java:230)
at
groovy.lang.MetaClassImpl.invokeStaticMethod(MetaClassImpl.java:1105)
at
org.codehaus.groovy.runtime.InvokerHelper.invokeMethod(InvokerHelper.java:749)
at
org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodN(ScriptBytecodeAdapter.java:170)
at groovy.ui.Console.main(Console.groovy:120)
... 6 more
Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
at
com.sun.java.swing.plaf.gtk.GTKLookAndFeel.initSystemColorDefaults(GTKLookAndFeel.java:1267)
at
com.sun.java.swing.plaf.gtk.GTKLookAndFeel.loadStyles(GTKLookAndFeel.java:1509)
at
com.sun.java.swing.plaf.gtk.GTKLookAndFeel.access$000(GTKLookAndFeel.java:37)
at
com.sun.java.swing.plaf.gtk.GTKLookAndFeel$WeakPCL$1.run(GTKLookAndFeel.java:1449)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:597)
at
java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:273)
at
java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:183)
at
java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:173)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:168)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:160)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:121)

--
View this message in context: http://www.nabble.com/Fail-to-launch-groovyConsole-under-Ubuntu-8.04-tp17008499p17008499.html
Sent from the groovy - user mailing list archive at Nabble.com.


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

http://xircles.codehaus.org/manage_email


Danno Ferrin

unread,
May 2, 2008, 9:26:26 AM5/2/08
to us...@groovy.codehaus.org
Looks related to this bug....
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6389282

Also this groovy bug seems to be the same issue, GROOVY-2672 so no need to post a jira.

Are you able to try trunk builds or Java6 Update 10 (Consumer JRE)?  The ug says it's fix jvm wise in 6u10, but there looks to be a patch that can be done code wise.

--Danno
--
------------------------------------------------------
I'm Danno Ferrin, and I approved this message.

Danno Ferrin

unread,
May 2, 2008, 10:37:22 AM5/2/08
to us...@groovy.codehaus.org
On Fri, May 2, 2008 at 2:22 AM, Daniel.Sun <realb...@hotmail.com> wrote:

Hi all,

When I tried to launch groovy console under Ubuntu 8.04, I got the following
exceptions.

The relevent environment variables:
JAVA_HOME=/usr/java/jdk1.6.0
GROOVY_HOME=/usr/groovy-1.5.6
PATH=/usr/java/jdk1.6.0/bin:/usr/groovy-1.5.6/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games
CLASSPATH=.:/usr/java/jdk1.6.0/lib

Could you tell me what's wrong with my settings?

Any help is much appreciated!

Thanks in advance!
Daniel.Sun

Hmm... works in virtualbox.  Do you have the advanced graphics features turned on?  Desktop composition and such?  Sun's releases of Java still seem to have issues with it, especially 1.6.0 FCS.  Could you ratchet down the visual effects to "None" and see if it still fails?  And upgrade to 6u5? (should be in the universe packages)

Danno Ferrin

unread,
May 4, 2008, 1:07:03 AM5/4/08
to us...@groovy.codehaus.org
Hate to say it, but it works for me in standalone 8.04 with the ubuntu package.  Precicely what kind of hardware are you running this on?

Daniel.Sun

unread,
May 4, 2008, 2:46:37 AM5/4/08
to us...@groovy.codehaus.org

I'm using 'Dell Latitude D810'

It's very odd :(

Thanks for your reply again and again.
Daniel.Sun

--
View this message in context: http://www.nabble.com/Fail-to-launch-groovyConsole-under-Ubuntu-8.04-tp17008499p17043355.html

Paul King

unread,
May 4, 2008, 5:45:12 AM5/4/08
to us...@groovy.codehaus.org
Daniel.Sun wrote:
> I'm using 'Dell Latitude D810'
>
> It's very odd :(

I have been using groovy (tarball version) on Ubuntu 8.04
without issue under VirtualBox. I haven't tried the
packages. I was using 1.6.0_06.

Paul.

Danno Ferrin

unread,
May 4, 2008, 10:39:17 AM5/4/08
to us...@groovy.codehaus.org
I am using a Dell 830, so that is kinda suprising.  Are you usung the sun java 6 packages accessable from the ubuntu updater?  That may be the issue,an older 1.6 build.  6u6 is what I am running.

Daniel.Sun

unread,
May 5, 2008, 9:16:35 AM5/5/08
to us...@groovy.codehaus.org

I am using jdk6u6 too, which was downloaded from java.sun.com site.

Maybe I have to wait for the next release of jdk6.

Thanks,
Daniel.Sun

--
View this message in context: http://www.nabble.com/Fail-to-launch-groovyConsole-under-Ubuntu-8.04-tp17008499p17061424.html

Danno Ferrin

unread,
May 5, 2008, 12:20:23 PM5/5/08
to us...@groovy.codehaus.org
Try the sun-java-6 package from the ubuntu respositorys, they may have distro specific tweaks in it.  That's what I've got.

Ciro Cavani

unread,
May 5, 2008, 12:36:34 PM5/5/08
to us...@groovy.codehaus.org
I am using Ubuntu 8.04 with Java6 packages from multiverse.

First, with only jre, startConsole didn't work (actually, using JAVA_HOME, it works). With jdk package it start nice (without setting JAVA_HOME explicitly).

JAVA_HOME=/usr/lib/jvm/java-6-sun

Second, I had some problems with /etc/alternatives. Alternative links don't update correct after removing Java5 and installing Java6:

sudo update-alternatives --auto <name>

where <name> is the broken link at /etc/alternatives.

Thanks,
Reply all
Reply to author
Forward
0 new messages