Closed tschaffter closed 2 years ago
The language service for Java has started, though one error is listed:
EDIT: According to this post, this error message is expected and should not affect the extension.
Java IntelliSense is provided by Extension Pack for Java
Popular extensions for Java development that provides Java IntelliSense, debugging, testing, Maven/Gradle support, project management and more
The extension logs shows that there is an issue with the Redhat extension as observed previously.
[2022-09-12 02:10:15.200] [exthost] [info] Extension host with pid 9353 started
[2022-09-12 02:10:15.204] [exthost] [error] Error: EEXIST: file already exists, open '/home/vscode/.vscode-server/data/User/workspaceStorage/5767d82dbf02e38a28c0cab3fa0099c8/vscode.lock'
[2022-09-12 02:10:15.214] [exthost] [info] Lock '/home/vscode/.vscode-server/data/User/workspaceStorage/5767d82dbf02e38a28c0cab3fa0099c8/vscode.lock': Could not acquire lock, checking if the file is stale.
[2022-09-12 02:10:15.217] [exthost] [info] Lock '/home/vscode/.vscode-server/data/User/workspaceStorage/5767d82dbf02e38a28c0cab3fa0099c8/vscode.lock': The lockfile is scheduled to be released in 1385 ms.
[2022-09-12 02:10:15.269] [exthost] [info] ExtensionService#_doActivateExtension vscode.configuration-editing, startup: false, activationEvent: 'onLanguage:jsonc'
[2022-09-12 02:10:15.274] [exthost] [info] ExtensionService#_doActivateExtension vscode.json-language-features, startup: false, activationEvent: 'onLanguage:jsonc'
[2022-09-12 02:10:15.326] [exthost] [info] ExtensionService#_doActivateExtension vscode.typescript-language-features, startup: false, activationEvent: 'onLanguage:jsonc'
[2022-09-12 02:10:15.358] [exthost] [info] ExtensionService#_doActivateExtension webhint.vscode-webhint, startup: false, activationEvent: 'onLanguage:jsonc'
[2022-09-12 02:10:15.378] [exthost] [info] ExtensionService#_doActivateExtension vscode.debug-auto-launch, startup: true, activationEvent: '*'
[2022-09-12 02:10:15.381] [exthost] [info] ExtensionService#_doActivateExtension vscode.git-base, startup: true, activationEvent: '*', root cause: vscode.git
[2022-09-12 02:10:15.385] [exthost] [info] ExtensionService#_doActivateExtension vscode.ipynb, startup: true, activationEvent: '*'
[2022-09-12 02:10:15.396] [exthost] [info] ExtensionService#_doActivateExtension firsttris.vscode-jest-runner, startup: true, activationEvent: '*'
[2022-09-12 02:10:15.445] [exthost] [info] ExtensionService#_doActivateExtension mhutchie.git-graph, startup: true, activationEvent: '*'
[2022-09-12 02:10:15.459] [exthost] [info] ExtensionService#_doActivateExtension mtxr.sqltools, startup: true, activationEvent: '*'
[2022-09-12 02:10:15.522] [exthost] [info] ExtensionService#_doActivateExtension vscode.npm, startup: true, activationEvent: 'workspaceContains:package.json'
[2022-09-12 02:10:15.547] [exthost] [info] ExtensionService#_doActivateExtension redhat.java, startup: true, activationEvent: 'workspaceContains:build.gradle'
[2022-09-12 02:10:15.650] [exthost] [info] ExtensionService#_doActivateExtension vscjava.vscode-gradle, startup: true, activationEvent: 'workspaceContains:build.gradle'
[2022-09-12 02:10:15.750] [exthost] [info] ExtensionService#_doActivateExtension vscjava.vscode-java-dependency, startup: true, activationEvent: 'workspaceContains:build.gradle'
[2022-09-12 02:10:15.815] [exthost] [info] ExtensionService#_doActivateExtension vscjava.vscode-java-pack, startup: true, activationEvent: 'workspaceContains:build.gradle'
[2022-09-12 02:10:15.878] [exthost] [info] ExtensionService#_doActivateExtension GabrielBB.vscode-lombok, startup: true, activationEvent: 'workspaceContains:build.gradle'
[2022-09-12 02:10:15.989] [exthost] [info] ExtensionService#_doActivateExtension vscjava.vscode-maven, startup: true, activationEvent: 'workspaceContains:**/pom.xml'
[2022-09-12 02:10:16.108] [exthost] [info] ExtensionService#_doActivateExtension GitHub.vscode-pull-request-github, startup: true, activationEvent: '*'
[2022-09-12 02:10:16.190] [exthost] [error] Error: ENOENT: no such file or directory, stat '/home/vscode/.vscode-server/data/User/workspaceStorage/5767d82dbf02e38a28c0cab3fa0099c8/vscode.lock'
[2022-09-12 02:10:16.190] [exthost] [info] Lock '/home/vscode/.vscode-server/data/User/workspaceStorage/5767d82dbf02e38a28c0cab3fa0099c8/vscode.lock': Deleting a stale lock.
[2022-09-12 02:10:16.205] [exthost] [info] Lock '/home/vscode/.vscode-server/data/User/workspaceStorage/5767d82dbf02e38a28c0cab3fa0099c8/vscode.lock': Lock acquired.
[2022-09-12 02:10:16.315] [exthost] [info] ExtensionService#_doActivateExtension vscode.git, startup: true, activationEvent: '*'
[2022-09-12 02:10:16.370] [exthost] [info] ExtensionService#_doActivateExtension vscode.github, startup: true, activationEvent: '*'
[2022-09-12 02:10:16.376] [exthost] [info] ExtensionService#_doActivateExtension mtxr.sqltools-driver-mysql, startup: true, activationEvent: '*'
[2022-09-12 02:10:16.377] [exthost] [info] ExtensionService#_doActivateExtension mtxr.sqltools-driver-pg, startup: true, activationEvent: '*'
[2022-09-12 02:10:16.413] [exthost] [warning] [vscjava.vscode-gradle] Accessing a resource scoped configuration without providing a resource is not expected. To get the effective value for '[java]', provide the URI of a resource or 'null' for any resource.
[2022-09-12 02:10:16.902] [exthost] [info] ExtensionService#_doActivateExtension VisualStudioExptTeam.vscodeintellicode, startup: false, activationEvent: 'onLanguage:java'
[2022-09-12 02:10:17.042] [exthost] [info] ExtensionService#_doActivateExtension vscjava.vscode-java-debug, startup: false, activationEvent: 'onLanguage:java'
[2022-09-12 02:10:17.483] [exthost] [warning] [redhat.java] Accessing a resource scoped configuration without providing a resource is not expected. To get the effective value for '[java]', provide the URI of a resource or 'null' for any resource.
[2022-09-12 02:10:17.518] [exthost] [warning] [redhat.java] Accessing a resource scoped configuration without providing a resource is not expected. To get the effective value for '[java]', provide the URI of a resource or 'null' for any resource.
[2022-09-12 02:10:20.629] [exthost] [info] ExtensionService#_doActivateExtension shengchen.vscode-checkstyle, startup: false, activationEvent: 'onLanguage:java'
[2022-09-12 02:10:20.707] [exthost] [info] ExtensionService#_doActivateExtension vscode.emmet, startup: false, activationEvent: 'onStartupFinished'
[2022-09-12 02:10:20.732] [exthost] [info] ExtensionService#_doActivateExtension vscode.merge-conflict, startup: false, activationEvent: 'onStartupFinished'
[2022-09-12 02:10:20.737] [exthost] [info] ExtensionService#_doActivateExtension dbaeumer.vscode-eslint, startup: false, activationEvent: 'onStartupFinished'
[2022-09-12 02:10:20.778] [exthost] [info] ExtensionService#_doActivateExtension esbenp.prettier-vscode, startup: false, activationEvent: 'onStartupFinished'
[2022-09-12 02:10:20.973] [exthost] [info] ExtensionService#_doActivateExtension nrwl.angular-console, startup: false, activationEvent: 'onStartupFinished'
[2022-09-12 02:10:21.528] [exthost] [info] ExtensionService#_doActivateExtension ritwickdey.LiveServer, startup: false, activationEvent: 'onStartupFinished'
[2022-09-12 02:10:21.537] [exthost] [info] Eager extensions activated
[2022-09-12 02:10:21.888] [exthost] [error] [redhat.java] provider FAILED
[2022-09-12 02:10:21.890] [exthost] [error] Error: The request (id: 1, method: 'textDocument/documentSymbol') has been cancelled
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034658
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034952
at Immediate.<anonymous> (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1035317)
at processImmediate (node:internal/timers:466:21)
[2022-09-12 02:10:21.891] [exthost] [error] [redhat.java] provider FAILED
[2022-09-12 02:10:21.891] [exthost] [error] Error: The request (id: 3, method: 'textDocument/hover') has been cancelled
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034658
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034952
at Immediate.<anonymous> (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1035317)
at processImmediate (node:internal/timers:466:21)
[2022-09-12 02:10:42.911] [exthost] [info] ExtensionService#_doActivateExtension vscode.references-view, startup: false, activationEvent: 'onCommand:references-view.findReferences'
[2022-09-12 02:15:35.446] [exthost] [info] ExtensionService#_doActivateExtension vscode.extension-editing, startup: false, activationEvent: 'onLanguage:markdown'
[2022-09-12 02:15:35.462] [exthost] [info] ExtensionService#_doActivateExtension vscode.markdown-language-features, startup: false, activationEvent: 'onLanguage:markdown'
[2022-09-12 02:15:35.609] [exthost] [info] ExtensionService#_doActivateExtension humao.rest-client, startup: false, activationEvent: 'onLanguage:markdown'
[2022-09-12 02:15:36.008] [exthost] [info] ExtensionService#_doActivateExtension vscode.markdown-math, startup: false, activationEvent: 'api', root cause: vscode.markdown-language-features
See also:
Slightly different error when disabling and enabling java extensions:
[2022-09-12 02:47:57.498] [exthost] [info] ExtensionService#_doActivateExtension vscjava.vscode-java-test, startup: false, activationEvent: 'onLanguage:java'
[2022-09-12 02:47:58.661] [exthost] [error] [redhat.java] provider FAILED
[2022-09-12 02:47:58.662] [exthost] [error] Error: Connection got disposed.
at Object.dispose (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1040826)
at Object.dispose (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:887823)
at b.handleConnectionClosed (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:888011)
at b.handleConnectionClosed (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:961642)
at t (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:886125)
at invoke (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1042452)
at s.fire (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1043213)
at Q (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1029965)
at invoke (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1042452)
at s.fire (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1043213)
at p.fireClose (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1051104)
at Socket.<anonymous> (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1052689)
at Socket.emit (node:events:538:35)
at Socket.emit (node:domain:475:12)
at Pipe.<anonymous> (node:net:687:12)
Another batch of errors:
[2022-09-12 02:58:18.054] [exthost] [info] ExtensionService#_doActivateExtension vscjava.vscode-java-dependency, startup: false, activationEvent: 'onLanguage:java'
[2022-09-12 02:58:18.121] [exthost] [info] ExtensionService#_doActivateExtension vscjava.vscode-java-debug, startup: false, activationEvent: 'onLanguage:java'
[2022-09-12 02:58:18.168] [exthost] [info] ExtensionService#_doActivateExtension VisualStudioExptTeam.vscodeintellicode, startup: false, activationEvent: 'onLanguage:java'
[2022-09-12 02:58:18.260] [exthost] [info] ExtensionService#_doActivateExtension vscjava.vscode-java-pack, startup: false, activationEvent: 'onLanguage:java'
[2022-09-12 02:58:18.414] [exthost] [info] ExtensionService#_doActivateExtension vscjava.vscode-maven, startup: false, activationEvent: 'workspaceContains:**/pom.xml'
[2022-09-12 02:58:42.527] [exthost] [info] ExtensionService#_doActivateExtension vscjava.vscode-java-test, startup: false, activationEvent: 'onLanguage:java'
[2022-09-12 02:58:43.232] [exthost] [error] Error: No delegateCommandHandler for java.maven.initializeSearcher
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034658
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034952
at Immediate.<anonymous> (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1035317)
at processImmediate (node:internal/timers:466:21) java.execute.workspaceCommand {"value":"redhat.java","_lower":"redhat.java"}
[2022-09-12 02:58:43.601] [exthost] [error] Error: No delegateCommandHandler for java.maven.initializeSearcher
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034658
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034952
at Immediate.<anonymous> (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1035317)
at processImmediate (node:internal/timers:466:21) java.execute.workspaceCommand {"value":"redhat.java","_lower":"redhat.java"}
[2022-09-12 02:58:43.802] [exthost] [error] Error: No delegateCommandHandler for java.intellicode.enable
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034658
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034952
at Immediate.<anonymous> (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1035317)
at processImmediate (node:internal/timers:466:21) java.execute.workspaceCommand {"value":"redhat.java","_lower":"redhat.java"}
[2022-09-12 02:58:43.803] [exthost] [error] Error: No delegateCommandHandler for vscode.java.test.get.testpath
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034658
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034952
at Immediate.<anonymous> (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1035317)
at processImmediate (node:internal/timers:466:21) java.execute.workspaceCommand {"value":"redhat.java","_lower":"redhat.java"}
[2022-09-12 02:58:43.804] [exthost] [error] Error: No delegateCommandHandler for vscode.java.test.get.testpath
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034658
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034952
at Immediate.<anonymous> (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1035317)
at processImmediate (node:internal/timers:466:21) java.execute.workspaceCommand {"value":"redhat.java","_lower":"redhat.java"}
[2022-09-12 02:58:43.838] [exthost] [error] Error: No delegateCommandHandler for java.maven.initializeSearcher
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034658
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034952
at Immediate.<anonymous> (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1035317)
at processImmediate (node:internal/timers:466:21) java.execute.workspaceCommand {"value":"redhat.java","_lower":"redhat.java"}
[2022-09-12 02:58:43.839] [exthost] [error] Error: No delegateCommandHandler for java.maven.initializeSearcher
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034658
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034952
at Immediate.<anonymous> (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1035317)
at processImmediate (node:internal/timers:466:21) java.execute.workspaceCommand {"value":"redhat.java","_lower":"redhat.java"}
[2022-09-12 02:58:44.061] [exthost] [error] Error: No delegateCommandHandler for vscode.java.resolveMainMethod
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034658
at /home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1034952
at Immediate.<anonymous> (/home/vscode/.vscode-server/extensions/redhat.java-1.10.0-linux-x64/dist/extension.js:2:1035317)
at processImmediate (node:internal/timers:466:21) java.execute.workspaceCommand {"value":"redhat.java","_lower":"redhat.java"}
A similar error "[ ] provider FAILED" happened to someone after VS Code auto updated. A clean install of a previous version of VS Code may help. I already tried previous versions of VS Code on Windows but didn't clean anything before the install. I should try on macOS using the instructions provided in the link.
See also:
When using "java.trace.server": "verbose",
is VS Code settings.json
More logs from a workspace where I removed all apps but the user service:
[Trace - 7:25:37 PM] Sending request 'textDocument/hover - (14)'.
Params: {
"textDocument": {
"uri": "file:///workspaces/redhat/apps/challenge-user-service/src/main/java/org/sagebionetworks/challenge/ChallengeUserServiceApplication.java"
},
"position": {
"line": 10,
"character": 49
}
}
[Trace - 7:25:37 PM] Received response 'textDocument/hover - (14)' in 19ms.
Result: {
"contents": ""
}
[Trace - 7:25:39 PM] Sending request 'shutdown - (15)'.
[Trace - 7:25:39 PM] Received notification 'window/logMessage'.
Params: {
"type": 1,
"message": "Sep 12, 2022, 7:25:39 PM Workspace was not properly initialized or has already shutdown.\nWorkspace was not properly initialized or has already shutdown.\njava.lang.Exception: Workspace was not properly initialized or has already shutdown.\n\tat org.eclipse.core.internal.resources.ResourceException.provideStackTrace(ResourceException.java:42)\n\tat org.eclipse.core.internal.resources.ResourceException.<init>(ResourceException.java:38)\n\tat org.eclipse.core.internal.resources.Workspace.getWorkManager(Workspace.java:1817)\n\tat org.eclipse.core.internal.resources.Workspace.endOperation(Workspace.java:1481)\n\tat org.eclipse.core.internal.events.AutoBuildJob$AutoBuildOffJob.run(AutoBuildJob.java:333)\n\tat org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)\n"
}
[Error - 7:25:39 PM] Sep 12, 2022, 7:25:39 PM Workspace was not properly initialized or has already shutdown.
Workspace was not properly initialized or has already shutdown.
java.lang.Exception: Workspace was not properly initialized or has already shutdown.
at org.eclipse.core.internal.resources.ResourceException.provideStackTrace(ResourceException.java:42)
at org.eclipse.core.internal.resources.ResourceException.<init>(ResourceException.java:38)
at org.eclipse.core.internal.resources.Workspace.getWorkManager(Workspace.java:1817)
at org.eclipse.core.internal.resources.Workspace.endOperation(Workspace.java:1481)
at org.eclipse.core.internal.events.AutoBuildJob$AutoBuildOffJob.run(AutoBuildJob.java:333)
at org.eclipse.core.internal.jobs.Worker.run(Worker.java:63)
[Error - 7:25:40 PM] Connection to server got closed. Server will not be restarted.
.devcontainer
and .vscode
folders to the user service app folder.[Trace - 8:32:22 PM] Sending request 'shutdown - (55)'.
[Error - 8:32:23 PM] Connection to server got closed. Server will not be restarted.
Connection got disposed.
I tried opening again from the workspace folder and the syntax highlighting works. This error was still displayed: Workspace was not properly initialized or has already shutdown.
. This is working in a workspace with only one gradle app, but not in the full workspace.
The syntax highlight works in a workspace that includes one Gradle project and one Maven project.
I added back all the apps to the workspace "redhat" and syntax highlight works.
What is the different with the current "redhat" workspace and the original workspace? Try deep cleanup of the original workspace.
The presence of the empty file build.gradle
in the workspace folder throws off the Java syntax highlight/IntelliSense. Removing it, possibly along other Gradle files recently added in the workspace folder, solves the issue.
import
statement are not resolved (here in white, normally in a different color to indicate that they are clickable because definition have been found).