Re: GWT compile fails with default Maven directory structure
On Friday, November 21, 2014 8:03:42 PM UTC+1, Thomas Broyer wrote: I can't tell for App Engine, but why would you want a GWT SDK? You're right, I was able to remove the GWT SDK plugin from Eclipse, and it still works using the one from my maven repository. That's not the case for GAE. If I remove it, I get the same error that I fixed yesterday by changing the build order to move my Maven Dependencies below everything else, as I mentioned earlier: GAE SDK /Users/.../.m2/repository/com/google/appengine/appengine-api-1.0-sdk/1.9.15/appengine-api-1.0-sdk-1.9.15.jar failed validation SDK location '/Users/.../.m2/repository/com/google/appengine/appengine-api-1.0-sdk/1.9.15/appengine-api-1.0-sdk-1.9.15.jar' is not a directory To get it working again, I need to: - Reinstall the GAE SDK from GPE - Change the project to use this SDK temporarily in Project Properties Google App Engine. The change won't persist, but it will add the GAE jars to your build classpath. - Again, move the Maven Dependencies below everything else in Project Properties Java Build Path Order and Export This is a GAE things, but I think more GWT users might run into this. So I can ask the GAE guys about it, but it looks like it's been an issue since at least 2011 https://groups.google.com/forum/#!searchin/google-appengine/SDK$20location$20is$20not$20a$20directory/google-appengine/owo4ZM0IiMs/UTOh4AZhQ-cJ, so maybe there's a reason why things are the way they are. Thanks! -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscr...@googlegroups.com. To post to this group, send email to google-web-toolkit@googlegroups.com. Visit this group at http://groups.google.com/group/google-web-toolkit. For more options, visit https://groups.google.com/d/optout.
Re: GWT compile fails with default Maven directory structure
When you use Maven and Eclipse, you import a Maven project (ou create one from within Eclipse), and the GPE detects the use of the gwt-maven-plugin and auto-configures itself, using the GWT dependencies from your Maven project rather than a GWT SDK (so you can really use any GWT version that's available in the Central Repository, whether it's available as an Eclipse plugin or not is irrelevant). I like launching DevMode using the GPE even when using Maven, because it's simpler and more integrated to Eclipse. On Friday, November 21, 2014 8:53:58 AM UTC+1, Phineas Gage wrote: On Friday, November 21, 2014 8:18:19 AM UTC+1, Thomas Broyer wrote: Sounds like a bug or misconfiguration of the GPE. Is the project a Maven project in Eclipse? There might be some hard-coded paths in the GPE (because of limitations of Eclipse) that are only triggered in one or the other mode (Maven vs. simple Eclipse project). E.g. /test being excluded from the GWT Compiler and DevMode classpath in simple projects, and the test sources (defaulting to src/test/java and src/test/resources), as declared in your Maven POM, in Maven projects. Also, this being a GPE issue, you might have better luck in the dedicated Google Group https://groups.google.com/d/forum/google-plugin-eclipse or on StackOverflow. It was created as a Google - Web Application Project. I think you have it here, it seems that when the source folder base name is 'test', it's excluded from the GWT Compiler, but that's not the case for the default Maven style directory structure. Just as a general question, do you keep the GPE installed when you use Maven? Where I'm heading is that maybe I only need GPE for the UiBinder auto-completion and editor features. Compiling, DevMode and testing can all be handled with Maven. GPE doesn't seem to keep up with GWT releases anyway. Thanks for the help... -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscr...@googlegroups.com. To post to this group, send email to google-web-toolkit@googlegroups.com. Visit this group at http://groups.google.com/group/google-web-toolkit. For more options, visit https://groups.google.com/d/optout.
Re: GWT compile fails with default Maven directory structure
On Friday, November 21, 2014 11:33:48 AM UTC+1, Thomas Broyer wrote: When you use Maven and Eclipse, you import a Maven project (ou create one from within Eclipse), and the GPE detects the use of the gwt-maven-plugin and auto-configures itself, using the GWT dependencies from your Maven project rather than a GWT SDK (so you can really use any GWT version that's available in the Central Repository, whether it's available as an Eclipse plugin or not is irrelevant). I like launching DevMode using the GPE even when using Maven, because it's simpler and more integrated to Eclipse. Thanks, that got me to where gwt:compile is working from the command line or GPE (save the test code path issue I posted about originally, which I'll go to GPE about). I'll work on running stuff later. Here are a few of the main hurdles I ran into: - I had to manually change the build order http://stackoverflow.com/questions/12107612/how-to-run-maven-project-on-google-app-engine/15314586#15314586 in Java Build Path - Order and Export to put my Maven Dependencies below everything else, which seems a little strange. - Where to put resources. I started with everything in src/main/resources to be Maven-like, but realized for GPE and compiling from maven to work, all stuff that needs to be processed by the GWT compiler needs to go in src/main/java. This was an entertaining read https://groups.google.com/forum/#!searchin/codehaus-mojo-gwt-maven-plugin-users/UiBinder/codehaus-mojo-gwt-maven-plugin-users/Y0dqogsT1Zw/QpSSkwO7CHIJ . - The MobileWebApp sample pom.xml https://gwt.googlesource.com/gwt/+/master/samples/mobilewebapp/pom.xml references the maven-gae-plugin, but it seems like that's been superseded by appengine-maven-plugin https://cloud.google.com/appengine/docs/java/tools/maven. - You still want separate GWT and app engine SDKs installed in Eclipse, even though you've also got them in your local maven repository. - In the end, I was better off starting a new Maven project from scratch then trying to migrate my existing one, especially with my connection to a local Subversion repository. Subclipse didn't handle the moves very well and my working copy got corrupted. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscr...@googlegroups.com. To post to this group, send email to google-web-toolkit@googlegroups.com. Visit this group at http://groups.google.com/group/google-web-toolkit. For more options, visit https://groups.google.com/d/optout.
Re: GWT compile fails with default Maven directory structure
On Friday, November 21, 2014 6:54:29 PM UTC+1, Phineas Gage wrote: - You still want separate GWT and app engine SDKs installed in Eclipse, even though you've also got them in your local maven repository. I can't tell for App Engine, but why would you want a GWT SDK? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscr...@googlegroups.com. To post to this group, send email to google-web-toolkit@googlegroups.com. Visit this group at http://groups.google.com/group/google-web-toolkit. For more options, visit https://groups.google.com/d/optout.
GWT compile fails with default Maven directory structure
I'm in the process of Maven-izing my GWT 2.6.1 project (an intermediate step to start using GWT 2.7.0), and as a first step want to switch to maven style directory structure (as suggested by the Maven GWT Plugin documentation http://mojo.codehaus.org/gwt-maven-plugin/user-guide/project.html), so I make two simple moves: [project]/src = [project]/src/main/java [project]/test = [project]/src/test/java But what happens when I do this is that the regular GWT Compile from the Google Plugin for Eclipse fails with the -strict option, because it tries to compile my test classes as GWT source code, and of course can't find the classes they reference, for example (source files names obfuscated with extra ...'s): [ERROR] Errors in 'file:/.../src/test/java/.../...Test.java' [ERROR] Line 20: No source code is available for type org.junit.Assert; did you forget to inherit a required module? (... repeated with many other files) I'm confused because this doesn't happen with my old directory structure, and I don't know why the GWT compiler would go back up into my test directory to compile classes there. Strangely, it also doesn't happen with this structure, which I accidentally moved to once: [project]/src = [project]/src/java/main [project]/test = [project]/src/java/test It almost seems like the GWT compiler is doing something special with the default Maven directory structure. And any of the solutions I can think of are not very clean: - Not use the Google Plugin for Eclipse, but only use the Maven GWT Plugin, but then I lose some features from the Google Plugin for Eclipse that I want - Not compile with -strict, but then I don't catch other warnings as easily - Use an exclude in my *.gwt.xml source paths to exclude **/*Test.java, but then I might still catch some unintended utility classes in my test package - Not use a parallel package structure for my tests, but then it's not possible to test package protected classes and methods - Not make [project]/src/test/java a source directory in Eclipse, but I don't know what the side effects of that are How are people handling this, or am I missing something? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscr...@googlegroups.com. To post to this group, send email to google-web-toolkit@googlegroups.com. Visit this group at http://groups.google.com/group/google-web-toolkit. For more options, visit https://groups.google.com/d/optout.
Re: GWT compile fails with default Maven directory structure
It sounds like you have non-gwt-capable classes in packages meant for GWT - is that deliberate? For example, test classes to make sure the various server components in your project work, but they are in your .client or .shared package? If they are not, then GWT will totally ignore them, as no .gwt.xml as indicated that those packages are able to be compiled at all. On Thursday, November 20, 2014 11:05:27 AM UTC-6, Phineas Gage wrote: I'm in the process of Maven-izing my GWT 2.6.1 project (an intermediate step to start using GWT 2.7.0), and as a first step want to switch to maven style directory structure (as suggested by the Maven GWT Plugin documentation http://mojo.codehaus.org/gwt-maven-plugin/user-guide/project.html), so I make two simple moves: [project]/src = [project]/src/main/java [project]/test = [project]/src/test/java But what happens when I do this is that the regular GWT Compile from the Google Plugin for Eclipse fails with the -strict option, because it tries to compile my test classes as GWT source code, and of course can't find the classes they reference, for example (source files names obfuscated with extra ...'s): [ERROR] Errors in 'file:/.../src/test/java/.../...Test.java' [ERROR] Line 20: No source code is available for type org.junit.Assert; did you forget to inherit a required module? (... repeated with many other files) I'm confused because this doesn't happen with my old directory structure, and I don't know why the GWT compiler would go back up into my test directory to compile classes there. Strangely, it also doesn't happen with this structure, which I accidentally moved to once: [project]/src = [project]/src/java/main [project]/test = [project]/src/java/test It almost seems like the GWT compiler is doing something special with the default Maven directory structure. And any of the solutions I can think of are not very clean: - Not use the Google Plugin for Eclipse, but only use the Maven GWT Plugin, but then I lose some features from the Google Plugin for Eclipse that I want - Not compile with -strict, but then I don't catch other warnings as easily - Use an exclude in my *.gwt.xml source paths to exclude **/*Test.java, but then I might still catch some unintended utility classes in my test package - Not use a parallel package structure for my tests, but then it's not possible to test package protected classes and methods - Not make [project]/src/test/java a source directory in Eclipse, but I don't know what the side effects of that are How are people handling this, or am I missing something? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscr...@googlegroups.com. To post to this group, send email to google-web-toolkit@googlegroups.com. Visit this group at http://groups.google.com/group/google-web-toolkit. For more options, visit https://groups.google.com/d/optout.
Re: GWT compile fails with default Maven directory structure
Sounds like a bug or misconfiguration of the GPE. Is the project a Maven project in Eclipse? There might be some hard-coded paths in the GPE (because of limitations of Eclipse) that are only triggered in one or the other mode (Maven vs. simple Eclipse project). E.g. /test being excluded from the GWT Compiler and DevMode classpath in simple projects, and the test sources (defaulting to src/test/java and src/test/resources), as declared in your Maven POM, in Maven projects. Also, this being a GPE issue, you might have better luck in the dedicated Google Group https://groups.google.com/d/forum/google-plugin-eclipse or on StackOverflow. On Thursday, November 20, 2014 6:05:27 PM UTC+1, Phineas Gage wrote: I'm in the process of Maven-izing my GWT 2.6.1 project (an intermediate step to start using GWT 2.7.0), and as a first step want to switch to maven style directory structure (as suggested by the Maven GWT Plugin documentation http://mojo.codehaus.org/gwt-maven-plugin/user-guide/project.html), so I make two simple moves: [project]/src = [project]/src/main/java [project]/test = [project]/src/test/java But what happens when I do this is that the regular GWT Compile from the Google Plugin for Eclipse fails with the -strict option, because it tries to compile my test classes as GWT source code, and of course can't find the classes they reference, for example (source files names obfuscated with extra ...'s): [ERROR] Errors in 'file:/.../src/test/java/.../...Test.java' [ERROR] Line 20: No source code is available for type org.junit.Assert; did you forget to inherit a required module? (... repeated with many other files) I'm confused because this doesn't happen with my old directory structure, and I don't know why the GWT compiler would go back up into my test directory to compile classes there. Strangely, it also doesn't happen with this structure, which I accidentally moved to once: [project]/src = [project]/src/java/main [project]/test = [project]/src/java/test It almost seems like the GWT compiler is doing something special with the default Maven directory structure. And any of the solutions I can think of are not very clean: - Not use the Google Plugin for Eclipse, but only use the Maven GWT Plugin, but then I lose some features from the Google Plugin for Eclipse that I want - Not compile with -strict, but then I don't catch other warnings as easily - Use an exclude in my *.gwt.xml source paths to exclude **/*Test.java, but then I might still catch some unintended utility classes in my test package - Not use a parallel package structure for my tests, but then it's not possible to test package protected classes and methods - Not make [project]/src/test/java a source directory in Eclipse, but I don't know what the side effects of that are How are people handling this, or am I missing something? -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscr...@googlegroups.com. To post to this group, send email to google-web-toolkit@googlegroups.com. Visit this group at http://groups.google.com/group/google-web-toolkit. For more options, visit https://groups.google.com/d/optout.
Re: GWT compile fails with default Maven directory structure
On Thursday, November 20, 2014 8:47:35 PM UTC+1, Colin Alworth wrote: It sounds like you have non-gwt-capable classes in packages meant for GWT - is that deliberate? For example, test classes to make sure the various server components in your project work, but they are in your .client or .shared package? If they are not, then GWT will totally ignore them, as no .gwt.xml as indicated that those packages are able to be compiled at all. Yes, I have my test classes in the same packages as the classes they test, but the test classes are in a different source directory. It's always been that way, and I like it because tests are easy to find and they have access to package protected classes and methods. -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscr...@googlegroups.com. To post to this group, send email to google-web-toolkit@googlegroups.com. Visit this group at http://groups.google.com/group/google-web-toolkit. For more options, visit https://groups.google.com/d/optout.
Re: GWT compile fails with default Maven directory structure
On Friday, November 21, 2014 8:18:19 AM UTC+1, Thomas Broyer wrote: Sounds like a bug or misconfiguration of the GPE. Is the project a Maven project in Eclipse? There might be some hard-coded paths in the GPE (because of limitations of Eclipse) that are only triggered in one or the other mode (Maven vs. simple Eclipse project). E.g. /test being excluded from the GWT Compiler and DevMode classpath in simple projects, and the test sources (defaulting to src/test/java and src/test/resources), as declared in your Maven POM, in Maven projects. Also, this being a GPE issue, you might have better luck in the dedicated Google Group https://groups.google.com/d/forum/google-plugin-eclipse or on StackOverflow. It was created as a Google - Web Application Project. I think you have it here, it seems that when the source folder base name is 'test', it's excluded from the GWT Compiler, but that's not the case for the default Maven style directory structure. Just as a general question, do you keep the GPE installed when you use Maven? Where I'm heading is that maybe I only need GPE for the UiBinder auto-completion and editor features. Compiling, DevMode and testing can all be handled with Maven. GPE doesn't seem to keep up with GWT releases anyway. Thanks for the help... -- You received this message because you are subscribed to the Google Groups Google Web Toolkit group. To unsubscribe from this group and stop receiving emails from it, send an email to google-web-toolkit+unsubscr...@googlegroups.com. To post to this group, send email to google-web-toolkit@googlegroups.com. Visit this group at http://groups.google.com/group/google-web-toolkit. For more options, visit https://groups.google.com/d/optout.