Code Monkey home page Code Monkey logo

Comments (7)

fwcd avatar fwcd commented on May 23, 2024

This might indeed be related to #5. Could you please paste the output stack trace if there is one? It should look similar to this:

from kotlin-language-server.

suenfung avatar suenfung commented on May 23, 2024

After showing few lines in output, a dialog shows:

screen shot 2018-07-31 at 6 14 03 pm

from kotlin-language-server.

fwcd avatar fwcd commented on May 23, 2024

@suenfung That's unfortunate. Could you please paste the lines from the output? Which OS are you running on?

from kotlin-language-server.

suenfung avatar suenfung commented on May 23, 2024

@fwcd
OS:
macOS High Sierra Version 10.13.5

Output Log:
[INFO] main main Connected to client
[INFO] client main Adding workspace file:///Users/user_dummy/Documents/projects/project_dummy to source path
[INFO] client main Adding 242 files under /Users/user_dummy/Documents/projects/project_dummy to source path
[INFO] client main Searching for dependencies in workspace root /Users/user_dummy/Documents/projects/project_dummy
[SEVERE] client org.ec Internal error: java.lang.reflect.InvocationTargetException
lipse.
lsp4j.
jsonrp
c.Remo
teEndp
oint

java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
at org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint.lambda$null$0(GenericEndpoint.java:63)
at org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint.request(GenericEndpoint.java:116)
at org.eclipse.lsp4j.jsonrpc.RemoteEndpoint.handleRequest(RemoteEndpoint.java:257)
at org.eclipse.lsp4j.jsonrpc.RemoteEndpoint.consume(RemoteEndpoint.java:186)
at org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer.handleMessage(StreamMessageProducer.java:188)
at org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer.listen(StreamMessageProducer.java:90)
at org.eclipse.lsp4j.jsonrpc.json.ConcurrentMessageProcessor.run(ConcurrentMessageProcessor.java:95)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint.lambda$null$0(GenericEndpoint.java:61)
... 11 more
Caused by: kotlin.KotlinNullPointerException
at org.javacs.kt.classpath.FindClassPathKt.mvnCommand(findClassPath.kt:215)
at org.javacs.kt.classpath.FindClassPathKt.generateMavenDependencyList(findClassPath.kt:70)
at org.javacs.kt.classpath.FindClassPathKt.readPom(findClassPath.kt:55)
at org.javacs.kt.classpath.FindClassPathKt.readProjectFile(findClassPath.kt:41)
at org.javacs.kt.classpath.FindClassPathKt.findClassPath(findClassPath.kt:24)
at org.javacs.kt.CompilerClassPath.refresh(CompilerClassPath.kt:13)
at org.javacs.kt.CompilerClassPath.addWorkspaceRoot(CompilerClassPath.kt:33)
at org.javacs.kt.KotlinLanguageServer.initialize(KotlinLanguageServer.kt:62)
... 16 more

[Error - 11:24:49 AM] Server initialization failed.
Message: Internal error.
Code: -32603
java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
at org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint.lambda$null$0(GenericEndpoint.java:63)
at org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint.request(GenericEndpoint.java:116)
at org.eclipse.lsp4j.jsonrpc.RemoteEndpoint.handleRequest(RemoteEndpoint.java:257)
at org.eclipse.lsp4j.jsonrpc.RemoteEndpoint.consume(RemoteEndpoint.java:186)
at org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer.handleMessage(StreamMessageProducer.java:188)
at org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer.listen(StreamMessageProducer.java:90)
at org.eclipse.lsp4j.jsonrpc.json.ConcurrentMessageProcessor.run(ConcurrentMessageProcessor.java:95)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint.lambda$null$0(GenericEndpoint.java:61)
... 11 more
Caused by: kotlin.KotlinNullPointerException
at org.javacs.kt.classpath.FindClassPathKt.mvnCommand(findClassPath.kt:215)
at org.javacs.kt.classpath.FindClassPathKt.generateMavenDependencyList(findClassPath.kt:70)
at org.javacs.kt.classpath.FindClassPathKt.readPom(findClassPath.kt:55)
at org.javacs.kt.classpath.FindClassPathKt.readProjectFile(findClassPath.kt:41)
at org.javacs.kt.classpath.FindClassPathKt.findClassPath(findClassPath.kt:24)
at org.javacs.kt.CompilerClassPath.refresh(CompilerClassPath.kt:13)
at org.javacs.kt.CompilerClassPath.addWorkspaceRoot(CompilerClassPath.kt:33)
at org.javacs.kt.KotlinLanguageServer.initialize(KotlinLanguageServer.kt:62)
... 16 more

from kotlin-language-server.

fwcd avatar fwcd commented on May 23, 2024

@suenfung Thanks, this seems to be an issue with the classpath resolver. Do you have any pom.xml files in your project, but not Maven installed (on your command line PATH)?

from kotlin-language-server.

safarmer avatar safarmer commented on May 23, 2024

I am seeing the same issue with a Gradle project (Spring Boot) that seems to unpack a pox.xml in the top level build/ directory. I do not have Maven installed, and I think this file will add invalid dependencies anyway.

It seems that for my issue, a workaround is to run ./gradlew clean before opening the project folder/workspace.

from kotlin-language-server.

mattdkerr avatar mattdkerr commented on May 23, 2024

