Announcement

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

    Got sample built-in-ds to work, but if add one component like TreeGrid and required import, GWT compile fails with: No source code is available for type com.smartgwt.client.widgets.tree.TreeGrid

    I got the build-in-ds sample/example to work, running in Eclipse, using SMART GWT 6.1. I can't add to the example though, because if I go ahead and add a component, say:

    import com.smartgwt.client.widgets.tree.TreeGrid; // which works, Eclipse Jee Oxygen finds it

    and then declare a TreeGrid, e.g.
    final TreeGrid treeGrid = new TreeGrid();

    the GWT Compile subsequently fails:

    [ERROR] Line 47: No source code is available for type com.smartgwt.client.widgets.tree.TreeGrid; did you forget to inherit a required module?
    [ERROR] Hint: Check the inheritance chain from your module; it may not be inheriting a required module or a module may not be adding its source path entries properly

    I then investigated my associated BUILT_IN_DS_3.gwt.xml file, someone at Isomorphic asking if I modified/broke it, AND I DID NOT ... DID NOT EVEN KNOW ABOUT IT.

    DO I NEED TO ADD SOMETHING TO THIS .gwt.xml file for it to work, the contents of it currently are:

    <?xml version="1.0" encoding="UTF-8"?>
    <!--
    When updating your version of GWT, you should also update this DTD reference,
    so that your app can take advantage of the latest GWT module capabilities.
    -->
    <!DOCTYPE module PUBLIC "-//Google Inc.//DTD Google Web Toolkit 2.8.1//EN"
    "http://gwtproject.org/doctype/2.8.1/gwt-module.dtd">
    <module rename-to='built_in_ds_3'>
    <!-- Inherit the core Web Toolkit stuff. -->
    <inherits name='com.google.gwt.user.User'/>

    <!-- Inherit the default GWT style sheet. You can change -->
    <!-- the theme of your GWT application by uncommenting -->
    <!-- any one of the following lines. -->
    <inherits name='com.google.gwt.user.theme.clean.Clean'/>
    <!-- <inherits name='com.google.gwt.user.theme.standard.Standard'/> -->
    <!-- <inherits name='com.google.gwt.user.theme.chrome.Chrome'/> -->
    <!-- <inherits name='com.google.gwt.user.theme.dark.Dark'/> -->

    <!-- Other module inherits -->

    <!-- Specify the app entry point class. -->
    <entry-point class='com.smartgwt.sample.client.BUILT_IN_DS_3'/>

    <!-- Specify the paths for translatable code -->
    <source path='client'/>
    <source path='shared'/>

    <!-- allow Super Dev Mode -->
    <add-linker name="xsiframe"/>
    </module>





    Last edited by rknotes; 10 Aug 2017, 10:34.

    #2
    The .gwt.xml file you show has no imports of SmartGWT libraries at all, so it would never have worked. After you had things working, you either overwrote the .gwt.xml file we ship with the sample with this one, or some tool you are using did so. Return to the .gwt.xml we ship with the sample to have things work again.

    Be sure to also read the QuickStart Guide and Installation Instructions.

    Comment


      #3
      Thanks. Please note I followed the QuickStart Guide, and have not tried anything odd like editing the .gwt.xml file. You are correct: it is somehow changed from what you ship in your example, but I did not change it, and stranger still, it works with BUILT_IN_DS. In case you are curious, please see screen shot of Eclipse Environment, and which shows all main components including successful GWT compile.

      And then, a single change, adding the TreeGrid declaration, breaking the compile. Again, please note I haven't tried any "monkey business", just trying to expand beyond the basic example. I guess the mystery is:

      1) what's changing the .gwt.xml file (not me directly)
      2) how does the BUILT_IN_DS example compile, and then the single line inclusion of TreeGrid, break it?

      You are undoubtedly more qualified to answer this question than I am; I downloaded the latest Eclipse fresh/from scratch. After this post, I will force copy in the original gwt.xml file, and post a new reply so we have more to look at. Thanks for your support.

      Click image for larger version

Name:	no-tree-grid.PNG
Views:	643
Size:	267.1 KB
ID:	248415

      AND THEN NOW, A SINGLE CHANGE, UNCOMMENTING LINE 47:



      Click image for larger version

Name:	with-tree-grid.PNG
Views:	539
Size:	269.9 KB
ID:	248416


      Comment


        #4
        Making that change, both the GWT compile and link were successful:

        Click image for larger version

