Urgent: production build failed

Since two days and without any obvious reason, I am experiencing a serious issue with the production build of my 24.7.6 app.

I build via
mvn clean vaadin:clean-frontend package -Pproduction

The maven log mentioned, that a production mode bundle build is needed and create one.
I can remove src/main/bundles and it’s recreated.

After start via java -jar target/jarfile.jar the app starts and logs that it runs in production mode.
But the css definitions are missed, the login screen doesn’t have the background image and if I start a view/route with an @JsModule annotation, the following error:

ERROR c.v.flow.component.internal.UIInternals The component class XYZ.class contains ‘./copyToClipboard.js’, but this file was not included when the production package was created. The component is not working properly. Check whether you have a reference to the component and whether you are not just using it via reflection. If necessary, add @Uses(XYZView.class) where it is used.

I have read the existing forum posts

vaadin-component-not-work

What I have already tried:

  • set <optimizeBundle>false</optimizeBundle>

  • replace @JsModule(“./copyToClipboard.js”)
    with @JavaScript(‘./copyToClipboard.js’)

  • add @Uses(XYZView.class) to MainLayout.java

  • add @LoadDependenciesOnStartup to the main application class

It’s an urgent problem for me because I have to provide an bugfix release for the productiion stage and can’t deliver … :see_no_evil:

Kind regards
Dominik

if I open the src/main/bundle/prod.bundle and take a look into config/flow-build-info.json the is the line

"productionMode": false

???

remove “vaadin:clean-frontend” from your CI build and ensure package.json and other frontend files are committed. Never had any problems

removed (was only temporary in order to detect the reason) and both package*.json are already commited

The symptoms you describe are consistent with the typical cases where the the production bundle optimizer cannot detect that some part of the application is actually used. But those problems typically don’t pop out of of nowhere and they should also be fixed by any of the approaches that you mentioned that you’ve already tried.

The one thing that comes to mind is to try running the build with debug logging (i.e. the -X flag for the mvn command) to see if there’s anything there that looks suspicious.

After an (unsuccessfully) build, there is a file in src/main/bundles/prod/config/flow-build-info.json with "productionMode": false altough I use -Pproduction and also -Dvaadin.force.production.build=true, . I can manually modify this file (as long as I do not force new prod bundle of course) , set "productionMode": true, and rebuild for production. In this case, it seems to work.

But in case of a clean/new production mode bundle build, how this file is created ?
the troubleshooting docs mentioned

is located in the META-INF/VAADIN/config/ resource package.

But if I put a manually modified file there, it’s not taken by the build process. In this case, again "productionMode": false, and the app starts incorectly without css and images.

Is the build-frontend goal executed correctly?
The productionMode flag in flow-build-info is updated to true when the build-frontend goal is executed.
Also flow-build-info.json should not end up in the bundle.

Is the build-frontend goal executed correctly?

I attach the result fro mvn -X

The productionMode flag in flow-build-info is updated to true when the build-frontend goal is executed.

Nope, the file contains “productionMode”: false

Also flow-build-info.json should not end up in the bundle.

Nope, the prod.bundle contains this file.

