gwtproject / gwt

GWT Open Source Project
http://www.gwtproject.org
1.49k stars 371 forks source link

[GWTD] GWT Designer fails to load after converting to GXT #6489

Closed dankurka closed 9 years ago

dankurka commented 9 years ago

Originally reported on Google Code with ID 6490

Found in GWT Release 2.3.0, GPE 2.3.1, Designer 2.3.1, Designer Beta 2.3.1.r35x201106081736.

Encountered on OS / Browser (e.g. WinXP, IE6-7, FF3):
Win7, FF3, Eclipse 3.5 (galileo).

Detailed description (please be as specific as possible):
Trying to build out a proof of concept, cannot run correctly without using Designer
beta and cannot run Designer with GXT *at all*.

1.  Eclipse 3.5 (galileo) installed at C:\dev_inst\eclipse

2.  Installed GPE for 3.5.

3.  Created project using Tomcat 6.0, project structure below
C:\dev\eclipse\support_HEAD\schleind....................................project root
C:\dev\eclipse\support_HEAD\schleind\source.............................source dir
C:\dev\eclipse\support_HEAD\schleind\sourcecontrol\web..................war directory
C:\dev\eclipse\support_HEAD\schleind\sourcecontrol\web\WEB-INF\web.xml..
C:\dev\eclipse\support_HEAD\schleind\edu\upenn\isc\fast\matt\mattflix...package for
GWT module MattFlix.gwt.xml:
        <module>
            <inherits name="com.google.gwt.user.User"/>
            <inherits name="com.google.gwt.user.theme.standard.Standard"/>
            <inherits name="com.extjs.gxt.ui.GXT"/>
            <entry-point class="edu.upenn.isc.schleind.mattflix.client.MattFlix"/>
        </module>
C:\dev\eclipse\support_HEAD\schleind\sourcecontrol\web\assets...........contains MattFlix.css
C:\dev\eclipse\support_HEAD\schleind\sourcecontrol\web\jsp\mattFlix.jsp contains <link
type="text/css" rel="stylesheet" href="../assets/MattFlix.css">

4. Configured the project for tomcat, disabled jetty...
  4.1. Configure the Web Toolkit settings
    4.1.1.  select "Use WebToolkit" (checked)
    4.1.2.  Use default SDK 2.3.0.
  4.2. Configure Google WebApplication settings
    4.2.1.  Checked "This project has a war directory"
    4.2.2.  WAR directory:  sourcecontrol/web
    4.2.3.  Launch and deploy from this directory
  4.3.  Added launch configuration under Run->Debug configurations->'g' Web Application:

          -codeServerPort 9997 -noserver -remoteUI "${gwt_remote_ui_server_port}:${unique_id}"
-logLevel INFO -war C:\dev\eclipse\support_HEAD\schleind\sourcecontrol\web edu.upenn.isc.schleind.mattFlix.mattFlix
-startupUrl http://localhost:8090/schleind/jsp/fast.do edu.upenn.isc.schleind.mattflix.MattFlix
  4.4.  At this point everything worked perfectly except that I needed to use the workaround
indicated in Issue 6349 for the designer to startup, ie:
    4.4.1.  edit C:\dev\eclipse\support_HEAD\schleind\sourcecontrol\web\WEB-INF\classes\edu\upenn\isc\schleind\mattflix.MattFlix.gwt.xml,
    4.4.2.  comment out the line:  <entry-point class="edu.upenn.isc.schleind.mattflix.client.MattFlix"/>
 (a sad hack!)

5.  Further comments in Issue 6349 suggested Designer beta 2.3.1.r36x201106081537,
so I uninstalled the GPE and installed the Designer beta
  3.1.  Issue 6349 resolved, GWT now appears to be working perfectly (production builds,
Designer appears to be fully functional, can debug, etc)
  3.2.  Current installations in Eclipse look like this:
  Eclipse IDE for Java EE Developers    1.2.0.20090621-0820 epp.package.jee
  FastConfigurationFeature  1.0.0.200907281405  edu.upenn.isc.fast.fastConfigurationFeature.feature.group
  Google App Engine Java SDK 1.5.0  1.5.0.r35v201105191506  com.google.appengine.eclipse.sdkbundle.e35.feature.feature.group
  Google Web Toolkit SDK 2.3.0  2.3.0.r35v201105191506  com.google.gwt.eclipse.sdkbundle.e35.feature.feature.group
  GWT Designer  2.3.1.r35x201106081736  com.google.gdt.eclipse.designer.feature.feature.group
  GWT Designer Core 2.3.1.r35x201106081537  com.google.gdt.eclipse.designer.hosted.feature.feature.group
  GWT Designer Editor   2.3.1.r35x201106081541  com.google.gdt.eclipse.designer.editor.feature.feature.group
  JavaRebel Eclipse Debugger Integration (Optional) 1.0.3.200907231937  org.zeroturnaround.eclipse.debug.feature.feature.group
  JavaRebel Eclipse Integration 1.0.3.200907231937  org.zeroturnaround.eclipse.feature.feature.group
  JavaRebel WTP Integration (Optional)  1.0.3.200907231937  org.zeroturnaround.eclipse.wtp.feature.feature.group
  QuickREx  3.5.0   de.babe.eclipse.features.QuickREx.feature.group
  WindowBuilder Core    1.0.0.r35x201106081531  org.eclipse.wb.core.feature.feature.group
  WindowBuilder Core Documentation  1.0.0.r35x201106081535  org.eclipse.wb.doc.user.feature.feature.group
  WindowBuilder Core UI 1.0.0.r35x201106081733  org.eclipse.wb.core.ui.feature.feature.group
  WindowBuilder CSS Support 1.0.0.r35x201106081534  org.eclipse.wb.css.feature.feature.group
  WindowBuilder XML Core    1.0.0.r35x201106081533  org.eclipse.wb.core.xml.feature.feature.group