I have the same issue, but I am using Visual Studio Code latest and I found the logs for the extension in my AppData directory structure (I'm on Windows):

`[Info - 1:51:13 p.m.] main Connected to client
[Info - 1:51:13 p.m.] client Adding workspace file:///c%3A/ws/roolz to source path
[Info - 1:51:13 p.m.] client Adding 57 files under c:\ws\roolz to source path
[Info - 1:51:13 p.m.] client Searching for dependencies in workspace root c:\ws\roolz
[Info - 1:51:13 p.m.] client Resolving dependencies for rlzactor through CLI...
[Info - 1:51:14 p.m.] client Creating temporary gradle file C:\Users\mkerr\AppData\Local\Temp\1\classpath9622557532420025474.gradle
[Info - 1:51:14 p.m.] client Found gradle.exe at C:\ProgramData\chocolatey\bin\gradle.exe
[Info - 1:51:20 p.m.] client Successfully resolved dependencies using Gradle dependencies CLI
[Info - 1:51:20 p.m.] client Resolving dependencies for rlzprotocol through CLI...
[Info - 1:51:20 p.m.] client Creating temporary gradle file C:\Users\mkerr\AppData\Local\Temp\1\classpath3687492058504834792.gradle
[Info - 1:51:20 p.m.] client Found gradle.exe at C:\ProgramData\chocolatey\bin\gradle.exe
[Info - 1:51:27 p.m.] client Successfully resolved dependencies using Gradle dependencies CLI
[Info - 1:51:28 p.m.] client Resolving dependencies for roolz through CLI...
[Info - 1:51:28 p.m.] client Creating temporary gradle file C:\Users\mkerr\AppData\Local\Temp\1\classpath12912053875673474220.gradle
[Info - 1:51:35 p.m.] client Successfully resolved dependencies using Gradle dependencies CLI
Jun. 06, 2019 1:51:35 P.M. org.eclipse.lsp4j.jsonrpc.RemoteEndpoint fallbackResponseError
SEVERE: Internal error: java.lang.reflect.InvocationTargetException
java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
at org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint.lambda$null$0(GenericEndpoint.java:67)
at org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint.request(GenericEndpoint.java:120)
at org.eclipse.lsp4j.jsonrpc.RemoteEndpoint.handleRequest(RemoteEndpoint.java:261)
at org.eclipse.lsp4j.jsonrpc.RemoteEndpoint.consume(RemoteEndpoint.java:190)
at org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer.handleMessage(StreamMessageProducer.java:192)
at org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer.listen(StreamMessageProducer.java:94)
at org.eclipse.lsp4j.jsonrpc.json.ConcurrentMessageProcessor.run(ConcurrentMessageProcessor.java:99)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.lang.reflect.InvocationTargetException
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint.lambda$null$0(GenericEndpoint.java:65)
... 11 more
Caused by: kotlin.KotlinNullPointerException
at org.javacs.kt.classpath.FindClassPathKt.mvnCommand(FindClassPath.kt:268)
at org.javacs.kt.classpath.FindClassPathKt.generateMavenDependencyList(FindClassPath.kt:123)
at org.javacs.kt.classpath.FindClassPathKt.readPom(FindClassPath.kt:108)
at org.javacs.kt.classpath.FindClassPathKt.readProjectFile(FindClassPath.kt:94)
at org.javacs.kt.classpath.FindClassPathKt.findClassPath(FindClassPath.kt:25)
at org.javacs.kt.CompilerClassPath.refresh(CompilerClassPath.kt:13)
at org.javacs.kt.CompilerClassPath.addWorkspaceRoot(CompilerClassPath.kt:33)
at org.javacs.kt.KotlinLanguageServer.initialize(KotlinLanguageServer.kt:65)
... 16 more

[Error - 1:51:35 p.m.] client Internal error: java.lang.reflect.InvocationTargetException
[Error - 1:51:35 p.m.] Server initialization failed.
Message: Internal error.
Code: -32603
java.lang.RuntimeException: java.lang.reflect.InvocationTargetException
at org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint.lambda$null$0(GenericEndpoint.java:67)
at org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint.request(GenericEndpoint.java:120)
at org.eclipse.lsp4j.jsonrpc.RemoteEndpoint.handleRequest(RemoteEndpoint.java:261)
at org.eclipse.lsp4j.jsonrpc.RemoteEndpoint.consume(RemoteEndpoint.java:190)
at org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer.handleMessage(StreamMessageProducer.java:192)
at org.eclipse.lsp4j.jsonrpc.json.StreamMessageProducer.listen(StreamMessageProducer.java:94)
at org.eclipse.lsp4j.jsonrpc.json.ConcurrentMessageProcessor.run(ConcurrentMessageProcessor.java:99)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)
Caused by: java.lang.reflect.InvocationTargetException
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at org.eclipse.lsp4j.jsonrpc.services.GenericEndpoint.lambda$null$0(GenericEndpoint.java:65)
... 11 more
Caused by: kotlin.KotlinNullPointerException
at org.javacs.kt.classpath.FindClassPathKt.mvnCommand(FindClassPath.kt:268)
at org.javacs.kt.classpath.FindClassPathKt.generateMavenDependencyList(FindClassPath.kt:123)
at org.javacs.kt.classpath.FindClassPathKt.readPom(FindClassPath.kt:108)
at org.javacs.kt.classpath.FindClassPathKt.readProjectFile(FindClassPath.kt:94)
at org.javacs.kt.classpath.FindClassPathKt.findClassPath(FindClassPath.kt:25)
at org.javacs.kt.CompilerClassPath.refresh(CompilerClassPath.kt:13)
at org.javacs.kt.CompilerClassPath.addWorkspaceRoot(CompilerClassPath.kt:33)
at org.javacs.kt.KotlinLanguageServer.initialize(KotlinLanguageServer.kt:65)
... 16 more `

from kotlin-language-server.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.