Cannot build for production Vaadin 24

i tried clean & install, but always gives me this error:
Cannot invoke “java.lang.Class.isInterface()” because the return value of “org.reflections.Reflections.forClass(java.lang.String, java.lang.ClassLoader)” is null

i also tried to compile with --enable-preview, doesnt work. Java 17.

What Vaadin version are you using?

24.0.5

i didnt see it previously but i also have a runtime exception when i start the application


Caused by: java.lang.RuntimeException: no DevModeHandlerManager implementation found but but dev server enabled. Either disable by setting vaadin.frontend.hotdeploy=false (and run the build-frontend maven goal) or include the vaadin-dev-server dependency```

setting ```vaadin.frontend.hotdeploy=false

For the first error, if you upgrade to a recent Vaadin 24.0 version (e.g. 24.0.11) and run maven with -X flag, you should get additional information about the real error

For the second error try to set <frontendHotdeploy>false</frontedHotdeploy> in vaadin-maven-plugin configuration section in the POM file.

I’ll double check if the aplication.properties setting usage should work as stated in the error message

adding
<frontendHotdeploy>false</frontedHotdeploy>
worked for starting the application, thanks

how? im using intellij, not sure how to move in order to not break any configurations

Do you mean how to upgrade Vaadin?

yes, upgrade vaadin and run maven with x flag in intellij. thanks for the patience :sweat_smile:

To upgrade Vaadin just change the version of the dependency in the POM file
I supposed you should have a vaadin-bom dependency in dependencyManagement section

How do you get the first error? Simply by starting the application from the IDE or by invoking maven directly (e.g. mvn package)?

If you run maven from command line, just add -X to the arguments (e.g. mvn -X -Pproduction package)
This will produce a verbose output

here the full output of
mvn -X -Pproduction package
https://pastebin.com/pZYXrPNi

i changed vaadin version

the first error came up when clicking maven > “install” on the right side of intellij

The provided link results in a page not found

If you go to Maven settings in IDEA, you can change the “Output level” to Debug, to have the same effect as the -X flag