Name:	tree-grid-with-changes-back-to-gwt-xml.PNG
Views:	569
Size:	291.3 KB
ID:	248418
        Here's the full compilation and link results:

        Aug 15, 2017 4:49:21 PM java.util.prefs.WindowsPreferences <init>
        WARNING: Could not open/create prefs root node Software\JavaSoft\Prefs at root 0x80000002. Windows RegCreateKeyEx(...) returned error code 5.
        Compiling module com.smartgwt.sample.BUILT_IN_DS_3
        Ignored 2 units with compilation errors in first pass.
        Compile with -strict or with -logLevel set to DEBUG or WARN to see all errors.
        Compiling 5 permutations
        Compiling permutation 0...
        Compiling permutation 1...
        Compiling permutation 2...
        Compiling permutation 3...
        Compiling permutation 4...
        Compile of permutations succeeded
        Compilation succeeded -- 66.618s
        Linking into C:\Users\Reto\eclipse-workspace\BUILT-IN-DS-3\war\built_in_ds_3
        Invoking Linker Cross-Site-Iframe
        Ignoring the following script tags in the gwt.xml file
        sc/initsc.js
        sc/modules/ISC_Core.js?isc_version=11.1p_2017-07-09.js
        sc/modules/ISC_Foundation.js?isc_version=11.1p_2017-07-09.js
        sc/modules/ISC_Containers.js?isc_version=11.1p_2017-07-09.js
        sc/modules/ISC_Grids.js?isc_version=11.1p_2017-07-09.js
        sc/modules/ISC_Forms.js?isc_version=11.1p_2017-07-09.js
        sc/modules/ISC_RichTextEditor.js?isc_version=11.1p_2017-07-09.js
        sc/modules/ISC_Calendar.js?isc_version=11.1p_2017-07-09.js
        sc/modules/ISC_DataBinding.js?isc_version=11.1p_2017-07-09.js
        sc/skins/Enterprise/load_skin.js

        Invoking Linker SmartGwtScriptInjector
        Creating loadScriptTagFiles.js to manually load the following script tags:
        sc/initsc.js
        sc/modules/ISC_Core.js?isc_version=11.1p_2017-07-09.js
        sc/modules/ISC_Foundation.js?isc_version=11.1p_2017-07-09.js
        sc/modules/ISC_Containers.js?isc_version=11.1p_2017-07-09.js
        sc/modules/ISC_Grids.js?isc_version=11.1p_2017-07-09.js
        sc/modules/ISC_Forms.js?isc_version=11.1p_2017-07-09.js
        sc/modules/ISC_RichTextEditor.js?isc_version=11.1p_2017-07-09.js
        sc/modules/ISC_Calendar.js?isc_version=11.1p_2017-07-09.js
        sc/modules/ISC_DataBinding.js?isc_version=11.1p_2017-07-09.js
        sc/skins/Enterprise/load_skin.js
        Link succeeded
        Linking succeeded -- 42.766s

        Comment


          #5
          please see posts above, somehow added in wrong place. I deleted everything, unable to get things running still.

          Your README file tries to address various versions of things all at the same time, instead of ideally providing how to set things up using the latest downloads, etc., and then if needed, ones before that. As such, it's a user drudgery to try to get something running ... painful, just to start trying to do some engineering, making the user have to sort through various versions and confusing. Would you please, please list the correct instructions here, using all the latest GWT with Eclipse components. A user does not want to have to dig through trying to carefully understand WHAT GWT USED TO BE AND WHAT IT MIGRATED INTO, and how to get your software working.
          Last edited by rknotes; 15 Aug 2017, 16:33.

          Comment


            #6
            Here's what I get when I try import the project the way your instructions suggest, using the specifically added in GWT Compile, please see circled area of photo for where the GWT drop-down is:
            Click image for larger version

Name:	imporiting-project-as-indicated.PNG
Views:	567
Size:	152.7 KB
ID:	248421

            Comment


              #7


              Here, following the README steps:

              - Create a launch configuration and launch the app as described here: https://developers.google.com/eclips..._debugging_2_0

              This link then shows the following choice, Web Application choice:

              Click image for larger version  Name:	supposed-web-application-choice.PNG Views:	2 Size:	88.9 KB ID:	248423


              BUT APPARENTLY THAT NO LONGER EXISTS, HERE ARE THE CHOICES I GET:

              Click image for larger version  Name:	run-configuration-choices.PNG Views:	3 Size:	140.1 KB ID:	248427

              IF I THEN PICK GWT DEVELOPMENT MODE, THIS IS WHAT I GET:

              Click image for larger version  Name:	project-does-not-use-GWT.PNG Views:	1 Size:	94.7 KB ID:	248428

              IS THE README HENCE LACKING FOR THE LATEST GWT TOOLS / PROCESS?




              FYI:

              Click image for larger version  Name:	eclipse-version.PNG Views:	2 Size:	84.4 KB ID:	248430


              so, as far as I can tell README does not work, below is are no Java compilation problems, BUT NO CHOICE FOR WEB APPLICATION, AND GWT CHOICE DOES NOT WORK.


              Click image for larger version

