failed to resolve import error while compiling - compilation

I upgraded my version of vaadin from 23.0.2 to 23.3.1, my code always worked fine with vaadin 23.0.2. After upgrading, i cannot compile my project any more. While building the frontend I get the following error:
Rollup failed to resolve import "#vaadin/combo-box/src/vaadin-combo-box-dropdown.js" from "node_modules/multiselect-combo-box/src/multiselect-combo-box-dropdown.js".
The complete stacktrace:
[ERROR] error during build:
[ERROR] Error: [vite]: Rollup failed to resolve import "#vaadin/combo-box/src/vaadin-combo-box-dropdown.js" from "node_modules/multiselect-combo-box/src/multiselect-combo-box-dropdown.js".
[ERROR] This is most likely unintended because it can break your application at runtime.
[ERROR] If you do want to externalize this module explicitly add it to
[ERROR] `build.rollupOptions.external`
[ERROR] at onRollupWarning (file:///C:/bosa/workspaces/my-app/node_modules/vite/dist/node/chunks/dep-67e7f8ab.js:45526:19)
[ERROR] at onwarn (file:///C:/bosa/workspaces/my-app/node_modules/vite/dist/node/chunks/dep-67e7f8ab.js:45297:13)
[ERROR] at Object.onwarn (file:///C:/bosa/workspaces/my-app/node_modules/rollup/dist/es/shared/rollup.js:23263:13)
[ERROR] at ModuleLoader.handleResolveId (file:///C:/bosa/workspaces/my-app/node_modules/rollup/dist/es/shared/rollup.js:22158:26)
[ERROR] at file:///C:/bosa/workspaces/my-app/node_modules/rollup/dist/es/shared/rollup.js:22119:26
[ERROR] ': Unexpected exit value: 1, allowed exit values: [0], executed command [C:\Program Files\nodejs\node.exe, C:\bosa\workspaces\my-app\node_modules\vite\bin\vite.js, build] in directory C:\bosa\workspaces\my-app with environment {USERDOMAIN_ROAMINGPROFILE=DESKTOP-ETHGK19, PROCESSOR_LEVEL=6, SESSIONNAME=Console, ALLUSERSPROFILE=C:\ProgramData, PROCESSOR_ARCHITECTURE=AMD64,
I checked my node_modules folder and vaadin-combo-box-dropdown.js is missing. I cleaned everything, my target folder and my node_modules folder, but the error keeps on occuring. Could anyone help me?

Related

Jenkins throws an exception: build step 'invoke top-level maven targets' marked build as failure

Jenkins throws the following error:
[WARNING] The requested profile "singleflow" could not be activated because it does not exist.
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.1:compile (default-compile) on project factor-esb-autotest: Fatal error compiling: invalid target release: 10 -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
build step 'invoke top-level maven targets' marked build as failure
My POM https://pastebin.com/xeb5Mpcb
At first I thought that the error was due to the fact that in the jenkins global settings the version does not match the plugin (3.8.1), I set it to "Install from Apach" 3.8.1 but it still does not work. What could be the reason ?
Maven in global setting
There must be a configuration for maven-compiler-plugin (<release>10</release>) or a property like <maven.compiler.release>10</maven.compiler.release>
The commented upgrade of JUnit is unrelated to the problem.
Apart from that such information that you have update pom should be part of the question up-front

maven build fails in jenkins for child module error

I have a maven build with the below structure.
TEST/pom.xml -in root directory
TEST/A/B/pom.xml- child module
maven clean install works fine from command prompt. But, it fails when I run from jenkins with this error.
[ERROR] [ERROR] Some problems were encountered while processing the POMs:
[ERROR] Child module /home/jenkins/workspace/TEST/A/B of /home/jenkins/workspace/TEST/pom.xml does not exist #
Please help here as I have failed to resolve this till now.

Error installing dl4j using maven

Sorry but I am very new to using Maven, trying to install dl4j for the provided examples via the following command, as per the instructions on the dl4j website:
mvn clean install -DskipTests -Dmaven.javadoc.skip=true
This proceeds somewhat, but then terminates with an error:
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.5.1:compile (default-compile) on project dl4j-examples: Compilation failure: Compilation failure:
[ERROR] /Users/nick/Downloads/dl4j-examples/dl4j-examples/src/main/java/org/deeplearning4j/examples/unsupervised/variational/plot/PlotUtil.java:[158,13] cannot find symbol
[ERROR] symbol: method setDomainPannable(boolean)
[ERROR] location: variable plot of type org.jfree.chart.plot.XYPlot
[ERROR] /Users/nick/Downloads/dl4j-examples/dl4j-examples/src/main/java/org/deeplearning4j/examples/unsupervised/variational/plot/PlotUtil.java:[159,13] cannot find symbol
[ERROR] symbol: method setRangePannable(boolean)
[ERROR] location: variable plot of type org.jfree.chart.plot.XYPlot
[ERROR] -> [Help 1]
Now I have jfreechart library in a directory searchable by classpath, so, can someone help me resolve the above?
Running mac high sierra, on a 2016 macbook pro.
There is no need to build/install dl4j to run the examples.
Straight from the dl4j quickstart:
git clone https://github.com/deeplearning4j/dl4j-examples.git
cd dl4j-examples/
mvn clean install

I'm trying to build Apache Hadoop 2.5.0 on Windows 7 x64 but I keep running into an unknown error

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-javadoc-plugin:2.8
.1:jar (module-javadocs) on project hadoop-maven-plugins: MavenReportException:
Error while creating archive:
[ERROR] Exit code: 1 - C:\hsc\hadoop-maven-plugins\src\main\java\org\apache\hado
op\maven\plugin\util\Exec.java:45: error: unknown tag: String
[ERROR] * #param command List<String> containing command and all arguments
[ERROR] ^
[ERROR] C:\hsc\hadoop-maven-plugins\src\main\java\org\apache\hadoop\maven\plugin
\util\Exec.java:46: error: unknown tag: String
[ERROR] * #param output List<String> in/out parameter to receive command output
[ERROR] ^
[ERROR] C:\hsc\hadoop-maven-plugins\src\main\java\org\apache\hadoop\maven\plugin
\util\FileSetUtils.java:50: error: unknown tag: File
[ERROR] * #return List<File> containing every element of the FileSet as a File
[ERROR] ^
[ERROR]
[ERROR] Command line was: C:\Progra~1\Java\jdk1.8.0_20\jre\..\bin\javadoc.exe #o
ptions #packages
[ERROR]
[ERROR] Refer to the generated Javadoc files in 'C:\hsc\hadoop-maven-plugins\tar
get' dir.
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e swit
ch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please rea
d the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionE
xception
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] mvn <goals> -rf :hadoop-maven-plugins
Prior to this, I've run into the usual error where it asks for file read/write access. I've given it all the permissions through chmod as well as manually changing the permission settings in the file properties on windows.
The wiki link sends me to a page that basically says its a problem with the plugin. Unfortunately, there isn't anything there that would indicate how to fix the problem.
I'm on Windows 7x64, trying to build hadoop 2.5.0 using src and using latest version of maven 3.2.3 and jdk 1.8.0_20
I had a similar issue while building the source. Instead of using the following command for compiling:
mvn package -Pdist,native -DskipTests=true -Dtar
I used:
mvn package -Pdist,native -Dmaven.javadoc.skip=true -DskipTests -Dtar
Do try this!
You can also add below property in parent POM to resolve this issue -
<properties>
<additionalparam>-Xdoclint:none</additionalparam>
</properties>

Error pushing to Heroku when route is removed from Play Framework

In my commit I:
Removed the controller class: com.fractalemagic.Crashes
Removed the relevant lines from conf/routes
Heroku build log:
-----> Play 2.x - Java app detected
-----> Installing OpenJDK 1.8...done
-----> Running: sbt compile stage
OpenJDK 64-Bit Server VM warning: ignoring option MaxPermSize=512M; support was removed in 8.0
Getting org.scala-sbt sbt 0.13.5 ...
:: retrieving :: org.scala-sbt#boot-app
confs: [default]
44 artifacts copied, 0 already retrieved (13482kB/434ms)
Getting Scala 2.10.4 (for sbt)...
:: retrieving :: org.scala-sbt#boot-scala
confs: [default]
5 artifacts copied, 0 already retrieved (24459kB/193ms)
[info] Loading project definition from /tmp/scala_buildpack_build_dir/project
[info] Set current project to SomethingMagical (in build file:/tmp/scala_buildpack_build_dir/)
[info] Compiling 6 Scala sources and 25 Java sources to /tmp/scala_buildpack_build_dir/target/scala-2.11/classes...
[error] /tmp/scala_buildpack_build_dir/target/scala-2.11/src_managed/main/com/fractalemagic/routes.java:8: error: cannot find symbol
[error] public static final com.fractalemagic.ReverseCrashes Crashes = new com.fractalemagic.ReverseCrashes();
[error] ^
[error] symbol: class ReverseCrashes
[error] location: package com.fractalemagic
[error] /tmp/scala_buildpack_build_dir/target/scala-2.11/src_managed/main/com/fractalemagic/routes.java:11: error: package com.fractalemagic.javascript does not exist
[error] public static final com.fractalemagic.javascript.ReverseCrashes Crashes = new com.fractalemagic.javascript.ReverseCrashes();
[error] ^
[error] /tmp/scala_buildpack_build_dir/target/scala-2.11/src_managed/main/com/fractalemagic/routes.java:16: error: package com.fractalemagic.ref does not exist
[error] public static final com.fractalemagic.ref.ReverseCrashes Crashes = new com.fractalemagic.ref.ReverseCrashes();
[error] ^
[error] /tmp/scala_buildpack_build_dir/target/scala-2.11/src_managed/main/com/fractalemagic/routes.java:8: error: cannot find symbol
[error] public static final com.fractalemagic.ReverseCrashes Crashes = new com.fractalemagic.ReverseCrashes();
[error] ^
[error] symbol: class ReverseCrashes
[error] location: package com.fractalemagic
[error] /tmp/scala_buildpack_build_dir/target/scala-2.11/src_managed/main/com/fractalemagic/routes.java:11: error: package com.fractalemagic.javascript does not exist
[error] public static final com.fractalemagic.javascript.ReverseCrashes Crashes = new com.fractalemagic.javascript.ReverseCrashes();
[error] ^
[error] /tmp/scala_buildpack_build_dir/target/scala-2.11/src_managed/main/com/fractalemagic/routes.java:16: error: package com.fractalemagic.ref does not exist
[error] public static final com.fractalemagic.ref.ReverseCrashes Crashes = new com.fractalemagic.ref.ReverseCrashes();
[error] ^
[error] Note: Some input files use or override a deprecated API.
[error] Note: Recompile with -Xlint:deprecation for details.
[error] Note: /tmp/scala_buildpack_build_dir/app/Global.java uses unchecked or unsafe operations.
[error] Note: Recompile with -Xlint:unchecked for details.
[error] 6 errors
[error] (compile:compile) javac returned nonzero exit code
[error] Total time: 22 s, completed Aug 2, 2014 8:46:52 PM
! Failed to build app with sbt
! Push rejected, failed to compile Play 2.x - Java app
I did get the same error while trying to run the project locally with Activator but after I ran activator clean it worked fine.
I noticed in the build logs that Heroku only compiles the code:
-----> Running: sbt compile stage
When according to: https://devcenter.heroku.com/articles/play-support#activation
It should also clean.
After reversing the commit I was able to push to Heroku successfully.
The docs you've linked seem a bit outdated. You need to specifically tell heroku to do a clean compile, by setting the environment variable SBT_CLEAN=true
If you're using the heroku toolbelt:
heroku config:set SBT_CLEAN=true -a your-app-name
Heroku Build Behavior
For me, I solve the problem by deleting all content under target and then re-compile.

Resources