GWT Compiler Error: No source code is available for type 'type...' did you forget to inherit a required module?

I have a GWT module that exists outside my main GWT app src location, but still inside the IDEA project.  For some reason, even though I've properly inherited the module in my main GWT.xml file, the compiler errors out with this message:

         Line 64: No source code is available for type com.mycompany.util.transactionlogging.TransactionLogType; did you forget to inherit a required module?


Now, that Enum class is in an IDEA Module called 'BaseUtil', which I have a dependency on in the IDEA module inspector.  Not only that, but I've also added the associated GWT module with:

    <inherits name="com.mycompany.util.TransactionLogging"/>


The compiler log even indicates that GWT is finding, and loading the module:

Loading inherited module 'com.mycompany.util.TransactionLogging'
   Module location: file:ROOT_DIR/myclient/build/classes/production/BaseUtil/com/mycompany/util/TransactionLogging.gwt.xml



And the TransactionLogging.gwt.xml file correctly references the source path:

     <module>
        <source path="transactionlogging"/>
    </module>

In other words, I believe I have hooked everything up correctly, but I still get a GWT compiler error.  

The interesting point is that my 'main' GWT module is located at this source path:


        file:ROOT_DIR/GWT/com/myclient/gwt/transaction/TransactionViewer.gwt.xml

and the dependent module is:

        file:ROOT_DIR/BaseUtil/com/mycompany/util/TransactionLogging.gwt.xml


Note how they are in different src paths.  One is GWT/com/myclient/..., and the other is BaseUtil/com/mycompany   (GWT vs BaseUtil, and 'myclient' vs 'mycompany').  I don't think any of this should matter since I've refererenced everything correctly in the IDEA module dependencies and the GWT module inherits.


If anyone has ideas on this please let me know.
          
3 comments
Comment actions Permalink

Let me reformat that message, it came out messy:


I have a GWT module that exists outside my main GWT app src location, but still inside the IDEA project.  For some reason, even though I've properly inherited the module in my main GWT.xml file, the compiler errors out with this message:


         Line 64: No source code is available for type com.mycompany.util.transactionlogging.TransactionLogType; did you forget to inherit a required module?


Now, that Enum class is in an IDEA Module called 'BaseUtil', which I have a dependency on in the IDEA module inspector.  Not only that, but I've also added the associated GWT

module with:


    <inherits name="com.mycompany.util.TransactionLogging"/>



The compiler log even indicates that GWT is finding, and loading the module:


    Loading inherited module 'com.mycompany.util.TransactionLogging'
    Module location: file:ROOT_DIR/myclient/build/classes/production/BaseUtil/com/mycompany/util/TransactionLogging.gwt.xml




And the TransactionLogging.gwt.xml file correctly references the source path:


     <module>
        <source path="transactionlogging"/>
     </module>



In other words, I believe I have hooked everything up correctly, but I still get a GWT compiler error.


The interesting point is that my 'main' GWT module is located at this source path:



        file:ROOT_DIR/GWT/com/myclient/gwt/transaction/TransactionViewer.gwt.xml


and the dependent module is:


        file:ROOT_DIR/BaseUtil/com/mycompany/util/TransactionLogging.gwt.xml




Note how they are in different src paths.  One is GWT/com/myclient/..., and the other is BaseUtil/com/mycompany   (GWT vs BaseUtil, and 'myclient' vs 'mycompany').  I don't think any of this should matter since I've refererenced everything correctly in the IDEA module dependencies and the GWT module inherits.


If anyone has ideas on this please let me know.
         
0
Comment actions Permalink

Do you have GWT facets in all modules containing GWT client code?

--
Nikolay Chashnikov
Software Developer
JetBrains, Inc
http://www.jetbrains.com
"Develop with pleasure!"

0
Comment actions Permalink

Yes, that was the problem.  I had to add a GWT facet to the other module that contained some dependent GWT code.  Thank you.

0

Please sign in to leave a comment.