Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to fix [ERROR] Hint: Check that your module inherits 'com.google.gwt.core.Core'

I want to start a Web Development project with GWT in Eclipse. For that I am following the tutorial on http://www.gwtproject.org/doc/latest/tutorial/create.html

The form to create the Project does not exactly look like they explain. For example I cannot make a checkmark at "Use Google App Engine" since it does not exist. To get the build.xml I checkmarked the "Generate an Ant Project" field.

When I try to run the generated code, the following error occurs:

Turning off precompile in incremental mode.
Super Dev Mode starting up
workDir: /tmp/gwt-codeserver-9585554490549923267.tmp
2019-02-03 18:36:10.619:INFO::main: Logging initialized @879ms
Loading Java files in com.google.gwt.sample.stockwatcher.StockWatcher.
[ERROR] Hint: Check that your module inherits 'com.google.gwt.core.Core'      either directly or indirectly (most often by inheriting module 'com.google.gwt.user.User')

When I try to use the command line version of their tutorial, I get an 503 Error:

HTTP ERROR: 503

Problem accessing /StockWatcher.html. Reason:

    Service Unavailable

Powered by Jetty://

I use GWT SDK 2.8.1 and Java 10

I installed already lots of plugins for Eclipse, so that I am quite sure to have all plugins I need. Maybe this could be something with the Java version? Does anyone has an idea?

like image 363
HutzelFutzel Avatar asked Feb 03 '19 18:02

HutzelFutzel


2 Answers

  1. Check that your gwt.xml really inherits "com.google.gwt.user.User"
  2. Check java sdk. Some gwt versions work only with java 1.8
  3. If you use Idea, there was a bug, which also causes this error: https://youtrack.jetbrains.com/issue/IDEA-218731?_ga=2.120118728.1133270638.1599566675-1712334692.1566210515
like image 95
Gamzat Gimbatov Avatar answered Nov 14 '22 11:11

Gamzat Gimbatov


Use 1.8.0 JRE to compile the GWT application. You can setup this in eclipse as shown below.

enter image description here

Then try to compile the application you will get the following output in console.

Compiling module com.somshine.miniproject.MiniProject Compiling 5 permutations Compiling permutation 0... Compiling permutation 1... Compiling permutation 2... Compiling permutation 3... Compiling permutation 4... Compile of permutations succeeded Compilation succeeded -- 21.193s Linking into D:\Java\gwtProject\miniProject\war\miniproject Link succeeded Linking succeeded -- 0.426s

like image 23
Somnath Avatar answered Nov 14 '22 11:11

Somnath