4843 [INFO] --- vaadin:24.7.6:build-frontend (default) @ isplaner ---
4843 [DEBUG] Loading mojo com.vaadin:vaadin-maven-plugin:24.7.6:build-frontend from plugin realm ClassRealm[plugin>com.vaadin:vaadin-maven-plugin:24.7.6, parent: jdk.internal.loader.ClassLoaders$AppClassLoader@497470ed]
4844 [DEBUG] Configuring mojo execution 'com.vaadin:vaadin-maven-plugin:24.7.6:build-frontend:default' with basic configurator -->
4845 [DEBUG]   (f) applicationProperties = /Users/x/projectDir/src/main/resources/application.properties
4845 [DEBUG]   (f) bunEnable = false
4845 [DEBUG]   (f) ciBuild = false
4845 [DEBUG]   (f) cleanFrontendFiles = true
4845 [DEBUG]   (f) forceProductionBuild = false
4845 [DEBUG]   (f) frontend = /Users/x/projectDir/src/main/frontend
4845 [DEBUG]   (f) frontendDirectory = /Users/x/projectDir/src/main/frontend
4845 [DEBUG]   (f) frontendExtraFileExtensions = []
4845 [DEBUG]   (f) frontendResourcesDirectory = /Users/x/projectDir/src/main/resources/META-INF/resources/frontend
4845 [DEBUG]   (f) generateBundle = true
4845 [DEBUG]   (f) generateEmbeddableWebComponents = true
4845 [DEBUG]   (f) javaResourceFolder = /Users/x/projectDir/src/main/resources
4845 [DEBUG]   (f) javaSourceFolder = /Users/x/projectDir/src/main/java
4845 [DEBUG]   (f) mojoExecution = com.vaadin:vaadin-maven-plugin:24.7.6:build-frontend {execution: default}
4845 [DEBUG]   (f) node = node
4845 [DEBUG]   (f) nodeAutoUpdate = true
4845 [DEBUG]   (f) nodeVersion = v22.14.0
4845 [DEBUG]   (f) npmExcludeWebComponents = false
4845 [DEBUG]   (f) npmFolder = /Users/Dominik/Documents/hwg/isplaner
4846 [DEBUG]   (f) openApiJsonFile = /Users/x/projectDir/target/generated-resources/openapi.json
4846 [DEBUG]   (f) optimizeBundle = false
4846 [DEBUG]   (f) pnpmEnable = false
4846 [DEBUG]   (f) postinstallPackages = []
4846 [DEBUG]   (f) project = MavenProject: de.hub28.hwg:isplaner:1.5.19 @ /Users/x/projectDir/pom.xml
4846 [DEBUG]   (f) projectBasedir = /Users/Dominik/Documents/hwg/isplaner
4846 [DEBUG]   (f) projectBuildDir = /Users/x/projectDir/target
4846 [DEBUG]   (f) requireHomeNodeExec = false
4846 [DEBUG]   (f) resourceOutputDirectory = /Users/x/projectDir/target/classes/META-INF/VAADIN
4846 [DEBUG]   (f) runNpmInstall = true
4846 [DEBUG]   (f) skipDevBundleRebuild = false
4846 [DEBUG]   (f) useGlobalPnpm = false
4846 [DEBUG]   (f) webpackOutputDirectory = /Users/x/projectDir/target/classes/META-INF/VAADIN/webapp
4846 [DEBUG] -- end configuration --
4846 [DEBUG] Using cached Reflector for plugin com.vaadin:vaadin-maven-plugin and phase compile
4853 [DEBUG] Auto-detected client-side router to use: react-router
4853 [DEBUG] Auto-detected client-side router to use: react-router
4853 [DEBUG] Auto-detected client-side router to use: react-router
4859 [DEBUG] 
 List of npm dependencies found in the project:

 XXX removed 

4870 [DEBUG] 
 List of @JsModule found in the project:
    
XXX removed 

 List of @JavaScript found in the project:
4872 [INFO] Visited 304 classes. Took 19 ms.
4874 [INFO] Checking if a production mode bundle build is needed
4875 [INFO] Custom eager routes defined. Require bundle build.
4875 [INFO] A production mode bundle build is needed
4902 [DEBUG] writing to file '/Users/x/projectDir/src/main/frontend/generated/index.tsx' because content does not match
4903 [DEBUG] writing to file '/Users/x/projectDir/src/main/frontend/generated/flow/Flow.tsx' because content does not match
4905 [DEBUG] skipping writing to file '/Users/x/projectDir/src/main/frontend/generated/jsx-dev-transform/index.ts' because content matches
4905 [DEBUG] skipping writing to file '/Users/x/projectDir/src/main/frontend/generated/jsx-dev-transform/jsx-dev-runtime.ts' because content matches
4905 [DEBUG] skipping writing to file '/Users/x/projectDir/src/main/frontend/generated/jsx-dev-transform/jsx-runtime.ts' because content matches
4905 [DEBUG] writing to file '/Users/x/projectDir/src/main/frontend/generated/vaadin-react.tsx' because content does not match
4910 [DEBUG] writing to file '/Users/x/projectDir/src/main/frontend/generated/layouts.json' because content does not match
4912 [DEBUG] writing to file '/Users/x/projectDir/src/main/frontend/generated/flow/ReactAdapter.tsx' because content does not match
4912 [DEBUG] skipping writing to file '/Users/x/projectDir/src/main/frontend/generated/routes.tsx' because content matches
4918 [DEBUG] types.d.ts is up-to-date
4918 [DEBUG] skipping writing to file '/Users/x/projectDir/target/sw.ts' because content matches
4918 [DEBUG] skipping writing to file '/Users/x/projectDir/src/main/frontend/generated/vaadin-featureflags.js' because content matches
4920 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/build-status-plugin/build-status-plugin.js' because content does not match
4920 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/build-status-plugin/package.json' because content does not match
4921 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/application-theme-plugin/application-theme-plugin.js' because content does not match
4921 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/application-theme-plugin/theme-generator.js' because content does not match
4922 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/application-theme-plugin/theme-copy.js' because content does not match
4922 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/application-theme-plugin/theme-handle.js' because content does not match
4922 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/application-theme-plugin/package.json' because content does not match
4923 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/theme-loader/theme-loader.js' because content does not match
4923 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/theme-loader/theme-loader-utils.js' because content does not match
4923 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/theme-loader/package.json' because content does not match
4923 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/theme-live-reload-plugin/theme-live-reload-plugin.js' because content does not match
4924 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/theme-live-reload-plugin/package.json' because content does not match
4924 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/rollup-plugin-postcss-lit-custom/rollup-plugin-postcss-lit.js' because content does not match
4924 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/rollup-plugin-postcss-lit-custom/package.json' because content does not match
4924 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/react-function-location-plugin/react-function-location-plugin.js' because content does not match
4924 [DEBUG] writing to file '/Users/x/projectDir/target/plugins/react-function-location-plugin/package.json' because content does not match
4926 [DEBUG] versions.json adds dependency @vaadin/bundles with version 24.7.7
4926 [DEBUG] versions.json adds dependency @vaadin/polymer-legacy-adapter with version 24.7.7
4926 [DEBUG] versions.json adds dependency @vaadin/vaadin-development-mode-detector with version 2.0.7
4926 [DEBUG] versions.json adds dependency @vaadin/vaadin-usage-statistics with version 2.1.3
4927 [DEBUG] versions.json adds dependency @vaadin/react-components with version 24.7.7 for mode react
4927 [DEBUG] versions.json adds dependency @vaadin/react-components-pro with version 24.7.7 for mode react
4927 [DEBUG] Added "@vaadin/bundles": "24.7.7" line.
4927 [DEBUG] Added "@vaadin/polymer-legacy-adapter": "24.7.7" line.
4928 [DEBUG] Added "@vaadin/vaadin-themable-mixin": "24.7.7" line.
4928 [DEBUG] Added "@vaadin/vaadin-lumo-styles": "24.7.7" line.
4928 [DEBUG] Added "@vaadin/vaadin-material-styles": "24.7.7" line.
4928 [DEBUG] versions.json adds dependency @vaadin/bundles with version 24.7.7
4928 [DEBUG] versions.json adds dependency @vaadin/polymer-legacy-adapter with version 24.7.7
4928 [DEBUG] versions.json adds dependency @vaadin/vaadin-development-mode-detector with version 2.0.7
4928 [DEBUG] versions.json adds dependency @vaadin/vaadin-usage-statistics with version 2.1.3
4928 [DEBUG] versions.json adds dependency @vaadin/react-components with version 24.7.7 for mode react
4929 [DEBUG] versions.json adds dependency @vaadin/react-components-pro with version 24.7.7 for mode react
4930 [DEBUG] Added 7 dependencies to main package.json
8429 [DEBUG] versions.json adds dependency @vaadin/bundles with version 24.7.7
8429 [DEBUG] versions.json adds dependency @vaadin/polymer-legacy-adapter with version 24.7.7
8429 [DEBUG] versions.json adds dependency @vaadin/vaadin-development-mode-detector with version 2.0.7
8429 [DEBUG] versions.json adds dependency @vaadin/vaadin-usage-statistics with version 2.1.3
8429 [DEBUG] versions.json adds dependency @vaadin/react-components with version 24.7.7 for mode react
8431 [DEBUG] versions.json adds dependency @vaadin/react-components-pro with version 24.7.7 for mode react
8439 [DEBUG] writing file /Users/x/projectDir/package.json.
8440 [DEBUG] writing to file '/Users/x/projectDir/package.json' because content does not match
8440 [INFO] Running `npm install` to resolve and optionally download frontend dependencies. This may take a moment, please stand by...
8454 [DEBUG] Command '[which, node]' has non-empty stderr but assuming this is fine:
''
8474 [DEBUG] Command '[/opt/homebrew/bin/node, -v]' has non-empty stderr but assuming this is fine:
''
8513 [DEBUG] Using node 23.6.0 located at /opt/homebrew/bin/node
8521 [DEBUG] Command '[which, npm]' has non-empty stderr but assuming this is fine:
''
8606 [DEBUG] Command '[/opt/homebrew/bin/npm, -v]' has non-empty stderr but assuming this is fine:
''
8758 [DEBUG] Command '[which, npm]' has non-empty stderr but assuming this is fine:
''
8834 [DEBUG] Command '[/opt/homebrew/bin/npm, -v]' has non-empty stderr but assuming this is fine:
''
8908 [DEBUG] Using npm 10.9.2 located at /opt/homebrew/bin/npm
8912 [DEBUG] Command '[which, npm]' has non-empty stderr but assuming this is fine:
''
8986 [DEBUG] Command '[/opt/homebrew/bin/npm, -v]' has non-empty stderr but assuming this is fine:
''
9064 [DEBUG] 
/opt/homebrew/bin/npm --no-update-notifier --no-audit \ 
    --scripts-prepend-node-path=true --ignore-scripts \ 
    install 

