I have a spring-vaadin project using vaadin addons and a gradle configuration. Adding V-Leaflet to my project worked the first time, but later it broke and the widgetset never compiled again. The compilation fails reporting it can't find jackson:
:vaadinPluginVersionCheck SKIPPED
:compileJava
:vaadinUpdateWidgetset
:processResources UP-TO-DATE
:classes
:vaadinClassPathJar UP-TO-DATE
:vaadinCompile
Errors in 'org/vaadin/addon/leaflet/shared/Point.java'
Line 37: JsonValue cannot be resolved to a type
Line 3: The import com.fasterxml cannot be resolved
Aborting compile due to errors in some input files
FAILED
Here is the relevant section in the gradle dependencies section:
compile 'com.fasterxml.jackson.core:jackson-core:2.9.7'
compile 'com.fasterxml.jackson.core:jackson-annotations:2.9.7'
vaadinCompile 'org.peimari:g-leaflet:+' //For v-leaflet
compile 'org.vaadin.addon:v-leaflet:+' //For map fields
I have already tried using vaadinCompile, compile and implementation for all of them.
I have solved this.
I don't know exactly what happened but I solved it by updating everything and removing direct access to transitive dependencies within the vaadinCompile
step.
The final gradle script is:
vaadinCompile 'org.vaadin.addon:v-leaflet:2.0.9'
compile 'org.vaadin.addon:v-leaflet:2.0.9'
Only adding the vaadinCompile part solved the issue for the jar and running from gradle, but I had to add the compile directive also, so that eclipse could find v-leaflet classes on the classpath.