GWT problem

Hello all!

I use Eclipse Java EE IDE for Web Developers.

Version: Helios Release
Build id: 20100617-1415

When I have changed vaadin version from 6.5.7 to 6.6.0, I began to receive error messages during compilation widgetset

I have found these classes (interfaces) (javax.validation.ConstraintViolation) in gwt/gwt-servlet-deps.jar and have added this packet to “Java Build Path” in my project,but it hasn’t helped.

As it is possible to solve this problem. Thanks

See
this message
.

If you upgrade the Vaadin version from “Project Properties → Vaadin” with the latest (Tuesday this week) Vaadin Plug-in for Eclipse, you should not need to do any modifications to the build path by hand.

Note, though, that if you have set up the GWT JARs etc. by hand on the build path, the plug-in will download the new versions but will not update the references to those JARs on the project build path.

Thanks for your councils. Has understood
Yours faithfully, Pavel.

I upgraded Vaadin to 6.7.6 and got a GWT2.3

While trying to compile a widget set I am having the problem.
All the gwt dependencies are in classpath, so it’s not seemed to be a problem

Here is the error:

Compiling widgetset test.management.widgetset.ReporterWidgetset
Updating GWT module description file…
27-Mar-2012 1:30:18 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getAvailableWidgetSets
INFO: Widgetsets found from classpath:
org.vaadin.peter.multibutton.MultibuttonWidgetset in jar:file:C:/automation/catsManagementLibs/1.0.0/MultiButton2.0.1.jar!/
com.vaadin.terminal.gwt.DefaultWidgetSet in jar:file:C:/automation/catsManagementLibs/1.0.0/vaadin-6.7.6.jar!/
test.management.widgetset.ReporterWidgetset in file://C/Users/aboguslavsky/Perforce/perforce.dev.bluecatnetworks.corp_1666/p4_workspace/qa/automation/framework/Reporter/src