9064 [INFO] using '/opt/homebrew/bin/npm --no-update-notifier --no-audit --scripts-prepend-node-path=true --ignore-scripts install' for frontend package installation
9067 [DEBUG] Output of `/opt/homebrew/bin/npm --no-update-notifier --no-audit --scripts-prepend-node-path=true --ignore-scripts install`:
21649 [DEBUG] npm warn deprecated inflight@1.0.6: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.
21649 [DEBUG] npm warn deprecated rollup-plugin-terser@5.3.1: This package has been deprecated and is no longer maintained. Please use @rollup/plugin-terser
21649 [DEBUG] npm warn deprecated acorn-dynamic-import@4.0.0: This is probably built in to whatever tool you're using. If you still need it... idk
21649 [DEBUG] npm warn deprecated glob@7.2.3: Glob versions prior to v9 are no longer supported
21649 [DEBUG] npm warn deprecated sourcemap-codec@1.4.8: Please use @jridgewell/sourcemap-codec instead
21649 [DEBUG] 
21649 [DEBUG] added 637 packages in 13s
21649 [DEBUG] 
21649 [DEBUG] 124 packages are looking for funding
21649 [DEBUG]   run `npm fund` for details
21649 [INFO] Frontend dependencies resolved successfully.
21650 [DEBUG] Skipping postinstall for '.' as no postinstall script was found in the package.json
21650 [DEBUG] Running postinstall for 'esbuild'
21653 [DEBUG] Output of postinstall `esbuild`:
22058 [DEBUG] 
22058 [DEBUG] > esbuild@0.25.5 postinstall
22058 [DEBUG] > node install.js
22058 [DEBUG] 
22058 [DEBUG] Running postinstall for '@vaadin/vaadin-usage-statistics'
22064 [DEBUG] Output of postinstall `@vaadin/vaadin-usage-statistics`:
22268 [DEBUG] 
22268 [DEBUG] > @vaadin/vaadin-usage-statistics@2.1.3 postinstall
22268 [DEBUG] > node check.cjs
22268 [DEBUG] 
22268 [DEBUG] 
22268 [DEBUG]     Vaadin collects development time usage statistics to improve this product. To opt-out, either run:
22268 [DEBUG]     npm explore @vaadin/vaadin-usage-statistics -- npm run disable
22268 [DEBUG]     to store disable statistics for the machine, or add
22268 [DEBUG]     "vaadin": { "disableUsageStatistics": true }
22268 [DEBUG]     to the project package.json and re-run npm install to disable statistics for the project.
22268 [DEBUG] 
22268 [DEBUG]     For more details, see https://github.com/vaadin/vaadin-usage-statistics
22268 [DEBUG]   
22270 [DEBUG] writing to file '/Users/x/projectDir/node_modules/.vaadin/vaadin.json' because content does not match
22270 [INFO] Copying frontend resources from jar files ...
22360 [INFO] Visited 362 resources. Took 89 ms.
22360 [INFO] Copying project local frontend resources.
22365 [INFO] Copied 1 local frontend files. Took 5 ms.
22365 [INFO] Copying frontend directory completed.
22366 [DEBUG] Generating PWA icons from 'icons/icon.png'
23451 [INFO] PWA icons generated
23454 [DEBUG] skipping writing to file '/Users/x/projectDir/target/vaadin-dev-server-settings.json' because content matches
23456 [DEBUG] skipping writing to file '/Users/x/projectDir/vite.generated.ts' because content matches
23456 [DEBUG] Created vite generated configuration file: '/Users/x/projectDir/vite.generated.ts'
23458 [DEBUG] Start updating imports file and chunk files.
23458 [DEBUG] Start collecting scanned JS modules and scripts.
23458 [DEBUG] Found 1 modules, and 1 scripts.
23470 [DEBUG] JS modules and scripts collected in 12 ms.
23470 [DEBUG] Start sorting imports to lazy and eager.
23470 [DEBUG] Imports sorting took 0 ms.
23702 [DEBUG] writing to file '/Users/x/projectDir/src/main/frontend/generated/flow/generated-flow-imports.js' because content does not match
23703 [DEBUG] skipping writing to file '/Users/x/projectDir/src/main/frontend/generated/flow/generated-flow-imports.d.ts' because content matches
23723 [DEBUG] writing to file '/Users/x/projectDir/src/main/frontend/generated/flow/generated-flow-webcomponent-imports.js' because content does not match
23723 [DEBUG] Imports and chunks update took 265 ms.
23723 [DEBUG] Didn't create folders as they probably already exist. If there is a problem check access rights for folder /Users/x/projectDir/src/main/frontend/generated
23724 [DEBUG] writing to file '/Users/x/projectDir/src/main/frontend/generated/theme.js' because content does not match
23724 [DEBUG] writing to file '/Users/x/projectDir/src/main/frontend/generated/theme.d.ts' because content does not match
23730 [DEBUG] writing to file '/Users/x/projectDir/src/main/frontend/generated/vaadin.ts' because content does not match
23761 [DEBUG] Command '[which, node]' has non-empty stderr but assuming this is fine:
''
23792 [DEBUG] Command '[/opt/homebrew/bin/node, -v]' has non-empty stderr but assuming this is fine:
''
23852 [DEBUG] Using node 23.6.0 located at /opt/homebrew/bin/node
23857 [DEBUG] Command '[which, npm]' has non-empty stderr but assuming this is fine:
''
23949 [DEBUG] Command '[/opt/homebrew/bin/npm, -v]' has non-empty stderr but assuming this is fine:
''
24129 [DEBUG] Command '[which, npm]' has non-empty stderr but assuming this is fine:
''
24218 [DEBUG] Command '[/opt/homebrew/bin/npm, -v]' has non-empty stderr but assuming this is fine:
''
24310 [DEBUG] Using npm 10.9.2 located at /opt/homebrew/bin/npm
24316 [DEBUG] Command '[which, node]' has non-empty stderr but assuming this is fine:
''
24335 [DEBUG] Command '[/opt/homebrew/bin/node, -v]' has non-empty stderr but assuming this is fine:
''
24361 [INFO] Running Vite ...
24361 [DEBUG] 
/opt/homebrew/bin/node \ 
    ./node_modules/vite/bin/vite.js build 

