Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Problem running SmartGWT on SuperDev Mode

    I am using
    SmartGWT 6.0p_2017-08-15 and
    GWT 2.8.0 .
    Using Google Chrome Version 60.0.3112.78 (Official Build) (32-bit) for testing.
    GWT Plugin 3.0.0.x
    Eclipse Neon 3 (4.6.3)
    Windows 7 , 64-bit OS

    I migrated from SmartGWT 4.0p and gwt 2.6.0 to the above version. i use the classic dev mode to debug. After the migration, i tried moving to the Super Dev Mode and having trouble getting there. When i run the application on SuperDev mode for debugging . The application is getting compiled but throwing the error on the screen while loading (attached)

    https://www.smartclient.com/smartgwt...eshooting.html

    I have added all the necessary scripts from the topic "Script Tags in Super Dev Mode" on this forum. One thing that i noticed is , when ever i start up the application in SDM "loadScriptTagFiles.js" file is not generated. So as per the instruction ,if i start in Classic Dev mode the file gets generated, but goes away if i switch to SDM.

    I had few luck with Classic dev mode for couple of times, but that is also not consistent. Am bumping in to the below error, each time it tries to load the application using debug URL on firefox 21, This version of FF has the installed gwt debug plugin.

    16:49:55.243 [ERROR] [seweb] Unable to load module entry point class com.smartgwt.client.SmartGwtEntryPoint (see associated exception for details)

    com.google.gwt.core.client.JavaScriptException: (TypeError) @com.smartgwt.client.util.I18nUtil::initBuiltinTypes()([]): $wnd.isc.builtinTypes.localeInt is undefined
    at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:252)
    at com.google.gwt.dev.shell.ModuleSpaceOOPHM.doInvoke(ModuleSpaceOOPHM.java:121)
    at com.google.gwt.dev.shell.ModuleSpace.invokeNative(ModuleSpace.java:573)
    at com.google.gwt.dev.shell.ModuleSpace.invokeNativeVoid(ModuleSpace.java:315)
    at com.google.gwt.dev.shell.JavaScriptHost.invokeNativeVoid(JavaScriptHost.java:107)
    at com.smartgwt.client.util.I18nUtil.initBuiltinTypes(I18nUtil.java)
    at com.smartgwt.client.util.I18nUtil.init(I18nUtil.java:33)
    at com.smartgwt.client.SmartGwtEntryPoint.onModuleLoad(SmartGwtEntryPoint.java:454)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at com.google.gwt.dev.shell.ModuleSpace.onLoad(ModuleSpace.java:423)
    at com.google.gwt.dev.shell.OophmSessionHandler.loadModule(OophmSessionHandler.java:200)
    at com.google.gwt.dev.shell.BrowserChannelServer.processConnection(BrowserChannelServer.java:530)
    at com.google.gwt.dev.shell.BrowserChannelServer.run(BrowserChannelServer.java:368)
    at java.lang.Thread.run(Thread.java:745)

    Am not able to do the client side debugging because of the issues in both mode, Please help.
    Attached Files
    Last edited by jeslinedias; 3 Oct 2017, 12:36. Reason: Updated OS, Plugin version and the link to the referred topic from this forum

    #2
    Originally posted by jeslinedias View Post
    I have added all the necessary scripts from the topic "Script Tags in Super Dev Mode" on this forum.
    What do you mean? If you've removed all the script tags from your modules and now load them directly in the HTML, you shouldn't need anything in loadScriptTagFiles.js. Can you link to the thread you're referring to?

    Originally posted by jeslinedias View Post
    One thing that i noticed is , when ever i start up the application in SDM "loadScriptTagFiles.js" file is not generated. So as per the instruction ,if i start in Classic Dev mode the file gets generated, but goes away if i switch to SDM.
    What version of Eclipse are you using, what OS, and what version of the GWT Plugin? You are running SDM through the GWT Plugin, right?

    When you say "goes away," what do you mean? Is the file completely gone, or does it have zero length?

    What we would suggest first is that you import the BuiltInDS sample project into Eclipse (File >> Import), and attempt to run that with the same GWT version, JDK, and GWT Plugin, and see whether that works. We've verified on our end that it works for us.





    Comment


      #3
      Note also that you should always try the latest build when you encounter a bug like this. Although the symptoms don't match what you describe, we did fix an issue with the Eclipse project impacting the new GWT v3 Plugin after the date of the build you're using.

      Comment


        #4
        I have updated the verison of eclipse ,plugin and the link am referring for SuperDevMode setup. I dont get your first question, am not removing any script tab. Do i have to do that ?

        When you say "goes away," what do you mean? Is the file completely gone, or does it have zero length?
        Yes the file is gone, no file in the directory.

        Am gonna check with the BuiltInDS project first.
        Last edited by jeslinedias; 4 Oct 2017, 07:40.

        Comment


          #5
          Our first question was asking you to explain what you meant by this:

          Originally posted by jeslinedias View Post
          I have added all the necessary scripts from the topic "Script Tags in Super Dev Mode" on this forum.
          If you've added script tags to load the Framework to your HTML, and also switched your module file (gwt.xml) to load the NoScript variant as the help topic suggests (e.g. com.smartgwtee.SmartGwtEENoScript), then your loadScriptTagFiles.js should be empty and won't be needed at all. So if you're ever seeing a non-empty loadScriptTagFiles.js after those changes (whether in SDM or Classic Dev Mode), that doesn't make sense - unless you have one or more script tags in your own module files (not the ones we provide).
          Last edited by Isomorphic; 4 Oct 2017, 09:44.

          Comment


            #6
            my boot loading html has the below lines

            Code:
            <-- Scripts related to SmartGWT debug
            <script src="seweb/sc/modules/ISC_Core.js">          </script>
            <script src="seweb/sc/modules/ISC_Foundation.js">    </script>
            <script src="seweb/sc/modules/ISC_Containers.js">    </script>
            <script src="seweb/sc/modules/ISC_Grids.js">         </script>
            <script src="seweb/sc/modules/ISC_Forms.js">         </script>
            <script src="seweb/sc/modules/ISC_RichTextEditor.js"></script>
            <script src="seweb/sc/modules/ISC_Calendar.js">      </script>
            <script src="seweb/sc/modules/ISC_DataBinding.js">   </script>
            
            <script src="sc/skins/fleet/load_skin.js"></script>
            my *.gwt.xml looks line below

            Code:
            <inherits name='com.google.gwt.user.User' />
                <!-- <inherits name="com.citi.gwt.raphgwt.Raphgwt" /> -->
                <inherits name="com.google.gwt.i18n.I18N" />
                <!-- <set-property name="user.agent" value="gecko1_8" /> -->
                <inherits name="com.google.gwt.http.HTTP" />
                <inherits name='com.google.codemirror2_gwt.CodeMirror2GWT' />
                <inherits name="com.google.gwt.core.Core" />
                <inherits name="com.google.gwt.user.History" />
                <inherits name="com.google.gwt.visualization.Visualization" />
                <!-- <inherits name="com.smartgwtee.SmartGwtEENoScript"/> -->
                <inherits name="com.smartgwt.SmartGwtNoScript"/>
                <inherits name="com.smartgwt.SmartGwt"/>
                <inherits name="com.smartgwt.SmartGwtNoTheme" />
            As i stated before, the Classic mode is creating loadScriptTagFiles.js
            I am not able to get your BuiltInDS project, since am not using enterprise edition. Please suggest if there is anyother way !

            Is there any way you can help me going with the Classic mode working ? I have tried the steps of clearing unit-cache and compile and deploy many times, it still gives the error

            Code:
            com.google.gwt.core.client.JavaScriptException: (TypeError) @com.smartgwt.client.util.I18nUtil::initBuiltinTypes()([]): $wnd.isc.builtinTypes.localeInt is undefined
            at com.google.gwt.dev.shell.BrowserChannelServer.invokeJavascript(BrowserChannelServer.java:252)
            Last edited by jeslinedias; 4 Oct 2017, 13:16. Reason: Added few more comment

            Comment


              #7
              It looks like you've tried to switch to manually loading the Framework JS files in your HTML, which means you won't need to worry about loadScriptTagFiles.js at all or use the workaround of switching to Classic Dev Mode (assuming you don't have your own script tags that you load in your module file(s)). However, you've not modified the module file correctly as explained by the topic "Script Tags in Super Dev Mode" - you should only be loading one SmartGWT variant, not three of them.

              When manually loading the Framework JS in HTML, you should choose one of:
              • com.smartgwt.SmartGwtNoScript
              • com.smartgwt.SmartGwtNoScriptNoTheme
              • com.smartgwt.debug.SmartGwtNoScriptDebug

              If you want to experiment with SGWT 6.0p Enterprise, you can download the Evaluation Edition for free.

              Classic Mode is really not recommended as support for it was dropped long ago from most browsers, but if you must use it with FF, you should probably use FF24ESR which is the most recently end-of-lifed version that supports Classic Dev Mode. (The suggestion to switch the GWT Plugin to Classic Dev Mode was merely a workaround to a problem that it appears you shouldn't have, since you are manually loading the Framework JS.)
              Last edited by Isomorphic; 4 Oct 2017, 13:42.

              Comment


                #8
                I think am a bit clear on what to do .
                Now i have removed all the manual adding of the Framework scripts to the HTML, I also had other scripts loaded at my boot html (codemirror) and i have fixed the module loading. Now am just using only the below inherit
                • com.smartgwt.SmartGwtNoScriptNoThem
                I was able to start the application in Super Dev Mode. But the flow is not stopping at the book mark, even though i have started in debug mode. Below are the steps i followed and the logs. Please let me know, what am i missing.

                1. Hit the application URL, it loaded and i got the landing page
                2. Clicked the bookmark "Dev Mode On" . The application , recompiled and loaded the landing page again.
                3. Then i click the page where i had the bookmark. But its not stopping or debugging.

                Code:
                Running CodeServer with parameters: [-noprecompile, -port, 9876, -sourceLevel, 1.8, -bindAddress, 127.0.0.1, -launcherDir, C:\Jesline\SEVI-Code\TaaSMigWS\SeviWeb\target\SeviWeb-3.0.0-SNAPSHOT\WEB-INF\classes, -logLevel, INFO, -style, OBFUSCATED, com.citi.sevi.web.SEWeb]
                Super Dev Mode starting up
                Oct 05, 2017 10:18:14 AM java.util.prefs.WindowsPreferences &lt;init&gt;
                WARNING: Could not open/create prefs root node Software\JavaSoft\Prefs at root 0x80000002. Windows RegCreateKeyEx(...) returned error code 5.
                   workDir: C:\Users\jj96228\AppData\Local\Temp\gwt-codeserver-2194382757187084275.tmp
                7 [main] INFO org.eclipse.jetty.util.log - Logging initialized @5822ms
                   Loading Java files in com.citi.sevi.web.SEWeb.
                   Module setup completed in 18402 ms
                14437 [main] INFO org.eclipse.jetty.server.Server - jetty-9.2.14.v20151106
                14490 [main] INFO org.eclipse.jetty.server.handler.ContextHandler - Started o.e.j.s.ServletContextHandler@444a633b{/,null,AVAILABLE}
                14534 [main] INFO org.eclipse.jetty.server.ServerConnector - Started ServerConnector@176fae3d{HTTP/1.1}{127.0.0.1:9876}
                14534 [main] INFO org.eclipse.jetty.server.Server - Started @20350ms
                
                The code server is ready at http://127.0.0.1:9876/
                Code server started in 19.20 s ms
                14858 [main] INFO org.eclipse.jetty.server.Server - jetty-9.2.14.v20151106
                [WARN] Server class 'org.springframework.web.SpringServletContainerInitializer' could not be found in the web app, but was found on the system classpath
                   [WARN] Adding classpath entry 'file:/C:/Users/jj96228/.m2/repository/org/springframework/spring-web/4.2.9.RELEASE/spring-web-4.2.9.RELEASE.jar' to the web app classpath for this session
                15144 [main] INFO / - No Spring WebApplicationInitializer types detected on classpath
                15242 [main] INFO org.eclipse.jetty.server.handler.ContextHandler - Started c.g.g.d.s.j.WebAppContextWithReload@9e3ba0b{/,file:/C:/Jesline/SEVI-Code/TaaSMigWS/SeviWeb/target/SeviWeb-3.0.0-SNAPSHOT/WEB-INF/classes/,AVAILABLE}{C:\Jesline\SEVI-Code\TaaSMigWS\SeviWeb\target\SeviWeb-3.0.0-SNAPSHOT\WEB-INF\classes}
                15273 [main] INFO org.eclipse.jetty.server.ServerConnector - Started ServerConnector@eeaf583{HTTP/1.1}{127.0.0.1:8888}
                15273 [main] INFO org.eclipse.jetty.server.Server - Started @21088ms
                [WARN] No startup URLs supplied and no plausible ones found -- use -startupUrl
                Linking modules
                   Bootstrap link for command-line module 'com.citi.sevi.web.SEWeb'
                      Linking module 'seweb'
                         Invoking Linker Cross-Site-Iframe
                            Ignoring the following script tags in the gwt.xml file
                sc/skins/fleet/load_skin.js
                
                   Invoking Linker SmartGwtScriptInjector
                      Creating loadScriptTagFiles.js to manually load the following script tags:
                sc/skins/fleet/load_skin.js
                GET /recompile/seweb
                   Job com.citi.sevi.web.SEWeb_1_0
                      starting job: com.citi.sevi.web.SEWeb_1_0
                      binding: user.agent=safari
                      Compiling module com.citi.sevi.web.SEWeb
                         Unification traversed 598 fields and methods and 175 types. 0 are considered part of the current module and 5 had all of their fields and methods traversed.
                         Compiling 1 permutation
                            Compiling permutation 0...
                            Linking per-type JS with 0 new/changed types.
                            Source Maps Enabled
                         Compile of permutations succeeded
                         Compilation succeeded -- 5.644s
                      Linking into C:\Users\jj96228\AppData\Local\Temp\gwt-codeserver-2194382757187084275.tmp\com.citi.sevi.web.SEWeb\compile-2\war\seweb; Writing extras to C:\Users\jj96228\AppData\Local\Temp\gwt-codeserver-2194382757187084275.tmp\com.citi.sevi.web.SEWeb\compile-2\extras\seweb
                         Invoking Linker Cross-Site-Iframe
                            Ignoring the following script tags in the gwt.xml file
                sc/skins/fleet/load_skin.js
                
                   Invoking Linker SmartGwtScriptInjector
                      Creating loadScriptTagFiles.js to manually load the following script tags:
                sc/skins/fleet/load_skin.js
                         Link succeeded
                         Linking succeeded -- 13.362s
                      29.663s total -- Compile completed
                GET /seweb/style.css
                   Sent error page: not found: C:\Users\jj96228\AppData\Local\Temp\gwt-codeserver-2194382757187084275.tmp\com.citi.sevi.web.SEWeb\compile-2\war\seweb\style.css.gz

                Comment


                  #9
                  Originally posted by jeslinedias View Post
                  I think am a bit clear on what to do .
                  Now i have removed all the manual adding of the Framework scripts to the HTML, I also had other scripts loaded at my boot html (codemirror) and i have fixed the module loading. Now am just using only the below inherit
                  • com.smartgwt.SmartGwtNoScriptNoThem
                  That doesn't make sense. First, switching to manually loading all scripts is the suggested approach, as that's what GWT 2.7+ officially supports. The workaround we implement is not intended as a permanent solution going forward across multiple (future) releases of GWT. We didn't say that you doing the manual loading - as recommended by our help topic - was wrong. We merely said that you shouldn't load multiple SmartGwt module variations.

                  If you have indeed removed manually loading of the Framework from your HTML, then the NoScript variant of the SmartGwt shouldn't work - because it also doesn't load any script tags. So what you've described just doesn't make sense. The output you include below is further confusing, because it suggests you're still relying on automatic loading for the skin, via something like
                  Code:
                  <inherits name="com.smartclient.theme.fleet.FleetResources"/>
                  If you really want to avoid the loadScriptTagFile.js completely, you'll need to drop this dependency and manually load the skin (as well as all the Framework files recommended by the help topic) in your HTML.

                  Fortunately, though, the Framework should still load with the skin missing, but it will be clearly evident there's a problem.

                  Originally posted by jeslinedias View Post
                  I was able to start the application in Super Dev Mode. But the flow is not stopping at the book mark, even though i have started in debug mode. Below are the steps i followed and the logs. Please let me know, what am i missing.

                  1. Hit the application URL, it loaded and i got the landing page
                  2. Clicked the bookmark "Dev Mode On" . The application , recompiled and loaded the landing page again.
                  3. Then i click the page where i had the bookmark. But its not stopping or debugging.

                  Code:
                  Running CodeServer with parameters: [-noprecompile, -port, 9876, -sourceLevel, 1.8, -bindAddress, 127.0.0.1, -launcherDir, C:\Jesline\SEVI-Code\TaaSMigWS\SeviWeb\target\SeviWeb-3.0.0-SNAPSHOT\WEB-INF\classes, -logLevel, INFO, -style, OBFUSCATED, com.citi.sevi.web.SEWeb]
                  Super Dev Mode starting up
                  Oct 05, 2017 10:18:14 AM java.util.prefs.WindowsPreferences &lt;init&gt;
                  WARNING: Could not open/create prefs root node Software\JavaSoft\Prefs at root 0x80000002. Windows RegCreateKeyEx(...) returned error code 5.
                  workDir: C:\Users\jj96228\AppData\Local\Temp\gwt-codeserver-2194382757187084275.tmp
                  7 [main] INFO org.eclipse.jetty.util.log - Logging initialized @5822ms
                  Loading Java files in com.citi.sevi.web.SEWeb.
                  Module setup completed in 18402 ms
                  14437 [main] INFO org.eclipse.jetty.server.Server - jetty-9.2.14.v20151106
                  14490 [main] INFO org.eclipse.jetty.server.handler.ContextHandler - Started o.e.j.s.ServletContextHandler@444a633b{/,null,AVAILABLE}
                  14534 [main] INFO org.eclipse.jetty.server.ServerConnector - Started ServerConnector@176fae3d{HTTP/1.1}{127.0.0.1:9876}
                  14534 [main] INFO org.eclipse.jetty.server.Server - Started @20350ms
                  
                  The code server is ready at http://127.0.0.1:9876/
                  Code server started in 19.20 s ms
                  14858 [main] INFO org.eclipse.jetty.server.Server - jetty-9.2.14.v20151106
                  [WARN] Server class 'org.springframework.web.SpringServletContainerInitializer' could not be found in the web app, but was found on the system classpath
                  [WARN] Adding classpath entry 'file:/C:/Users/jj96228/.m2/repository/org/springframework/spring-web/4.2.9.RELEASE/spring-web-4.2.9.RELEASE.jar' to the web app classpath for this session
                  15144 [main] INFO / - No Spring WebApplicationInitializer types detected on classpath
                  15242 [main] INFO org.eclipse.jetty.server.handler.ContextHandler - Started c.g.g.d.s.j.WebAppContextWithReload@9e3ba0b{/,file:/C:/Jesline/SEVI-Code/TaaSMigWS/SeviWeb/target/SeviWeb-3.0.0-SNAPSHOT/WEB-INF/classes/,AVAILABLE}{C:\Jesline\SEVI-Code\TaaSMigWS\SeviWeb\target\SeviWeb-3.0.0-SNAPSHOT\WEB-INF\classes}
                  15273 [main] INFO org.eclipse.jetty.server.ServerConnector - Started ServerConnector@eeaf583{HTTP/1.1}{127.0.0.1:8888}
                  15273 [main] INFO org.eclipse.jetty.server.Server - Started @21088ms
                  [WARN] No startup URLs supplied and no plausible ones found -- use -startupUrl
                  Linking modules
                  Bootstrap link for command-line module 'com.citi.sevi.web.SEWeb'
                  Linking module 'seweb'
                  Invoking Linker Cross-Site-Iframe
                  Ignoring the following script tags in the gwt.xml file
                  sc/skins/fleet/load_skin.js
                  
                  Invoking Linker SmartGwtScriptInjector
                  Creating loadScriptTagFiles.js to manually load the following script tags:
                  sc/skins/fleet/load_skin.js
                  GET /recompile/seweb
                  Job com.citi.sevi.web.SEWeb_1_0
                  starting job: com.citi.sevi.web.SEWeb_1_0
                  binding: user.agent=safari
                  Compiling module com.citi.sevi.web.SEWeb
                  Unification traversed 598 fields and methods and 175 types. 0 are considered part of the current module and 5 had all of their fields and methods traversed.
                  Compiling 1 permutation
                  Compiling permutation 0...
                  Linking per-type JS with 0 new/changed types.
                  Source Maps Enabled
                  Compile of permutations succeeded
                  Compilation succeeded -- 5.644s
                  Linking into C:\Users\jj96228\AppData\Local\Temp\gwt-codeserver-2194382757187084275.tmp\com.citi.sevi.web.SEWeb\compile-2\war\seweb; Writing extras to C:\Users\jj96228\AppData\Local\Temp\gwt-codeserver-2194382757187084275.tmp\com.citi.sevi.web.SEWeb\compile-2\extras\seweb
                  Invoking Linker Cross-Site-Iframe
                  Ignoring the following script tags in the gwt.xml file
                  sc/skins/fleet/load_skin.js
                  
                  Invoking Linker SmartGwtScriptInjector
                  Creating loadScriptTagFiles.js to manually load the following script tags:
                  sc/skins/fleet/load_skin.js
                  Link succeeded
                  Linking succeeded -- 13.362s
                  29.663s total -- Compile completed
                  GET /seweb/style.css
                  Sent error page: not found: C:\Users\jj96228\AppData\Local\Temp\gwt-codeserver-2194382757187084275.tmp\com.citi.sevi.web.SEWeb\compile-2\war\seweb\style.css.gz
                  Bookmarks aren't required for SDM in GWT 2.7+, only for GWT 2.6. When running in SDM, your browser should show the Java from your project in the "source" pane and allow you to place breakpoints. When these are hit, you'll be able to step through the source, though since it's executing JS under the hood, access to local variables may be limited, depending on the browser.

                  We really can't provide detailed, low-level assistance to you through this forum. You might want to consider paid support to resolve your issue. We'd also like to repeat that you try importing the BuiltInDS project and see whether that works properly for you in SDM.

                  Comment


                    #10
                    Hi Admin,
                    I used only one smargwt import (nothemenoscript )in the module.gwt.xml and then i added the scripts manually in the bootload html. The super dev mode started working, The debugger stopped on the bookmark, but the only challenge now is , am yet to figure out how to use the Super Dev mode by checking value of variables at each point. I am able to use the classic dev mode too. So juggling to between both to progress. Thanks for you help.

                    Comment

                    Working...
                    X