27-Mar-2012 1:30:18 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getAvailableWidgetSets
INFO: Search took 3ms
Done.
Starting GWT compiler
Compiling module test.management.widgetset.ReporterWidgetset
Validating newly compiled units
[ERROR]
Errors in ‘jar:file:/C:/automation/catsManagementLibs/1.0.0/gwt-user.jar!/com/google/gwt/editor/client/EditorDriver.java’
[ERROR]
Line 20: The import javax.validation.ConstraintViolation cannot be resolved
[ERROR]
Line 97: ConstraintViolation cannot be resolved to a type
[ERROR]
Errors in ‘jar:file:/C:/automation/catsManagementLibs/1.0.0/gwt-user.jar!/com/google/gwt/editor/client/impl/AbstractSimpleBeanEditorDriver.java’
[ERROR]
Line 28: Name clash: The method setConstraintViolations(Iterable<ConstraintViolation<?>>) of type BaseEditorDriver has the same erasure as setConstraintViolations(Iterable>) of type EditorDriver but does not override it
[ERROR]
Errors in ‘jar:file:/C:/automation/catsManagementLibs/1.0.0/gwt-user.jar!/com/google/gwt/editor/client/impl/BaseEditorDriver.java’
[ERROR]
Line 31: The import javax.validation.ConstraintViolation cannot be resolved
[ERROR]
Line 67: ConstraintViolation cannot be resolved to a type
[ERROR]
Errors in ‘jar:file:/C:/automation/catsManagementLibs/1.0.0/gwt-user.jar!/com/google/gwt/editor/client/impl/SimpleViolation.java’
[ERROR]
Line 25: The import javax.validation.ConstraintViolation cannot be resolved
[ERROR]
Line 40: ConstraintViolation cannot be resolved to a type
[ERROR]
Line 43: ConstraintViolation cannot be resolved to a type
[ERROR]
Line 44: Missing code implementation in the compiler
[ERROR]
Line 49: ConstraintViolation cannot be resolved to a type
[ERROR]
Line 49: Missing code implementation in the compiler
[ERROR]
Line 70: ConstraintViolation cannot be resolved to a type
[ERROR]
Line 72: ConstraintViolation cannot be resolved to a type
[ERROR]
Line 73: ConstraintViolation<?> cannot be resolved to a type [ERROR] Line 77: ConstraintViolation cannot be resolved to a type
[ERROR]
Line 81: ConstraintViolation<capture#3-of ?> cannot be resolved to a type
[ERROR]
Line 89: ConstraintViolation<capture#4-of ?> cannot be resolved to a type
[ERROR]
Line 93: ConstraintViolation<capture#5-of ?> cannot be resolved to a type
[ERROR]
Line 98: ConstraintViolation cannot be resolved to a type
[ERROR]
Errors in ‘jar:file:/C:/automation/catsManagementLibs/1.0.0/gwt-user.jar!/com/google/gwt/editor/client/testing/MockSimpleBeanEditorDriver.java’
[ERROR]
Line 26: The import javax.validation.ConstraintViolation cannot be resolved
[ERROR]
Line 35: The type MockSimpleBeanEditorDriver<T,E> must implement the inherited abstract method EditorDriver.setConstraintViolations(Iterable<ConstraintViolation<?>>) [ERROR] Line 107: Name clash: The method setConstraintViolations(Iterable>) of type MockSimpleBeanEditorDriver<T,E> has the same erasure as setConstraintViolations(Iterable<ConstraintViolation<?>>) of type EditorDriver but does not override it
[ERROR]
Line 108: ConstraintViolation cannot be resolved to a type
[ERROR]
Errors in ‘jar:file:/C:/automation/catsManagementLibs/1.0.0/gwt-user.jar!/javax/validation/super/javax/validation/Configuration.java’
[ERROR]
Line 93: TraversableResolver cannot be resolved to a type
[ERROR]
Line 105: ConstraintValidatorFactory cannot be resolved to a type
[ERROR]
Line 182: TraversableResolver cannot be resolved to a type
[ERROR]
Line 182: No source code is available for type TraversableResolver; did you forget to inherit a required module?
[ERROR]
Line 194: ConstraintValidatorFactory cannot be resolved to a type
[ERROR]
Line 194: No source code is available for type ConstraintValidatorFactory; did you forget to inherit a required module?
[ERROR]
Line 202: ValidatorFactory cannot be resolved to a type
[ERROR]
Line 202: No source code is available for type ValidatorFactory; did you forget to inherit a required module?
[ERROR]
Errors in ‘jar:file:/C:/automation/catsManagementLibs/1.0.0/gwt-user.jar!/javax/validation/ConstraintViolationException_CustomFieldSerializer.java’
[ERROR]
Line 30: ConstraintViolationException cannot be resolved to a type
[ERROR]
Line 34: ConstraintViolationException cannot be resolved to a type
[ERROR]
Line 34: No source code is available for type ConstraintViolationException; did you forget to inherit a required module?
[ERROR]
Line 39: ConstraintViolation cannot be resolved to a type
[ERROR]
Line 39: ConstraintViolation cannot be resolved to a type
[ERROR]
Line 40: ConstraintViolationException cannot be resolved to a type
[ERROR]
Line 44: ConstraintViolationException cannot be resolved to a type
[ERROR]
Errors in ‘jar:file:/C:/automation/catsManagementLibs/1.0.0/gwt-user.jar!/javax/validation/super/javax/validation/MessageInterpolator.java’
[ERROR]
Line 21: The import javax.validation.metadata cannot be resolved
[ERROR]
Line 66: ConstraintDescriptor cannot be resolved to a type
[ERROR]
Errors in ‘jar:file:/C:/automation/catsManagementLibs/1.0.0/gwt-user.jar!/javax/validation/super/javax/validation/constraints/Pattern.java’
[ERROR]
Line 30: The import javax.validation.Constraint cannot be resolved
[ERROR]
Line 31: The import javax.validation.Payload cannot be resolved
[ERROR]
Line 49: Constraint cannot be resolved to a type
[ERROR]
Line 49: The attribute validatedBy is undefined for the annotation type Constraint
[ERROR]
Line 75: Payload cannot be resolved to a type
[ERROR]
Errors in ‘jar:file:/C:/automation/catsManagementLibs/1.0.0/gwt-user.jar!/javax/validation/super/javax/validation/spi/ConfigurationState.java’
[ERROR]
Line 22: The import javax.validation.ConstraintValidatorFactory cannot be resolved
[ERROR]
Line 24: The import javax.validation.TraversableResolver cannot be resolved
[ERROR]
Line 93: ConstraintValidatorFactory cannot be resolved to a type
[ERROR]
Line 107: TraversableResolver cannot be resolved to a type
Computing all possible rebind results for ‘com.google.gwt.user.client.UserAgentAsserter’
Rebinding com.google.gwt.user.client.UserAgentAsserter
Checking rule
[WARN]
Detected warnings related to ‘com.google.gwt.editor.client.SimpleBeanEditorDriver’. Are validation-api-.jar and validation-api--sources.jar on the classpath?
[WARN]
Unknown type ‘com.google.gwt.editor.client.SimpleBeanEditorDriver’ specified in deferred binding rule
27-Mar-2012 1:30:27 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getPaintablesHavingWidgetAnnotation
INFO: Searching for paintables…
27-Mar-2012 1:30:28 PM com.vaadin.terminal.gwt.widgetsetutils.ClassPathExplorer getPaintablesHavingWidgetAnnotation
INFO: Search took 629ms
Widgetset compilation completed

Please help

If compiling in Eclipse and the validation JARs are on the classpath, make sure you have the latest Vaadin Eclipse plug-in. I suspect that might be the issue.

I also have had compilation problems… sometimes I get a good run, other times I bang my head against the wall for ages… (I am also quite a newbie :-))

Currently I have the validation jars added via Maven.

Can I use the Vaadin Widget compilation in this case?

Practice would indicate no… as I still get the above errors this way (even if I also add the validation jars manually to the classpath as well - I have (as far as I can tell) the latest vaadin plugin - 2.0.1…).

It sure would be nice hitting the little compile widget toolbar button instead of having to remember the maven goals vaadin:update-widgetset and then gwt:compile (side note, in Eclipse, does the Run As > Maven Build… goals section button work for anyone else? Seems a rather pointless button to me.)

Just thought I would add this post in case another newbie using maven stumbles across it :slight_smile:

Regards
Colin

Could you
create an enhancement request
about this?

It might require a separate Vaadin Maven integration Eclipse plug-in, though, to avoid dependencies from the main plug-in to m2e/m2eclipse, so possibly not so small a change to make it trigger widgetset compilation if doing it using Maven.