I am trying to set up nvim for java development, I am rather new to all this, and hence am following this tutorial, because it didn't work when I tried on my own.
tutorial
I first cloned this repo using ssh, then i did a mvnw clean install as told.
and i got the following errors
1 error #
#
[ERROR] The build could not read 2 projects -> [Help 1]
[ERROR]
[ERROR] The project com.microsoft.java:com.microsoft.java.debug.plugin:0.41.0 (/home/demo/.config/nvim/java-debug/com.microsoft.java.debug.plugin/pom.xml) has 1 error
[ERROR] Invalid artifact repository: Unable to provision, see the following errors:
[ERROR]
[ERROR] 1) Error in custom provider, java.lang.TypeNotPresentException: Type org.eclipse.tycho.core.p2.P2ArtifactRepositoryLayout not present
[ERROR] at ClassRealm[extension>org.eclipse.tycho:tycho-maven-plugin:2.7.3, parent: java.net.URLClassLoader#2cb4c3ab] (via modules: org.eclipse.sisu.wire.WireModule -> org.eclipse.sisu.plexus.PlexusBindingModule)
[ERROR] at ClassRealm[extension>org.eclipse.tycho:tycho-maven-plugin:2.7.3, parent: java.net.URLClassLoader#2cb4c3ab] (via modules: org.eclipse.sisu.wire.WireModule -> org.eclipse.sisu.plexus.PlexusBindingModule)
[ERROR] while locating org.apache.maven.artifact.repository.layout.ArtifactRepositoryLayout annotated with #com.google.inject.name.Named(value=p2)
[ERROR]
[ERROR] 1 error: org/eclipse/tycho/core/p2/P2ArtifactRepositoryLayout has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
[ERROR]
[ERROR] The project com.microsoft.java:com.microsoft.java.debug.repository:0.41.0 (/home/demo/.config/nvim/java-debug/com.microsoft.java.debug.repository/pom.xml) has 1 error
[ERROR] Invalid artifact repository: Unable to provision, see the following errors:
[ERROR]
[ERROR] 1) Error in custom provider, java.lang.TypeNotPresentException: Type org.eclipse.tycho.core.p2.P2ArtifactRepositoryLayout not present
[ERROR] at ClassRealm[extension>org.eclipse.tycho:tycho-maven-plugin:2.7.3, parent: java.net.URLClassLoader#2cb4c3ab] (via modules: org.eclipse.sisu.wire.WireModule -> org.eclipse.sisu.plexus.PlexusBindingModule)
[ERROR] at ClassRealm[extension>org.eclipse.tycho:tycho-maven-plugin:2.7.3, parent: java.net.URLClassLoader#2cb4c3ab] (via modules: org.eclipse.sisu.wire.WireModule -> org.eclipse.sisu.plexus.PlexusBindingModule)
[ERROR] while locating org.apache.maven.artifact.repository.layout.ArtifactRepositoryLayout annotated with #com.google.inject.name.Named(value=p2)
[ERROR]
[ERROR] 1 error: org/eclipse/tycho/core/p2/P2ArtifactRepositoryLayout has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0
[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/ProjectBuildingException
Is there any chance that this could be a firewall error? Because I am on a public network currently
The error is because you are trying to build that project using Java 8 (class file 52.0) and some of its dependencies requires Java 11 (class file version 55.0).
See:
https://www.java.com/releases/
https://en.wikipedia.org/wiki/Java_class_file#General_layout
Related
Im trying to start a project on play in IntelliJ IDEA Ultimate MacBook Pro on M1, I get the following error in the console:
[error] java.lang.UnsatisfiedLinkError:
/Users/username/Library/Caches/JNA/temp/jna2878211531869408345.tmp:
dlopen(/Users/username/Library/Caches/JNA/temp/jna2878211531869408345.tmp,
0x0001): tried:
'/Users/username/Library/Caches/JNA/temp/jna2878211531869408345.tmp'
(fat file, but missing compatible architecture (have 'i386,x86_64',
need 'arm64e')), '/usr/lib/jna2878211531869408345.tmp' (no such file)
I tried to reinstall the JDK on the arm architecture after deleting all the JDKs, it did not help
What needs to be tricked to fix this?
Full StackTrace:
[error] java.lang.UnsatisfiedLinkError: /Users/romangoltsov/Library/Caches/JNA/temp/jna2878211531869408345.tmp: dlopen(/Users/romangoltsov/Library/Caches/JNA/temp/jna2878211531869408345.tmp, 0x0001): tried: '/Users/romangoltsov/Library/Caches/JNA/temp/jna2878211531869408345.tmp' (fat file, but missing compatible architecture (have 'i386,x86_64', need 'arm64e')), '/usr/lib/jna2878211531869408345.tmp' (no such file)
[error] at java.base/java.lang.ClassLoader$NativeLibrary.load0(Native Method)
[error] at java.base/java.lang.ClassLoader$NativeLibrary.load(ClassLoader.java:2442)
[error] at java.base/java.lang.ClassLoader$NativeLibrary.loadLibrary(ClassLoader.java:2498)
[error] at java.base/java.lang.ClassLoader.loadLibrary0(ClassLoader.java:2694)
[error] at java.base/java.lang.ClassLoader.loadLibrary(ClassLoader.java:2627)
[error] at java.base/java.lang.Runtime.load0(Runtime.java:768)
[error] at java.base/java.lang.System.load(System.java:1837)
[error] at com.sun.jna.Native.loadNativeDispatchLibraryFromClasspath(Native.java:1018)
[error] at com.sun.jna.Native.loadNativeDispatchLibrary(Native.java:988)
[error] at com.sun.jna.Native.<clinit>(Native.java:195)
[error] at io.methvin.watchservice.jna.CarbonAPI.<clinit>(CarbonAPI.java:19)
[error] at io.methvin.watchservice.jna.CFStringRef.toCFString(CFStringRef.java:23)
[error] at io.methvin.watchservice.MacOSXListeningWatchService.register(MacOSXListeningWatchService.java:101)
[error] at io.methvin.watchservice.WatchablePath.register(WatchablePath.java:50)
[error] at io.methvin.watcher.DirectoryWatcher.register(DirectoryWatcher.java:352)
[error] at io.methvin.watcher.DirectoryWatcher.registerAll(DirectoryWatcher.java:317)
[error] at io.methvin.watcher.DirectoryWatcher.<init>(DirectoryWatcher.java:167)
[error] at io.methvin.watcher.DirectoryWatcher$Builder.build(DirectoryWatcher.java:118)
[error] at play.dev.filewatch.DefaultFileWatchService.watch(DefaultFileWatchService.scala:38)
[error] at play.dev.filewatch.FileWatchService$$anon$1.watch(FileWatchService.scala:87)
[error] at play.runsupport.Reloader.<init>(Reloader.scala:414)
[error] at play.runsupport.Reloader$.reloader$lzycompute$1(Reloader.scala:259)
[error] at play.runsupport.Reloader$.play$runsupport$Reloader$$reloader$1(Reloader.scala:251)
[error] at play.runsupport.Reloader$.startDevMode(Reloader.scala:271)
[error] at play.sbt.run.PlayRun$.devModeServer$lzycompute$1(PlayRun.scala:99)
[error] at play.sbt.run.PlayRun$.devModeServer$1(PlayRun.scala:83)
[error] at play.sbt.run.PlayRun$.$anonfun$playRunTask$3(PlayRun.scala:106)
[error] at play.sbt.run.PlayRun$.$anonfun$playRunTask$3$adapted(PlayRun.scala:68)
[error] at scala.Function1.$anonfun$compose$1(Function1.scala:49)
[error] stack trace is suppressed; run 'last Compile / run' for the full output
[error] (Compile / run) java.lang.UnsatisfiedLinkError: /Users/romangoltsov/Library/Caches/JNA/temp/jna2878211531869408345.tmp: dlopen(/Users/romangoltsov/Library/Caches/JNA/temp/jna2878211531869408345.tmp, 0x0001): tried: '/Users/romangoltsov/Library/Caches/JNA/temp/jna2878211531869408345.tmp' (fat file, but missing compatible architecture (have 'i386,x86_64', need 'arm64e')), '/usr/lib/jna2878211531869408345.tmp' (no such file)
Found a solution:
Inside sbt 1.4.6 there is a JNA library version 5.5.0, which apparently does not have the necessary files for the arm64 architecture processor
Raising the sbt version to 1.6.2 helped
I am compling dbeaver-7.2.2 on mips64el platform using the command "mvn package -DskipTests=true". it fails and displays error as follws:
[ERROR] Failed to execute goal org.eclipse.tycho:tycho-compiler-plugin:1.7.0:compile (default-compile) on project org.jkiss.dbeaver.ui: Compilation failure: Compilation failure:
[ERROR] /root/dbeaver-7.2.2/plugins/org.jkiss.dbeaver.ui/src/org/jkiss/dbeaver/ui/properties/PropertyTreeViewer.java:
[ERROR] /*
[ERROR] ^
[ERROR] The type org.eclipse.swt.widgets.Control cannot be resolved. It is indirectly referenced from required .class files
[ERROR] /root/dbeaver-7.2.2/plugins/org.jkiss.dbeaver.ui/src/org/jkiss/dbeaver/ui/properties/PropertyTreeViewer.java:[1101]
[ERROR] private class SortListener implements Listener {
[ERROR] ^^^^^^^^
[ERROR] Listener cannot be resolved to a type
[ERROR] /root/dbeaver-7.2.2/plugins/org.jkiss.dbeaver.ui/src/org/jkiss/dbeaver/ui/properties/PropertyTreeViewer.java:[1173]
[ERROR] class PaintListener implements Listener {
[ERROR] ^^^^^^^^
[ERROR] Listener cannot be resolved to a type
[ERROR] 3 problems (3 errors)
[ERROR] -> [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/MojoFailureException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR] mvn <goals> -rf :org.jkiss.dbeaver.ui
the class PaintListener belogs to org.eclipse.swt.gtk.linux.mips64el which has been compiled successfully.i have set org.eclipse.swt.gtk.linux.mips64el classpath ,but it stills fail.
dbeaver-7.2.2 source code:https://github.com/dbeaver/dbeaver/releases/tag/7.2.2
[ERROR] The type org.eclipse.swt.widgets.Control cannot be resolved. It is indirectly referenced from required .class files
the class PaintListener belogs to org.eclipse.swt.gtk.linux.mips64el which has been compiled successfully.i have set org.eclipse.swt.gtk.linux.mips64el classpath ,but it stills fail.
Whenever I try to enable auto-import in IntelliJ it always gives me this error:
SBT 'mobile-aggregator' project refresh failed
Error:Error while importing SBT project:[error] at sbt.MainLoop$.$anonfun$runWithNewLog$1(MainLoop.scala:107)
[error] at sbt.io.Using.apply(Using.scala:22)
[error] at sbt.MainLoop$.runWithNewLog(MainLoop.scala:101)
[error] at sbt.MainLoop$.runAndClearLast(MainLoop.scala:57)
[error] at sbt.MainLoop$.runLoggedLoop(MainLoop.scala:42)
[error] at sbt.MainLoop$.runLogged(MainLoop.scala:34)
[error] at sbt.StandardMain$.runManaged(Main.scala:113)
[error] at sbt.xMain.run(Main.scala:76)
[error] at xsbt.boot.Launch$$anonfun$run$1.apply(Launch.scala:109)
[error] at xsbt.boot.Launch$.withContextLoader(Launch.scala:128)
[error] at xsbt.boot.Launch$.run(Launch.scala:109)
[error] at xsbt.boot.Launch$$anonfun$apply$1.apply(Launch.scala:35)
[error] at xsbt.boot.Launch$.launch(Launch.scala:117)
[error] at xsbt.boot.Launch$.apply(Launch.scala:18)
[error] at xsbt.boot.Boot$.runImpl(Boot.scala:41)
[error] at xsbt.boot.Boot$.main(Boot.scala:17)
[error] at xsbt.boot.Boot.main(Boot.scala)
[error] java.lang.ClassNotFoundException: org.jetbrains.sbt.CreateTasks$
[error] Use 'last' for the full log.
[info] shutting down serverSee complete log in href="file:/C:/Users/Rahman/.IdeaIC2017.2/system/log/sbt.last.log">file:/C:/Users/Rahman/.IdeaIC2017.2/system/log/sbt.last.log
This happens quite a few times when your compiler / editor tries to use your cached project data.
To fix this, perform the following steps:
Exit IntelliJ & Delete .idea folder from the root project folder
Delete target folder from root_project_folder\target & root_project_folder\project\target
Make sure you have a valid name for your project name inside build.sbt. It should be in the following format: name := "projectname"
Again start your intelliJ and reinitialize your project.
Hopefully, that should have solved your problem
I am new to maven installation. While executing a .bat file which installs maven, I am getting the below error. Could you please check :
Launching environment tests
checking Java 4 compile, java 4 run
[ERROR] COMPILATION ERROR :
[ERROR] Failure executing javac, but could not parse the error:
The system cannot find the path specified.
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.3.2:compile (default
-compile) on project devenv-validate: Compilation failure
[ERROR] Failure executing javac, but could not parse the error:
[ERROR] The system cannot find the path specified.
[ERROR] -> [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 arti
cles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
checking Java 4 compile, java 6 run
[ERROR] COMPILATION ERROR :
[ERROR] Failure executing javac, but could not parse the error:
The system cannot find the path specified.
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.3.2:compile (default
-compile) on project devenv-validate: Compilation failure
[ERROR] Failure executing javac, but could not parse the error:
[ERROR] The system cannot find the path specified.
[ERROR] -> [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 arti
cles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
checking Java 6 compile, java 6 run
-------------------------------------------------------
T E S T S
-------------------------------------------------------
Running TestDevEnvValidator
Java version : Actual [1.6.0_20], expected [1.6.0_20]
Java compiler : Actual [6], expected [6]
Tests run: 3, Failures: 0, Errors: 0, Skipped: 0, Time elapsed: 0 sec
Results :
Tests run: 3, Failures: 0, Errors: 0, Skipped: 0
Press any key to continue . . .
Can anyone please have a look and say why it is failing. Thanks in advance.
The system cannot find the path specified.
If you are using Windows, please check if the path specified for system variables: Path, JAVA_HOME, M2_HOME, M2.
Check out this tutorial:
http://www.tutorialspoint.com/maven/maven_environment_setup.htm
I am following the steps as per the Kantega/storm-twitter-workshop project link
but I am stuck at a point. While testing credentials by running the main class in folder cheating
cd cheating
mvn compile exec:java -Dexec.classpathScope=compile -Dexec.mainClass=storm.starter.CheatingTwitterFunTopology
I am getting the below error:
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.0.2:compile (default-compile) on project storm-assignment-solution: Compilation failure
[ERROR] Unable to locate the Javac Compiler in:
[ERROR] /usr/lib/jvm/java-7-openjdk-amd64/jre/../lib/tools.jar
[ERROR] Please ensure you are using JDK 1.4 or above and
[ERROR] not a JRE (the com.sun.tools.javac.Main class is required).
[ERROR] In most cases you can change the location of your Java
[ERROR] installation by setting the JAVA_HOME environment variable.
[ERROR] -> [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/MojoFailureException
Where am I going wrong?
The Error says it all ..
[ERROR] Unable to locate the Javac Compiler in:[ERROR] /usr/lib/jvm/java-7-openjdk-amd64/jre/../lib/tools.jar
[ERROR] Please ensure you are using JDK 1.4 or above and
Looking at your project page found the following
1) It uses 2 maven modules namely cheating and storm-assignment and both of them are expected to run under Java 1.6 as found in their pom.xml
Check the pom.xml for both the module has this
<configuration>
<source>1.6</source>
<target>1.6</target>
</configuration>
Make sure you are running with atleast Java 1.6 or Higher