Closed skiedrowski closed 1 year ago
Does it reproduce consistently because it looks like a temporary network error or something similar?
Yes, always. Tested on two different MacBooks in two different networks. Switching to production mode solves the issue on both MacBooks in both networks.
Not strictly related, but I'm struggling with the exactly same problem when running V23 on vertx-maven-plugin
. It happens locally and also on CI (circleci and github actions). Tried also with different node and npm version, but still have the same error.
To be noted that running npm command manually works as expected.
Not strictly related, but I'm struggling with the exactly same problem when running V23 on
vertx-maven-plugin
. ...
only with productionMode = false
or also with productionMode = true
?
(since my issue only happens when productionMode = false
)
only with productionMode = false
With production mode you will not run ”npm install” from Java (it will run from Maven/Gradle) so you won’t see the same issue
It seems like the problem is related to how STDERR is handled by processes launched by the JVM.
If in TaskRunNpmInstall.runNpmCommand()
I change builder.redirectError(ProcessBuilder.Redirect.INHERIT)
to builder.redirectError(ProcessBuilder.Redirect.PIPE)
, npm execution completes successfully.
For vertx-maven-plugin
, I think the problem is how the parent process, created by the maven plugin, handles STDERR redirection.
Additional fact is that error seems to happen only with WebpackHandler
; with Vite enabled, all works fine in Payara.
Hello! Any news on this? Keep getting the same error with Vaadin 23.3.6 and Payara 5.192 (productionMode = false).
Description of the bug
Deploying a simple Vaadin application in dev mode to Payara Server 5.2022.2 causes NPM Dependency ERROR. Deploying the same application to Tomcat works fine. Deploying the same application in production mode works with both servers.
Expected behavior
Dev Mode should be available with Vaadin 23 and Payara.
Minimal reproducible example
Preparation
Tomcat works
vaadinDevModeTroubleTomcat
./mvnw package
cd apache-tomcat-9.0.62/bin/ && ./startup.sh
)cd ../.. && cp target/myapp.war apache-tomcat-9.0.62/webapps/
)apache-tomcat-9.0.62/bin/shutdown.sh
Payara fails
vaadinDevModeTroublePayara
./mvnw package
payara5/bin/asadmin start-domain
)payara5/bin/asadmin deploy target/myapp.war
)payara5/glassfish/domains/domain1/logs/server.log contains
~/.npm/_logs/2022-04-29T06_49_42_618Z-debug-0.log contains
payara5/bin/asadmin stop-domain
Versions