ABckh / zed-java-eclipse-jdtls

Eclipse Public License 2.0
29 stars 3 forks source link

Extension doesn't work #26

Closed liukaizheng closed 2 months ago

liukaizheng commented 2 months ago

There is the log file:

2024-09-13T10:15:53.0294603+08:00 [INFO] ========== starting zed ==========
2024-09-13T10:15:53.1555528+08:00 [INFO] Use Microsoft YaHei UI as UI font.
2024-09-13T10:15:53.1572314+08:00 [INFO] Opening main db
2024-09-13T10:15:53.1669562+08:00 [INFO] Using git binary path: None
2024-09-13T10:15:53.1678568+08:00 [ERROR] SHELL environment variable is not assigned so we can't source login environment variables

Caused by:
    environment variable not found
2024-09-13T10:15:53.2036152+08:00 [INFO] initializing context server client
2024-09-13T10:15:53.2039342+08:00 [INFO] Registering built-in prompt template: content_prompt
2024-09-13T10:15:53.2045039+08:00 [INFO] Registering built-in prompt template: edit_workflow
2024-09-13T10:15:53.2050332+08:00 [INFO] Registering built-in prompt template: step_resolution
2024-09-13T10:15:53.2054909+08:00 [INFO] Registering built-in prompt template: terminal_assistant_prompt
2024-09-13T10:15:53.2060444+08:00 [INFO] No prompt template overrides directory found at C:\Users\qingxun\AppData\Local\Zed\prompt_overrides. Using built-in prompts.
2024-09-13T10:15:53.2065565+08:00 [INFO] extensions updated. loading 7, reloading 0, unloading 0
2024-09-13T10:15:53.2183564+08:00 [INFO] set status on client 0: Authenticating
2024-09-13T10:15:53.2187519+08:00 [INFO] set status on client 166153: Connecting
2024-09-13T10:15:53.2194364+08:00 [INFO] Opening main db
2024-09-13T10:15:53.2214521+08:00 [ERROR] Error { kind: Generic("Input watch path is neither a file nor a directory."), paths: [] }
2024-09-13T10:15:53.2283095+08:00 [INFO] building git repository, `.git` path in the worktree: ".git"
2024-09-13T10:15:53.2411622+08:00 [INFO] Enabling color space support
2024-09-13T10:15:53.2531123+08:00 [INFO] Adapter: "Intel(R) UHD Graphics 630"
2024-09-13T10:15:53.253604+08:00 [INFO] No ray tracing extensions are supported
2024-09-13T10:15:53.2610272+08:00 [WARN] Requested size 1x1 is outside of surface capabilities
2024-09-13T10:15:53.2610987+08:00 [ERROR] No composite alpha flag for transparency: OPAQUE | INHERIT
2024-09-13T10:15:53.2611569+08:00 [INFO] Using surface present mode IMMEDIATE
2024-09-13T10:15:53.2612302+08:00 [WARN] Unable to forbid exclusive full screen
2024-09-13T10:15:53.2762847+08:00 [INFO] Creating a descriptor pool for at most 16 sets
2024-09-13T10:15:53.2764034+08:00 [INFO] Creating a descriptor pool for at most 16 sets
2024-09-13T10:15:53.2764874+08:00 [INFO] Initializing Blade pipelines for surface SurfaceInfo { format: Bgra8UnormSrgb, alpha: Ignored }
2024-09-13T10:15:53.2785544+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.2789134+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.2794905+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.2798406+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.2803084+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.2806981+08:00 [INFO] Skip function Some("to_device_position_impl")
2024-09-13T10:15:53.2807853+08:00 [INFO] Skip function Some("to_device_position")
2024-09-13T10:15:53.280883+08:00 [INFO] Skip function Some("to_device_position_transformed")
2024-09-13T10:15:53.2809685+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.2811259+08:00 [INFO] Skip function Some("blend_color")
2024-09-13T10:15:53.2817888+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.2822208+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.2825471+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.2832161+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.2838517+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.2842831+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.284575+08:00 [INFO] Skip function Some("to_device_position_impl")
2024-09-13T10:15:53.2846474+08:00 [INFO] Skip function Some("to_device_position")
2024-09-13T10:15:53.2847098+08:00 [INFO] Skip function Some("to_device_position_transformed")
2024-09-13T10:15:53.2847743+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.2849582+08:00 [INFO] Skip function Some("blend_color")
2024-09-13T10:15:53.2887377+08:00 [ERROR] No composite alpha flag for transparency: OPAQUE | INHERIT
2024-09-13T10:15:53.2888108+08:00 [INFO] Using surface present mode IMMEDIATE
2024-09-13T10:15:53.2888847+08:00 [WARN] Unable to forbid exclusive full screen
2024-09-13T10:15:53.3100715+08:00 [ERROR] No composite alpha flag for transparency: OPAQUE | INHERIT
2024-09-13T10:15:53.3101516+08:00 [INFO] Using surface present mode IMMEDIATE
2024-09-13T10:15:53.3102228+08:00 [WARN] Unable to forbid exclusive full screen
2024-09-13T10:15:53.3577083+08:00 [INFO] Using surface present mode IMMEDIATE
2024-09-13T10:15:53.3577893+08:00 [WARN] Unable to forbid exclusive full screen
2024-09-13T10:15:53.3752259+08:00 [INFO] Initializing Blade pipelines for surface SurfaceInfo { format: Bgra8UnormSrgb, alpha: Ignored }
2024-09-13T10:15:53.3771636+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.3774935+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.3779742+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.3782756+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.3786584+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.3789475+08:00 [INFO] Skip function Some("to_device_position_impl")
2024-09-13T10:15:53.3790097+08:00 [INFO] Skip function Some("to_device_position")
2024-09-13T10:15:53.379071+08:00 [INFO] Skip function Some("to_device_position_transformed")
2024-09-13T10:15:53.3791295+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.3792672+08:00 [INFO] Skip function Some("blend_color")
2024-09-13T10:15:53.3798394+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.3802006+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.380514+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.3811225+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.3817447+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.3821243+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.3824085+08:00 [INFO] Skip function Some("to_device_position_impl")
2024-09-13T10:15:53.3824731+08:00 [INFO] Skip function Some("to_device_position")
2024-09-13T10:15:53.3825346+08:00 [INFO] Skip function Some("to_device_position_transformed")
2024-09-13T10:15:53.3825933+08:00 [INFO] Skip function Some("to_tile_position")
2024-09-13T10:15:53.3827248+08:00 [INFO] Skip function Some("blend_color")
2024-09-13T10:15:53.3839479+08:00 [INFO] Using GPU: GPUSpecs { is_software_emulated: false, device_name: "Intel(R) UHD Graphics 630", driver_name: "Intel Corporation", driver_info: "Intel driver" }
2024-09-13T10:15:53.385086+08:00 [ERROR] Error { kind: Generic("Input watch path is neither a file nor a directory."), paths: [] }
2024-09-13T10:15:53.3949482+08:00 [INFO] Opening main db
2024-09-13T10:15:53.407736+08:00 [INFO] Opening main db
2024-09-13T10:15:53.4105467+08:00 [INFO] Using conpty.dll for pseudoconsole
2024-09-13T10:15:53.4753193+08:00 [INFO] Using surface present mode IMMEDIATE
2024-09-13T10:15:53.4754186+08:00 [WARN] Unable to forbid exclusive full screen
2024-09-13T10:15:53.5298166+08:00 [INFO] Creating texture 0x28fca54d9d8 of size 1024x1024x1 and format R8Unorm, name 'atlas', handle 0
2024-09-13T10:15:53.530336+08:00 [INFO] Creating buffer 0x2900ef47858 of size 65536, name 'chunk-0', handle 1
2024-09-13T10:15:53.5969774+08:00 [INFO] Creating buffer 0x2900ef45c88 of size 65536, name 'chunk-1', handle 2
2024-09-13T10:15:53.6011888+08:00 [INFO] Creating buffer 0x2900ef472c8 of size 4096, name 'chunk-0', handle 3
2024-09-13T10:15:53.6013038+08:00 [INFO] Creating buffer 0x2900ef456f8 of size 5376, name 'chunk-1', handle 4
2024-09-13T10:15:53.6013934+08:00 [INFO] Creating buffer 0x2900ef47de8 of size 14784, name 'chunk-2', handle 5
2024-09-13T10:15:53.6014652+08:00 [INFO] Creating buffer 0x2900ef41f58 of size 4096, name 'chunk-3', handle 6
2024-09-13T10:15:53.6016104+08:00 [INFO] Creating buffer 0x2900ef46218 of size 81984, name 'chunk-4', handle 7
2024-09-13T10:15:53.610085+08:00 [INFO] Creating buffer 0x2900ef419c8 of size 4096, name 'chunk-5', handle 8
2024-09-13T10:15:53.6101843+08:00 [INFO] Creating buffer 0x2900ef48378 of size 5376, name 'chunk-6', handle 9
2024-09-13T10:15:53.6102574+08:00 [INFO] Creating buffer 0x2900ef467a8 of size 14784, name 'chunk-7', handle 10
2024-09-13T10:15:53.6103249+08:00 [INFO] Creating buffer 0x2900ef46d38 of size 4096, name 'chunk-8', handle 11
2024-09-13T10:15:53.6103962+08:00 [INFO] Creating buffer 0x2900ef48908 of size 81984, name 'chunk-9', handle 12
2024-09-13T10:15:53.6380454+08:00 [INFO] Initializing default prettier with plugins {"prettier-plugin-java"}
2024-09-13T10:15:53.6384006+08:00 [INFO] Initializing default prettier with plugins {"prettier-plugin-java"}
2024-09-13T10:15:53.6404991+08:00 [INFO] Node runtime install_if_needed
2024-09-13T10:15:53.687199+08:00 [INFO] Initializing default prettier with plugins {"prettier-plugin-java"}
2024-09-13T10:15:53.6966517+08:00 [INFO] Creating buffer 0x28fca479bb8 of size 45024, name 'chunk-10', handle 13
2024-09-13T10:15:53.6967983+08:00 [INFO] Creating buffer 0x28fca476f38 of size 81984, name 'chunk-11', handle 14
2024-09-13T10:15:53.8776169+08:00 [INFO] Node runtime install_if_needed
2024-09-13T10:15:53.9797148+08:00 [INFO] connected to rpc endpoint https://collab.zed.dev/rpc
2024-09-13T10:15:54.0875741+08:00 [INFO] Node runtime install_if_needed
2024-09-13T10:15:54.2811432+08:00 [INFO] Initializing default prettier with plugins {"prettier-plugin-java"}
2024-09-13T10:15:54.2812726+08:00 [INFO] attempting to start language server "java", path: "E:\\codes\\geom\\grep-java", id: 1
2024-09-13T10:15:54.2847585+08:00 [INFO] Node runtime install_if_needed
2024-09-13T10:15:54.6745628+08:00 [INFO] Node runtime install_if_needed
2024-09-13T10:15:54.7948547+08:00 [INFO] add connection to peer
2024-09-13T10:15:54.7949215+08:00 [INFO] add_connection;
2024-09-13T10:15:54.7950102+08:00 [INFO] waiting for server hello
2024-09-13T10:15:54.8085856+08:00 [INFO] got server hello
2024-09-13T10:15:54.8086957+08:00 [INFO] set status to connected (connection id: ConnectionId { owner_id: 0, id: 0 }, peer id: PeerId { owner_id: 540, id: 5550140 })
2024-09-13T10:15:54.8088004+08:00 [INFO] set status on client 166153: Connected { peer_id: PeerId { owner_id: 540, id: 5550140 }, connection_id: ConnectionId { owner_id: 0, id: 0 } }
2024-09-13T10:15:54.8314934+08:00 [INFO] starting language server process. binary path: "C:\\Users\\qingxun\\AppData\\Local\\Zed\\node\\node-v22.5.1-win-x64\\node.exe", working directory: "C:/", args: ["C:\\Users\\qingxun\\AppData\\Local\\Zed\\copilot\\copilot-v0.5.0\\dist/agent.js", "--stdio"]
2024-09-13T10:15:54.9698101+08:00 [INFO] Installing default prettier and plugins: [("prettier-plugin-java", "2.6.4"), ("prettier", "3.3.3")]
2024-09-13T10:15:54.9699469+08:00 [INFO] Node runtime install_if_needed
2024-09-13T10:15:55.1237716+08:00 [INFO] Node runtime install_if_needed
2024-09-13T10:15:55.2356889+08:00 [INFO] Language server with id 0 sent unhandled notification LogMessage:
{
  "level": 0,
  "message": "[DEBUG] [agent] [2024-09-13T02:15:55.231Z] Agent service starting",
  "metadataStr": "[DEBUG] [agent] [2024-09-13T02:15:55.231Z]",
  "extra": [
    "Agent service starting"
  ]
}
2024-09-13T10:15:55.2376459+08:00 [INFO] Language server with id 0 sent unhandled notification client/registerCapability:
{
  "registrations": [
    {
      "id": "2c5656c6-0cd6-45e2-83b0-5c99a4906c7b",
      "method": "workspace/didChangeWorkspaceFolders",
      "registerOptions": {}
    }
  ]
}
2024-09-13T10:15:55.8777937+08:00 [INFO] Initialized prettier with plugins: {"prettier-plugin-java"}
2024-09-13T10:15:56.4194133+08:00 [INFO] Creating texture 0x28fca5584e8 of size 1024x1024x1 and format Bgra8UnormSrgb, name 'atlas', handle 15
2024-09-13T10:15:56.4195186+08:00 [INFO] Creating buffer 0x2900e7d48a8 of size 705600, name 'chunk-2', handle 16
2024-09-13T10:15:56.4806205+08:00 [INFO] Language server with id 0 sent unhandled notification LogMessage:
{
  "level": 0,
  "message": "[DEBUG] [agent] [2024-09-13T02:15:56.476Z] Telemetry initialized",
  "metadataStr": "[DEBUG] [agent] [2024-09-13T02:15:56.476Z]",
  "extra": [
    "Telemetry initialized"
  ]
}
2024-09-13T10:16:27.5418011+08:00 [INFO] starting language server process. binary path: "C:\\Users\\qingxun\\AppData\\Local\\Zed\\extensions\\work\\java-eclipse-jdtls\\eclipse.jdt.ls\\bin\\jdtls.bat", working directory: "E:\\codes\\geom\\grep-java", args: []
2024-09-13T10:16:27.5439409+08:00 [INFO] response dropped without fully consuming the response body, connection won't be reused
Aborting a response without fully consuming the response body can result in sub-optimal performance. See https://github.com/sagebind/isahc/wiki/Connection-Reuse#closing-connections-early.
2024-09-13T10:16:27.5634688+08:00 [ERROR] cannot read LSP message headers
2024-09-13T10:16:27.5637063+08:00 [ERROR] failed to start language server "java": oneshot canceled
2024-09-13T10:16:27.5637753+08:00 [ERROR] server stderr: Some("")
2024-09-13T10:16:27.5638414+08:00 [INFO] retrying installation of language server "java" in 1s
2024-09-13T10:16:27.5639131+08:00 [ERROR] server shut down
2024-09-13T10:16:28.5793681+08:00 [INFO] About to spawn test binary
2024-09-13T10:16:28.5794367+08:00 [WARN] test binary failed to launch
2024-09-13T10:16:28.5794835+08:00 [WARN] test binary check failed
2024-09-13T10:16:28.5795318+08:00 [INFO] beginning to reinstall server
2024-09-13T10:16:28.579588+08:00 [INFO] deleting server container
2024-09-13T10:16:28.5799169+08:00 [ERROR] server container removal

