Vscode-cpptools: Crash with hover

Created on 18 Jun 2019  路  9Comments  路  Source: microsoft/vscode-cpptools

cpptools sometimes will produce some error with this problem,maybe it's a same problem锛孖 tried just open one vscode,still got the same error message.

[Error - 12:14:08 AM] Connection to server got closed. Server will not be restarted.
[Error - 12:14:08 AM] Request textDocument/hover failed.
Error: Connection got disposed.
at Object.dispose (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:2556:25)
at Object.dispose (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:3313:35)
at LanguageClient.handleConnectionClosed (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:5395:42)
at LanguageClient.handleConnectionClosed (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:11804:15)
at closeHandler (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:5382:18)
at CallbackList.invoke (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:7515:39)
at Emitter.fire (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:7573:36)
at closeHandler (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:1906:26)
at CallbackList.invoke (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:7515:39)
at Emitter.fire (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:7573:36)
at StreamMessageReader.fireClose (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:9855:27)
at Socket.module.exports.listen.readable.on (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:9895:46)
at Socket.emit (events.js:187:15)
at Pipe.Socket._destroy._handle.close [as _onclose] (net.js:596:12)
[Error - 12:14:08 AM] Request textDocument/documentHighlight failed.
Error: Connection got disposed.
at Object.dispose (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:2556:25)
at Object.dispose (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:3313:35)
at LanguageClient.handleConnectionClosed (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:5395:42)
at LanguageClient.handleConnectionClosed (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:11804:15)
at closeHandler (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:5382:18)
at CallbackList.invoke (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:7515:39)
at Emitter.fire (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:7573:36)
at closeHandler (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:1906:26)
at CallbackList.invoke (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:7515:39)
at Emitter.fire (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:7573:36)
at StreamMessageReader.fireClose (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:9855:27)
at Socket.module.exports.listen.readable.on (/Users/coder52/.vscode/extensions/ms-vscode.cpptools-0.24.0-insiders/dist/main.js:9895:46)
at Socket.emit (events.js:187:15)
at Pipe.Socket._destroy._handle.close [as _onclose] (net.js:596:12)

_Originally posted by @52coder in https://github.com/microsoft/vscode-cpptools/issues/3786#issuecomment-502465699_

Language Service bug fixed (release pending) insiders regression reliability

Most helpful comment

Our current hypothesis is that the crash is caused by incorrect handling of invalid UTF-8 characters. We'll try to get a fix for our next Insiders. Until we release the fix, setting C_Cpp.updateChannel to "Default" may be your best workaround.

UPDATE: I believe we have fixed the issue. I think we can release an update with the fix "soon" (at least by Thursday).

UPDATE: There were 2 different cases that could lead to a hover crash (and there was an edit crash as well). All should be fixed in our next update.

All 9 comments

This is our top crash with Insiders. Unfortunately, I'm not seeing what the cause is from the crash call stacks.

@52coder Can you provide any more info on how to get the crash to occur? What is special about what you are hovering over or what actions are required to get the repro? Is the repro only when the "different casing" issue occurs?

I have the same problem.

same problem on my MacOS

Same problem on Win7, but it disappears after I re-installed the earlier version 0.23.1

Our current hypothesis is that the crash is caused by incorrect handling of invalid UTF-8 characters. We'll try to get a fix for our next Insiders. Until we release the fix, setting C_Cpp.updateChannel to "Default" may be your best workaround.

UPDATE: I believe we have fixed the issue. I think we can release an update with the fix "soon" (at least by Thursday).

UPDATE: There were 2 different cases that could lead to a hover crash (and there was an edit crash as well). All should be fixed in our next update.

sorry for a late response, thanks for your work to fix this problem.

Fixed with 0.24.0-insiders2. Set the "C_Cpp.updateChannel" setting to "Insiders" to auto-install it.

Actually, there are still crashes...some of our fixes might not have worked.

The crashes got fixed with 0.24.0-insiders3 and not 0.24.0.

Was this page helpful?
0 / 5 - 0 ratings