首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >无法运行griffon应用程序

无法运行griffon应用程序
EN

Stack Overflow用户
提问于 2013-01-26 02:20:38
回答 2查看 354关注 0票数 0

我正在尝试在griffon中运行一个测试应用程序。我可以创建应用程序,但当我运行它时,我得到以下错误:

代码语言:javascript
复制
2013-01-25 11:12:02,352 [main] INFO  griffon.swing.SwingApplication - Initializing all startup groups: [test1]
2013-01-25 11:12:05,702 [AWT-EventQueue-0] ERROR org.codehaus.griffon.runtime.builder.UberBuilder - An error occurred while building test1.Test1View@63935d75
java.lang.RuntimeException: Failed to create component for 'application' reason: java.awt.HeadlessException
        at org.codehaus.griffon.runtime.builder.UberInterceptorMetaClass.invokeFactoryMethod(UberInterceptorMetaClass.groovy:97)
        at org.codehaus.griffon.runtime.builder.UberInterceptorMetaClass.this$3$invokeFactoryMethod(UberInterceptorMetaClass.groovy)
        at org.codehaus.griffon.runtime.builder.UberInterceptorMetaClass$this$3$invokeFactoryMethod.callCurrent(Unknown Source)
        at org.codehaus.griffon.runtime.builder.UberInterceptorMetaClass.invokeMethod(UberInterceptorMetaClass.groovy:168)
        at test1.Test1View.run(Test1View.groovy:11)
        at org.codehaus.griffon.runtime.builder.UberInterceptorMetaClass.invokeMethod(UberInterceptorMetaClass.groovy:152)
        at org.codehaus.griffon.runtime.builder.UberBuilder.build(UberBuilder.groovy:160)
        at org.codehaus.griffon.runtime.core.AbstractMVCGroup$1.run(AbstractMVCGroup.java:129)
Caused by: java.awt.HeadlessException
        at griffon.swing.SwingUtils.createApplicationFrame(SwingUtils.java:133)
        at griffon.swing.AbstractSwingGriffonApplication.createApplicationContainer(AbstractSwingGriffonApplication.java:99)
        at griffon.core.GriffonApplication$createApplicationContainer.call(Unknown Source)
        at griffon.swing.factory.ApplicationFactory.newInstance(ApplicationFactory.groovy:54)
        ... 8 more
2013-01-25 11:12:05,714 [main] ERROR griffon.util.GriffonExceptionHandler - Uncaught Exception
java.lang.RuntimeException: Failed to create component for 'application' reason: java.awt.HeadlessException
        at org.codehaus.griffon.runtime.builder.UberInterceptorMetaClass.invokeFactoryMethod(UberInterceptorMetaClass.groovy:97)
        at org.codehaus.griffon.runtime.builder.UberInterceptorMetaClass.this$3$invokeFactoryMethod(UberInterceptorMetaClass.groovy)
        at org.codehaus.griffon.runtime.builder.UberInterceptorMetaClass$this$3$invokeFactoryMethod.callCurrent(Unknown Source)
        at org.codehaus.griffon.runtime.builder.UberInterceptorMetaClass.invokeMethod(UberInterceptorMetaClass.groovy:168)
        at test1.Test1View.run(Test1View.groovy:11)
        at org.codehaus.griffon.runtime.builder.UberInterceptorMetaClass.invokeMethod(UberInterceptorMetaClass.groovy:152)
        at org.codehaus.griffon.runtime.builder.UberBuilder.build(UberBuilder.groovy:160)
        at org.codehaus.griffon.runtime.core.AbstractMVCGroup$1.run(AbstractMVCGroup.java:129)
Caused by: java.awt.HeadlessException
        at griffon.swing.SwingUtils.createApplicationFrame(SwingUtils.java:133)
        at griffon.swing.AbstractSwingGriffonApplication.createApplicationContainer(AbstractSwingGriffonApplication.java:99)
        at griffon.core.GriffonApplication$createApplicationContainer.call(Unknown Source)
        at griffon.swing.factory.ApplicationFactory.newInstance(ApplicationFactory.groovy:54)
        ... 8 more

你能给出的任何见解都是很棒的。我的设置是:

Kubuntu Linux 12.10 64位

代码语言:javascript
复制
------------------------------------------------------------
  Griffon 1.2.0
------------------------------------------------------------

   Build: 11-Jan-2013 09:10 AM
  Groovy: 2.0.6
     Ant: 1.8.4
   Slf4j: 1.7.2
  Spring: 3.2.0.RELEASE
     JVM: 1.7.0_09 (Oracle Corporation 23.2-b09)
      OS: Linux 3.5.0-22-generic amd64

谢谢!!

ironmantis7x

EN

回答 2

Stack Overflow用户

回答已采纳

发布于 2013-01-26 06:22:04

找到了!我需要安装JRE,但我没有安装,它正在寻找我需要的依赖项。

票数 0
EN

Stack Overflow用户

发布于 2013-01-26 03:21:28

正如在http://docs.oracle.com/javase/6/docs/api/java/awt/HeadlessException.html的文档中提到的,这应该是键盘、鼠标或显示器的问题。

假设您没有强制使用"-Djava.awt.headless=true",这很可能是由于缺少到X服务器的连接造成的。

类型

代码语言:javascript
复制
echo $DISPLAY

在终端窗口中。通常输出":0“。确保设置了变量(对于终端窗口是自动设置的),并尝试启动一个非常基本的X应用程序,比如"xterm“。如果运行正常,griffon应用程序应该会启动并显示。

票数 1
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/14527985

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档