Caused by:
    系统找不到指定的文件。 (os error 2)
2024-09-13T10:16:28.5800076+08:00 [INFO] attempting to start language server "java", path: "E:\\codes\\geom\\grep-java", id: 2
2024-09-13T10:16:33.6737542+08:00 [INFO] Creating buffer 0x28fc874ac78 of size 81984, name 'chunk-12', handle 17
2024-09-13T10:16:58.1251568+08:00 [INFO] starting language server process. binary path: "C:\\Users\\qingxun\\AppData\\Local\\Zed\\extensions\\work\\java-eclipse-jdtls\\eclipse.jdt.ls\\bin\\jdtls.bat", working directory: "E:\\codes\\geom\\grep-java", args: []
2024-09-13T10:16:58.1429513+08:00 [ERROR] cannot read LSP message headers
2024-09-13T10:16:58.1431463+08:00 [ERROR] failed to start language server "java": oneshot canceled
2024-09-13T10:16:58.1432132+08:00 [ERROR] server stderr: Some("")
2024-09-13T10:16:58.1432782+08:00 [INFO] retrying installation of language server "java" in 1s
2024-09-13T10:16:58.1433458+08:00 [ERROR] server shut down
2024-09-13T10:16:59.146875+08:00 [INFO] About to spawn test binary
2024-09-13T10:16:59.1469435+08:00 [WARN] test binary failed to launch
2024-09-13T10:16:59.1469902+08:00 [WARN] test binary check failed
2024-09-13T10:16:59.1470365+08:00 [INFO] beginning to reinstall server
2024-09-13T10:16:59.1470896+08:00 [INFO] deleting server container
2024-09-13T10:16:59.1482342+08:00 [ERROR] server container removal

