Open taefi opened 4 months ago
There is a mention of this situation in the Troubleshooting section of the documentation.
Just mentioning it here for future references:
Another issue I faced is that having a dependency in the classPath that contains a flow-build-info.json
can mess with finding the themes folder under frontend
directory as well, since when the dependency project is built without the production
flag set, there is an entry for "frontendFolder"
which is referring to the paths of the dependency project.
Thanks for the hint @mcollovati. I could workaround the issue by excluding the build info from the dependency jar file.
Description of the bug
Having a Vaadin application built for production as a dependency forces production mode to the main application at development time. It seems that the
DefaultApplicationConfigurationFactory
causes a leakage of build info token from the dependencies available in the classpath.Developing Hilla applications, it can happen that another Hilla application containing endpoints could be reused as a dependency (even thought the reusable part could be only the endpoints).
Workaround
Creating a separate build of the dependency without production flag alleviates the issue.
Expected behavior
The
productionMode
value of the build info token from a dependency should not be taken into account when running the main application in development mode.Minimal reproducible example
production
flag.Versions