GWT Project fails to launch in Dev mode from Intellij 12 - gwt

I have just installed an eveluation version of Intellij IDEA 12 to have a play with the new features.
I'm having difficulty getting my GWT project to run in Dev mode. It's failing with the following error:
[ERROR] Unable to load class 'com.google.gwt.useragent.rebind.UserAgentPropertyGenerator'
java.lang.ClassNotFoundException: com.google.gwt.useragent.rebind.UserAgentPropertyGenerator
this same project runs perfectly with Intellij 9 so I don't think it's my project that's at fault, presumably there is a configuration option in 12 which I need to set.
I am using Java 6 and GWT 2.4
Any clues would be apprieciated, for now I'm going back to Intellij 9.

Related

WFLYSRV0177: Error getting reflective information for class

I am developing a JEE project using Eclipse JEE (2019-09), Maven, Wildfly 17, JSF, PrimeFaces 7.0 running on Ubuntu 18.04.
My project used to compile, deploy and run on the WildFly 17 server until today. However, because I recieved strange errors when debugging, I installed an earlier Eclipse IDE to try to run my project on it.
After installing the older version of Eclipse (2019-03) in its own dedicated workspace, I got this error message when deploying my application to WildFly:
Caused by: java.lang.RuntimeException: WFLYSRV0177: Error getting reflective information for class
I then switched back to my initial Eclipse JEE (2019-09) Version, but then I kept recieving the same error message upon deploying.
I' ve searched the internet and found these two similar problems:
Error getting reflective information for class
Wildfly: Error getting reflective information for class
but actually not a solution to my problem.
Could somebody please help?
The problem was that the Maven jar- dependencies were not added to the WEB-INF/lib path.
Actually, in the deployed .war file the folder WEB-INF/lib was completely missing.
I fixed the problem by right-mouse click on my project in Eclipse, then "Properties", then "Deployment Assembly".
I added the missing entry "Maven Dependencies" as follows:
1.) BEFORE MY FIX:
2.) AFTER MY FIX:

Error importing SBT project in IntelliJ / no src folder appears

I'm new to working with both IntelliJ and Scala, so I've been trying to set up a basic HelloWorld project using it. However once I try to load the project I'm met with two problems
I get an error saying there was an "Error while importing SBT project"
No 'src' folder appears on the project tree
I've seen similar problems here and here, but I still can't get the project to load properly.
For some reason this site doesn't let you post an image until you have 10 reputation, so here is a link to the error message I'm receiving http://i.imgur.com/vDZB6SA.png.
From the looks of it, it seems like it's unable to download the necessary dependencies, however I was able to download the scala plugin earlier, so I can't see why there would be a problem now.
I tried following the advice here on updating the proxy settings, but that doesn't work either.
Has anyone encountered a similar problem? I'm really stuck here on how to proceed.
EDIT 1:
Details on IntelliJ
IntelliJ IDEA 2016.2.3
Build #IC-162.1812.17, built on August 30, 2016
JRE: 1.8.0_65-b17 amd64
JVM: Java HotSpot(TM) 64-Bit Server VM by Oracle Corporation
Setting up the proejct:
I just followed an example and went to New Project > Scala > SBT > name project and finish. Then once it loads I get the error displayed in the picture above. The SBT version is 0.13.8 and the Scala version is 2.11.8

Trying to install SBT-0.13.8 for Windows 7 installs SBT version 0.12.4

I have (multiple times) tried to install SBT-0.13.8 from the SBT download page via the SBT-0.13.8-MSI button and I always end up getting an SBT version which shows the following output
Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=256m; support was removed in 8.0
[info] Loading project definition from C:\Users\Tina\Desktop\example\project\project
error: error while loading CharSequence, class file 'C:\Program Files\Java\jre1.
8.0_20\lib\rt.jar(java/lang/CharSequence.class)' is broken (bad constant pool tag 15 at byte 1470)
[error] Type error in expression
Project loading failed: (r)etry, (q)uit, (l)ast, or (i)gnore? i
[warn] Ignoring load failure: no project loaded.
> about
[info] This is sbt 0.12.4
[info] No project is currently loaded
[info] sbt, sbt plugins, and build definitions are using Scala 2.9.2
SBT produces an error message and (!) shows itself as version 0.12.4.!!!
I really made sure that I have no other version of SBT installed and I even made a reboot before re-installing it but nothing changed. SBT files have a creation date of March, 21, 2015. This seems to be the newest version but why does this version show up as 0.12.4 and does not work with JDK1.8?
Looks like the directory you're in is wrong, you want to launch sbt from C:\Users\Tina\Desktop\example\project not C:\Users\Tina\Desktop\example\project\project (note 1 project less).
The second problem you're having is you're trying to use sbt 0.12.4 with Java 8. sbt 0.12.4 uses (as can be seen from the output) Scala 2.9.2 which doesn't work with Java 8. I would recommend migrating to sbt 0.13.8, but if not you could always downgrade to Java 7.
Edit after comments below
The progfun Coursera course download is still configured with sbt
0.12.4 which you're having trouble building because you are using Java 8.
I had a quick go at trying to see if upgrading the project to 0.13.8 would work (FYI it involves editing project/build.properties), but then plugins need to be upgraded, then meta-build code needed to be changed because of namespace changes..
Unless you're willing to experiment more and work you're way through the various changes required to use latest sbt and latest Java (which is what I would do if this were for myself), I would recommend as an alternative to:
Downgrade to Java 7
Notify the relevant people involved in running the course that the source material should be updated as it demonstrably does not work on latest, stable Java.
If your default Java is Java 8 but you want to switch to Java 7 for this out-of-date project setup, you need to create an .sbtopts file at the root of the project containing (note: on separate lines!):
-java-home
C:\Users\Tina\PATH\TO\YOUR\JAVA\HOME

Scala Play 2.3 InteliJ 14 *community edition - is it possible to run project without cmd line activator command

From http://blog.jetbrains.com/scala/2012/12/28/a-new-way-to-compile/ I understand that Intellij is using sbt to build - so thats 1x build
At the moment I run a separate command line task to run my project -
./activator -jvm-debug 5000 -Dhttp.port=9000
So each code change gets compiled twice (once by InteliJ; once by activator)
Is there a way to use the InteliJ build artifacts when I run, so the code is only compiled once?
Is using the Terminal window in InteliJ any different from a normal terminal window?
The versions I'm at are:
Java 7
Play framework 2.3.4
SBT 0.13.1
InteliJ 14 (community edition)
Thanks
Brent
Yes it's definitelly possible.
Install Play 2.x plugin (with dependencies) and add the run configuration dedicated for Play 2 (note in Intellij 14 Play2 support is combined within the Scala plugin)
Menu > Run > Edit configurations... > Add new configuration (plus icon in the corner) > Play 2 App
After saving you will be able to run your app (also in debug mode) within IntelliJ - i.e. via
Menu > Run > Debug 'Your Project'
btw, you can remove Make (before launch) from there, SBT should handle builds properly without Idea's support
See sample shot

IntelliJ 14 Scala Editor showing errors

I've just uninstalled IntelliJ 13 and installed 14 (community edition). I set up jdk, and then installed the Scala plugin, and created a new Scala > SBT project. It asked me to setup the Scala SDK which I did. I let it autoimport, and it created the src. etc folders. I then created a scala class. It compiles and runs fine. However, IntelliJ shows built in scala stuff as errors. For example:
For some reason, intellij is showing all scala library stuff as errors. However, the program compiles and runs fine. Has anybody else come across this?