Caused by:
    系统找不到指定的文件。 (os error 2)
2024-09-13T10:16:59.1483245+08:00 [INFO] attempting to start language server "java", path: "E:\\codes\\geom\\grep-java", id: 3
2024-09-13T10:17:22.2214933+08:00 [INFO] Creating buffer 0x28fc874b208 of size 82768, name 'chunk-13', handle 18
2024-09-13T10:17:22.5431991+08:00 [INFO] Creating buffer 0x2900e7d4e38 of size 83104, name 'chunk-14', handle 19
2024-09-13T10:17:29.6118805+08:00 [INFO] starting language server process. binary path: "C:\\Users\\qingxun\\AppData\\Local\\Zed\\extensions\\work\\java-eclipse-jdtls\\eclipse.jdt.ls\\bin\\jdtls.bat", working directory: "E:\\codes\\geom\\grep-java", args: []
2024-09-13T10:17:29.6133317+08:00 [INFO] response dropped without fully consuming the response body, connection won't be reused
Aborting a response without fully consuming the response body can result in sub-optimal performance. See https://github.com/sagebind/isahc/wiki/Connection-Reuse#closing-connections-early.
2024-09-13T10:17:29.6295699+08:00 [ERROR] cannot read LSP message headers
2024-09-13T10:17:29.6298059+08:00 [ERROR] failed to start language server "java": oneshot canceled
2024-09-13T10:17:29.629873+08:00 [ERROR] server stderr: Some("")
2024-09-13T10:17:29.629936+08:00 [INFO] retrying installation of language server "java" in 1s
2024-09-13T10:17:29.6300036+08:00 [ERROR] server shut down
2024-09-13T10:17:30.6383081+08:00 [INFO] About to spawn test binary
2024-09-13T10:17:30.638385+08:00 [WARN] test binary failed to launch
2024-09-13T10:17:30.6384339+08:00 [WARN] test binary check failed
2024-09-13T10:17:30.6384814+08:00 [INFO] beginning to reinstall server
2024-09-13T10:17:30.6385357+08:00 [INFO] deleting server container
2024-09-13T10:17:30.63885+08:00 [ERROR] server container removal