6.  Downloaded GXT 2.2.4...
  6.1. Right clicked on MattFlix.gwt.xml, chose convert to GXT, pointed to unzipped
GXT download with gxt.jar present
  6.2. While <inherits name="com.extjs.gxt.ui.GXT"/> was put in gwt.xml, there are
a number of obvious malfunctions:
    6.2.1.  A new war directory containing ExtGWT was created under the project root:
 C:\dev\eclipse\support_HEAD\schleind\war\ExtGWT
    6.2.2.  No css entries were made to my jsp, and there was no warning that this was
not done
    6.2.3.  Per GXT setup.txt, I think there should also be a classpath addition to my
Google debug launch but its not there
    6.2.4.  A gxt.jar was placed directly under the project root:  /schleind/gxt.jar
  6.3.  Given that the configuration routine had obvious failures, it's not surprisng
that the Designer now fails to open:
    6.3.1.  "GXT requires not just gxt.jar, but also set of resources, such as CSS
files, images, etc. GWT Designer was not able to find "gxt-.css" file."
    6.3.2.  So now I fix 6.2.1-6.2.3
      6.3.2.1.  Move ExtGWT from unused, wizard-created war directory to real war directory
in this project, sourcecontrol/web (remove war directory)
      6.3.2.2.  Add entry in module jsp mattFlix.jsp referring to gxt css:  <link type="text/css"
rel="stylesheet" href="../ExtGWT/css/gxt-all.css">
      6.3.2.3.  Add gxt.jar under our real war directory:  C:\dev\eclipse\support_HEAD\schleind\sourcecontrol\web\WEB-INF\lib
      6.3.2.4.  Add this gxt.jar to the project libraries and to the Google debug launch
classpath
    6.3.3.  So now try suggestion #2 from Designer error:  "ensure that your project has
HTML file which corresponds to the GWT module which you are trying to edit."
      6.3.3.1.  Fails after MattFlix.html and/or MattFlix.htm put in war directory 'soucecontrol/web',
page was served by tomcat with gxt style applied:
            <html>
              <head>
                <link type="text/css" rel="stylesheet" href="/ExtGWT/css/gxt-all.css">
              </head>
              <body>    
                <h2 class="x-progress-text" >I guess this only works if everyone has the 'default'
configuration... </h2>
              </body>
            </html>
    6.3.4.  Now try suggestion #3:  "include GXT CSS file using "stylesheet" element in
your module file", so I tried a few variations, reparsing failed each time:
      6.3.4.1.  <stylesheet src="/ExtGWT/css/gxt-all.css" />
      6.3.4.2.  <stylesheet src="/schleind/ExtGWT/css/gxt-all.css" />
      6.3.4.3.  <stylesheet src="ExtGWT/css/gxt-all.css" />
      6.3.4.3.  <stylesheet src="../ExtGWT/css/gxt-all.css" />

So unless someone can show me where I went wrong, Designer can't handle different configurations
and can't handle important 3rd party component libraries, although I've put together
demo apps (eg StockWatcher) where it does.  Unfortunately, until it handles it, anybody
whose project structure deviates from 'the default' will be restricted to building
wireframes and doing demos...

Shortest code snippet which demonstrates issue (please indicate where
actual result differs from expected result):
see above

Workaround if you have one:
None.

Links to relevant GWT Developer Forum posts:
https://code.google.com/p/google-web-toolkit/issues/detail?id=6093
http://code.google.com/p/google-web-toolkit/issues/detail?id=6349

Reported by mattschleindl@yahoo.com on 2011-06-17 15:27:20

dankurka commented 9 years ago
Rebuilt this project from the ground up converting to GWT again, selected Ext-GWT support
during module creation and appears to be working properly.

Reported by mattschleindl@yahoo.com on 2011-06-18 20:31:20

dankurka commented 9 years ago
OK, if it works, then I'm closing it.

Reported by scheglov@google.com on 2011-06-22 19:17:52