Name:	no-java-compile-issues.PNG
Views:	639
Size:	253.5 KB
ID:	248431
              Attached Files
              Last edited by rknotes; 15 Aug 2017, 17:27.

              Comment


                #8
                Have you read the help topic "Troubleshooting SuperDevMode"?

                Try using File >> Import >> Existing Projects into Workspace to import the project. That's verified as working with Eclipse Luna. Our instructions don't refer to the "GWT drop down."

                Comment


                  #9
                  With the new GWT Plugin v3, you'll want to create a Run Configuration under "GWT Development Mode (DevMode)" rather than "Web Application", but once inside that configuration things look mostly the same. There is still a radio toggle for selecting SDM vs. "Classic" Dev Mode. Importing and running a project should (otherwise) work as we describe.

                  Have you configured at least one GWT SDK version inside Eclipse for it to use (e.g. GWT SDK 2.8.1)? (This is under Preferences >> GWT >> GWT Settings.) Otherwise no project will be considered a GWT project.

                  Comment


                    #10
                    Originally posted by Isomorphic View Post
                    With the new GWT Plugin v3, you'll want to create a Run Configuration under "GWT Development Mode (DevMode)" rather than "Web Application", but once inside that configuration things look mostly the same. There is still a radio toggle for selecting SDM vs. "Classic" Dev Mode. Importing and running a project should (otherwise) work as we describe.

                    Have you configured at least one GWT SDK version inside Eclipse for it to use (e.g. GWT SDK 2.8.1)? (This is under Preferences >> GWT >> GWT Settings.) Otherwise no project will be considered a GWT project.
                    This is how the GWT settings are/were set:

                    Click image for larger version

Name:	gwt-settings.PNG
Views:	596
Size:	43.7 KB
ID:	248461

                    Comment


                      #11
                      Originally posted by Isomorphic View Post
                      Have you read the help topic "Troubleshooting SuperDevMode"?

                      I did read specifically the link Using GWT with Eclipse referred to in Super Dev Mode in GWT 2.7.0+. I can't get anything running yet. Have you tried these steps with the latest/current available tools/eclipse/GWT?

                      Per: Try using File >> Import >> Existing Projects into Workspace to import the project. That's verified as working with Eclipse Luna. Our instructions don't refer to the "GWT drop down."
                      Which Wizard do you recommend:


                      Click image for larger version

Name:	import-wizards.PNG
Views:	525
Size:	53.4 KB
ID:	248463

                      Comment


                        #12
                        Hi,

                        Isomorphic meant "Existing Projects into Workspace", #2 in your list under "General".

                        Best regards
                        Blama

                        Comment


                          #13
                          Per the last post, the choice

                          To create a Web Application, select File > New > Web Application Project from the Eclipse menu

                          as described in Super Dev Mode in GWT 2.7.0+ => Using GWT with Eclipse is and the selection popup appears to be out of date now. It is now: GWT Application / GWT Web Application Project, which provides the next menu/popup:


                          Click image for larger version

Name:	GWT Web application project.PNG
Views:	709
Size:	43.3 KB
ID:	248466

                          This appears to be the same popup as using the two item GWT Dropdown menu , and while this could compile and link with the existing BUILT-IN-DS, able to locate it via the package name, I could not get it to run adding new components such as TreeGrid, even though I added "inherits" to the *.gwt.*xml file:

                          <inherits name="com.smartgwt.tools.SmartGwtTools"/>
                          <inherits name="com.smartgwtee.tools.Tools"/>
                          <inherits name="com.smartgwtee.SmartGwtEE"/>

                          It would compile and link, but not run.




                          Last edited by rknotes; 16 Aug 2017, 13:25.

                          Comment


                            #14
                            To reiterate, use File >> Import >> Existing Projects into Workspace to import the project from the SGWT download bundle, as Blama pointed out to you above. Don't use File >> New - let's resolve the original issue you reported before jumping to any other.

                            We verified that with a fresh installation of Eclipse Neon, and GWT Eclipse Plugin v3, we are able to import the BuiltInDS Project, add a TreeGrid to it, and run it. The only extra step with Plugin v3 that you may need to take is to tick the "Use GWT" box in the Project Preferences under GWT >> General Settings. We'll see if we can update the project in the SGWT download bundles to automatically set that box, but you should have no problem following that simple instruction by hand to solve your issue.

                            Remember as per post #9 that the Run Configuration with Plugin v3 should be created under "GWT Development Mode (DevMode)", as "Web Application" won't be listed.

                            When you follow these instructions to import, configure, and run BuiltInDS, does it now work for you as it does for us?

                            Comment


                              #15
                              I did File >> Import >> Existing Projects into Workspace as you indicated.


                              When I do Run Configurations => GWT Development Mode, I still get "Project does not use GWT". Under: Project Preferences under GWT >> General Settings, I have:

                              Click image for larger version  Name:	gwt-settings.PNG Views:	2 Size:	43.7 KB ID:	248473

                              Here is the result:

                              Click image for larger version

Name:	project-does-not-use-gwt-.PNG
Views:	489
Size:	178.0 KB
ID:	248475




                              Attached Files

                              Comment

                              Working...
                              X