Caused by:
    系统找不到指定的文件。 (os error 2)
2024-09-13T10:17:30.6389382+08:00 [INFO] attempting to start language server "java", path: "E:\\codes\\geom\\grep-java", id: 4
2024-09-13T10:18:01.2510614+08:00 [INFO] starting language server process. binary path: "C:\\Users\\qingxun\\AppData\\Local\\Zed\\extensions\\work\\java-eclipse-jdtls\\eclipse.jdt.ls\\bin\\jdtls.bat", working directory: "E:\\codes\\geom\\grep-java", args: []
2024-09-13T10:18:01.2694247+08:00 [ERROR] cannot read LSP message headers
2024-09-13T10:18:01.2696055+08:00 [ERROR] failed to start language server "java": oneshot canceled
2024-09-13T10:18:01.2696813+08:00 [ERROR] server stderr: Some("")
2024-09-13T10:18:01.2697423+08:00 [INFO] retrying installation of language server "java" in 1s
2024-09-13T10:18:01.269812+08:00 [ERROR] server shut down
2024-09-13T10:18:02.2779656+08:00 [INFO] About to spawn test binary
2024-09-13T10:18:02.2780403+08:00 [WARN] test binary failed to launch
2024-09-13T10:18:02.2780888+08:00 [WARN] test binary check failed
2024-09-13T10:18:02.2781372+08:00 [INFO] beginning to reinstall server
2024-09-13T10:18:02.2781937+08:00 [INFO] deleting server container
2024-09-13T10:18:02.2784723+08:00 [ERROR] server container removal