24361 [DEBUG] Executing [/opt/homebrew/bin/node, /Users/x/projectDir/node_modules/vite/bin/vite.js, build] in /Users/Dominik/Documents/hwg/isplaner with environment {HOMEBREW_PREFIX=/opt/homebrew, JENV_SHELL=zsh, SDKMAN_CANDIDATES_API=https://api.sdkman.io/2, TERM_FEATURES=T3LrMSc7UUw9Ts3BFGsSyHNoSxF, TERM_SESSION_ID=w0t1p1:2B22AD1D-FD49-4398-959B-3F763AA9DC19, _P9K_TTY=/dev/ttys003, ITERM_SESSION_ID=w0t1p1:2B22AD1D-FD49-4398-959B-3F763AA9DC19, ZSH=/Users/Dominik/.oh-my-zsh, PGDATA=/opt/homebrew/var/postgresql@17, HOMEBREW_REPOSITORY=/opt/homebrew, PATH=/opt/homebrew/bin:/Users/Dominik/.sdkman/candidates/maven/current/bin:/Users/Dominik/.sdkman/candidates/jbang/current/bin:/Users/Dominik/.sdkman/candidates/java/current/bin:/Users/Dominik/.sdkman/candidates/gradle/current/bin:/Users/Dominik/.jenv/shims:/Users/Dominik/.jenv/bin:/opt/homebrew/opt/gnu-getopt/bin:/Users/Dominik/bin:/opt/homebrew/opt/postgresql@17/bin:/Users/Dominik/Library/Mobile Documents/com~apple~CloudDocs/bin:/Users/Dominik/Library/Mobile Documents/com~apple~CloudDocs/scripts:/opt/homebrew/bin:/opt/homebrew/sbin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/Library/Apple/usr/bin:/Applications/iTerm.app/Contents/Resources/utilities:/Users/Dominik/.nvm:/Users/Dominik/java/liquibase-3.6.2-bin:/opt/homebrew/Cellar/mvnd/1.0-m6-m39/bin:/Users/Dominik/Documents/vaadin/vaadin-cli/target, LOGNAME=dominik, LS_COLORS=di=1;36:ln=35:so=32:pi=33:ex=31:bd=34;46:cd=34;43:su=30;41:sg=30;46:tw=30;42:ow=30;43, XPC_FLAGS=0x0, __CF_USER_TEXT_ENCODING=0x1F5:0x0:0x3, LC_TERMINAL_VERSION=3.5.14, MAVEN_CMD_LINE_ARGS= -Dmaven.test.skip -Pproduction package -Djarfile=isplaner -X, P9K_TTY=old, NVM_DIR=/Users/Dominik/.nvm, TERM_PROGRAM_VERSION=3.5.14, JBANG_HOME=/Users/Dominik/.sdkman/candidates/jbang/current, JAVA_HOME=/Users/Dominik/.sdkman/candidates/java/current, LESS=-R, LSCOLORS=Gxfxcxdxbxegedabagacad, ATUIN_SESSION=01975e3c9f837fc2b1422919aa3bee5a, ITERM_PROFILE=Default, SDKMAN_DIR=/Users/Dominik/.sdkman, SDKMAN_CANDIDATES_DIR=/Users/Dominik/.sdkman/candidates, XPC_SERVICE_NAME=0, ATUIN_HISTORY_ID=019787c29f08712390511aa73204790d, HOMEBREW_CELLAR=/opt/homebrew/Cellar, COMMAND_MODE=unix2003, SHLVL=1, INFOPATH=/opt/homebrew/share/info:, SHELL=/bin/zsh, __CFBundleIdentifier=com.googlecode.iterm2, TMPDIR=/var/folders/1q/plz4q23128g8hj6brr04wp100000gn/T/, COLORTERM=truecolor, MAVEN_PROJECTBASEDIR=/Users/Dominik/Documents/hwg/isplaner, _P9K_SSH_TTY=/dev/ttys003, JENV_LOADED=1, HOME=/Users/Dominik, LC_TERMINAL=iTerm2, LaunchInstanceID=2460D55A-6A1E-4209-B2EC-EFA1A4009411, COLORFGBG=15;0, SSH_AGENT_PID=955, TERM=xterm-256color, LANG=de_DE.UTF-8, TERM_PROGRAM=iTerm.app, P9K_SSH=0, POSTGRESQL_HOME=/opt/homebrew/opt/postgresql@17, MAVEN_ARGS=-Dorg.slf4j.simpleLogger.showDateTime=true, MAVEN_HOME=/Users/Dominik/.sdkman/candidates/maven/current, SSH_AUTH_SOCK=/var/folders/1q/plz4q23128g8hj6brr04wp100000gn/T//ssh-KsEa1Gni2jA4/agent.953, OLDPWD=/Users/Dominik/Documents/hwg/isplaner, TERMINFO_DIRS=/Applications/iTerm.app/Contents/Resources/terminfo:/usr/share/terminfo, PAGER=less, USER=dominik, SECURITYSESSIONID=186b2, SDKMAN_PLATFORM=darwinarm64, GRADLE_HOME=/Users/Dominik/.sdkman/candidates/gradle/current, PWD=/Users/Dominik/Documents/hwg/isplaner}.
24366 [DEBUG] Started Process[pid=62407, exitValue="not exited"]
45941 [DEBUG] Process[pid=62407, exitValue=0] stopped with exit code 0
47245 [DEBUG] Using cached Reflector for plugin com.vaadin:vaadin-maven-plugin and phase compile
47246 [DEBUG] Removing file /Users/x/projectDir/package-lock.json
47246 [DEBUG] Auto-detected client-side router to use: react-router
47248 [INFO] Scanning classes to find frontend configurations and dependencies...
47248 [DEBUG] Reading default values for com.vaadin.flow.server.LoadDependenciesOnStartup
47252 [DEBUG] Default values for com.vaadin.flow.server.LoadDependenciesOnStartup: {value=[]}
47659 [DEBUG] Classes reachable from 

    XXX removed


50613 [DEBUG] Reading default values for com.vaadin.flow.component.dependency.NpmPackage
50613 [DEBUG] Default values for com.vaadin.flow.component.dependency.NpmPackage: {dev=false}
50829 [DEBUG] Reading default values for com.vaadin.flow.server.PWA
50830 [DEBUG] Default values for com.vaadin.flow.server.PWA: {offlinePath=, offline=true, backgroundColor=#f2f2f2, startPath=., themeColor=#ffffff, display=standalone, offlineResources=[], description=, manifestPath=manifest.webmanifest, iconPath=icons/icon.png}
50831 [DEBUG] No value for description using default: 
50831 [DEBUG] No value for backgroundColor using default: #f2f2f2
50831 [DEBUG] No value for themeColor using default: #ffffff
50831 [DEBUG] No value for iconPath using default: icons/icon.png
50831 [DEBUG] No value for manifestPath using default: manifest.webmanifest
50831 [DEBUG] No value for offlinePath using default: 
50831 [DEBUG] No value for display using default: standalone
50831 [DEBUG] No value for startPath using default: .
50831 [DEBUG] No value for offlineResources using default: []
50831 [DEBUG] No value for offline using default: true
50929 [INFO] Visited 11941 classes. Took 3680 ms.
50938 [DEBUG] Import from an unknown package: @vaadin/common-frontend/ConnectionIndicator.js
50958 [DEBUG] Checking license for Product [name=vaadin-chart, version=24.7.7]
51171 [DEBUG] Found proKey in /Users/Dominik/.vaadin/proKey
51173 [DEBUG] Online validation using subscriptionKey for Product [name=vaadin-chart, version=24.7.7]
51174 [DEBUG] No subscription key found
51174 [DEBUG] Online validation using proKey for Product [name=vaadin-chart, version=24.7.7]
51174 [DEBUG] Checking if license for Product [name=vaadin-chart, version=24.7.7] has recently been checked for build type PRODUCTION and pro key com.vaadin.pro.licensechecker.ProKey@4a778615
51188 [DEBUG] Last check for Product [name=vaadin-chart, version=24.7.7] was on 2025-06-13T13:50:28.172Z
52049 [DEBUG] Validating license for vaadin-chart 24.7.7
52049 [DEBUG] Marking license for Product [name=vaadin-chart, version=24.7.7] as checked now for buildType PRODUCTION
52049 [DEBUG] Marking license for Product [name=vaadin-chart, version=24.7.7] as checked on 2025-06-19T10:37:00.696698Z for buildType PRODUCTION and pro key com.vaadin.pro.licensechecker.ProKey@4a778615
52055 [DEBUG] Storing subscription for Product [name=vaadin-chart, version=24.7.7]
52056 [DEBUG] Pro key OK
52056 [DEBUG] Checking license for Product [name=vaadin-crud, version=24.7.7]
52056 [DEBUG] Found proKey in /Users/Dominik/.vaadin/proKey
52056 [DEBUG] Online validation using subscriptionKey for Product [name=vaadin-crud, version=24.7.7]
52056 [DEBUG] No subscription key found
52056 [DEBUG] Online validation using proKey for Product [name=vaadin-crud, version=24.7.7]
52056 [DEBUG] Checking if license for Product [name=vaadin-crud, version=24.7.7] has recently been checked for build type PRODUCTION and pro key com.vaadin.pro.licensechecker.ProKey@5da0292e
52056 [DEBUG] Last check for Product [name=vaadin-crud, version=24.7.7] was on 2025-06-17T06:16:02.879Z
52340 [DEBUG] Validating license for vaadin-crud 24.7.7
52341 [DEBUG] Marking license for Product [name=vaadin-crud, version=24.7.7] as checked now for buildType PRODUCTION
52341 [DEBUG] Marking license for Product [name=vaadin-crud, version=24.7.7] as checked on 2025-06-19T10:37:00.988139Z for buildType PRODUCTION and pro key com.vaadin.pro.licensechecker.ProKey@5da0292e
52343 [DEBUG] Storing subscription for Product [name=vaadin-crud, version=24.7.7]
52344 [DEBUG] Pro key OK
52344 [DEBUG] Checking license for Product [name=vaadin-grid-pro, version=24.7.7]
52344 [DEBUG] Found proKey in /Users/Dominik/.vaadin/proKey
52345 [DEBUG] Online validation using subscriptionKey for Product [name=vaadin-grid-pro, version=24.7.7]
52345 [DEBUG] No subscription key found
52345 [DEBUG] Online validation using proKey for Product [name=vaadin-grid-pro, version=24.7.7]
52345 [DEBUG] Checking if license for Product [name=vaadin-grid-pro, version=24.7.7] has recently been checked for build type PRODUCTION and pro key com.vaadin.pro.licensechecker.ProKey@d036aad
52345 [DEBUG] Last check for Product [name=vaadin-grid-pro, version=24.7.7] was on 2025-06-17T06:16:03.173Z
52634 [DEBUG] Validating license for vaadin-grid-pro 24.7.7
52636 [DEBUG] Marking license for Product [name=vaadin-grid-pro, version=24.7.7] as checked now for buildType PRODUCTION
52636 [DEBUG] Marking license for Product [name=vaadin-grid-pro, version=24.7.7] as checked on 2025-06-19T10:37:01.283235Z for buildType PRODUCTION and pro key com.vaadin.pro.licensechecker.ProKey@d036aad
52639 [DEBUG] Storing subscription for Product [name=vaadin-grid-pro, version=24.7.7]
52640 [DEBUG] Pro key OK
52640 [DEBUG] Checking license for Product [name=vaadin-map, version=24.7.7]
52640 [DEBUG] Found proKey in /Users/Dominik/.vaadin/proKey
52641 [DEBUG] Online validation using subscriptionKey for Product [name=vaadin-map, version=24.7.7]
52641 [DEBUG] No subscription key found
52641 [DEBUG] Online validation using proKey for Product [name=vaadin-map, version=24.7.7]
52641 [DEBUG] Checking if license for Product [name=vaadin-map, version=24.7.7] has recently been checked for build type PRODUCTION and pro key com.vaadin.pro.licensechecker.ProKey@2e663706
52641 [DEBUG] Last check for Product [name=vaadin-map, version=24.7.7] was on 2025-06-13T13:50:29.054Z
52934 [DEBUG] Validating license for vaadin-map 24.7.7
52934 [DEBUG] Marking license for Product [name=vaadin-map, version=24.7.7] as checked now for buildType PRODUCTION
52934 [DEBUG] Marking license for Product [name=vaadin-map, version=24.7.7] as checked on 2025-06-19T10:37:01.581684Z for buildType PRODUCTION and pro key com.vaadin.pro.licensechecker.ProKey@2e663706
52938 [DEBUG] Storing subscription for Product [name=vaadin-map, version=24.7.7]
52939 [DEBUG] Pro key OK
52946 [INFO] Build frontend completed in 48092 ms.
52946 [DEBUG] Found dependencies defined with different versions in project and Vaadin maven plugin.
Project dependencies are used, but plugin execution could fail if the versions are incompatible.
In case of build failure please analyze the project dependencies and update versions or configure exclusions for potential offending transitive dependencies.
You can use 'mvn dependency:tree -Dincludes=groupId:artifactId' to detect where the dependency is defined in the project.

commons-io:commons-io:jar: project version [2.15.0], plugin version [2.18.0]
org.apache.commons:commons-compress:jar: project version [1.26.2], plugin version [1.27.1]
org.apache.commons:commons-lang3:jar: project version [3.17.0], plugin version [3.16.0]
org.apache.commons:commons-text:jar: project version [1.11.0], plugin version [1.13.0]
io.github.classgraph:classgraph:jar: project version [4.8.146], plugin version [4.8.179]
com.fasterxml.jackson.dataformat:jackson-dataformat-yaml:jar: project version [2.18.2], plugin version [2.18.3]
org.yaml:snakeyaml:jar: project version [2.2], plugin version [2.3]
com.fasterxml.jackson.module:jackson-module-parameter-names:jar: project version [2.18.2], plugin version [2.18.3]
com.fasterxml.jackson.datatype:jackson-datatype-jdk8:jar: project version [2.18.2], plugin version [2.18.3]
jakarta.xml.bind:jakarta.xml.bind-api:jar: project version [4.0.2], plugin version [2.3.3]
jakarta.activation:jakarta.activation-api:jar: project version [2.1.3], plugin version [1.2.2]
jakarta.validation:jakarta.validation-api:jar: project version [3.0.2], plugin version [2.0.2]
org.springframework.data:spring-data-commons:jar: project version [3.4.1], plugin version [3.4.5]
org.springframework:spring-beans:jar: project version [6.2.1], plugin version [6.2.6]
org.springframework:spring-core:jar: project version [6.2.1], plugin version [6.2.6]
org.springframework:spring-jcl:jar: project version [6.2.1], plugin version [6.2.6]
52947 [INFO] 

The file getting into the bundle is wrong as the productioMode flag is updated after the bundle has been built AND it then contains local paths that shouldn’t be there at all.

If you check the JAR file you should find a META-INF/VAADIN/config/flow-build-info.json with the production flag on. That one should be the file processed by the frontend build, IIRC

I’ve given it a try to reproduce your problem with the Vaadin 24.7.6 starter, CopyToClipboard Vaadin recipe and @LoadDependenciesOnStartup. The false flag is indeed in the prod.bundle, but the JAR has it set to true.
Anyway, the app seems to start and work fine for me, at least the @JsModule scanned and work.
Do you have a chance to share a minimal reproducible example with us? (better to create a GitHub issue).

Thanks for your follow up, Mikhail. Unfortunatly its not really reproducible and I can’t share the whole project. But I collect the maven build run log from today and in case it failed again, than I can share this log file, at least.

1 Like