Caused by:
    系统找不到指定的文件。 (os error 2)
2024-09-13T10:18:02.2785599+08:00 [INFO] attempting to start language server "java", path: "E:\\codes\\geom\\grep-java", id: 5
2024-09-13T10:18:34.7754933+08:00 [INFO] starting language server process. binary path: "C:\\Users\\qingxun\\AppData\\Local\\Zed\\extensions\\work\\java-eclipse-jdtls\\eclipse.jdt.ls\\bin\\jdtls.bat", working directory: "E:\\codes\\geom\\grep-java", args: []
2024-09-13T10:18:34.7773042+08:00 [INFO] response dropped without fully consuming the response body, connection won't be reused
Aborting a response without fully consuming the response body can result in sub-optimal performance. See https://github.com/sagebind/isahc/wiki/Connection-Reuse#closing-connections-early.
2024-09-13T10:18:34.7928909+08:00 [ERROR] cannot read LSP message headers
2024-09-13T10:18:34.7930859+08:00 [ERROR] failed to start language server "java": oneshot canceled
2024-09-13T10:18:34.7931546+08:00 [ERROR] server shut down
2024-09-13T10:18:34.7932224+08:00 [ERROR] server stderr: Some("")
2024-09-13T10:18:34.7932942+08:00 [ERROR] Hit 4 reinstallation attempts for "java"
ABckh commented 2 months ago

Hi @liukaizheng, try to delete the extension completely as well as jdtls, set JAVA_HOME env variable and install the extension again.

I can see that you are facing the same issue with env variables, which might be the cause of your problem: https://github.com/zed-industries/zed/issues/9788

liukaizheng commented 2 months ago

Hi @liukaizheng, try to delete the extension completely as well as jdtls, set JAVA_HOME env variable and install the extension again.

I can see that you are facing the same issue with env variables, which might be the cause of your problem: zed-industries/zed#9788

Thank you!