You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
22: Catch `probe-rs-debugger` panic AND unexpected exits r=Yatekii a=noppej
Previously a `probe-rs-debugger` panic would fail silently, and the VSCode user would have no hint as to what went wrong.
With this PR, the user will be shown an error message that includes the `stderr` from the `probe-rs-debugger` process. In most cases, this will point to a bug, but it may also be an issue in the environment of the user. Either way, I would not expect most users to be able to resolve this kind of error without logging an issue.
This PR also updates the extension version number to `0.3.2` and will require a new release binary.
Co-authored-by: JackN <[email protected]>
logToConsole("DEBUG: Sending message to debug adapter:\n"+JSON.stringify(message,null,2));
297
+
if(probeRsLogLevel==='Debug'){
298
+
logToConsole("DEBUG: Sending message to debug adapter:\n"+JSON.stringify(message,null,2));
299
+
}
303
300
}
304
301
305
302
onDidSendMessage(message: any){
306
-
logToConsole("DEBUG: Received message from debug adapter:\n"+JSON.stringify(message,null,2));
303
+
if(probeRsLogLevel==='Debug'){
304
+
logToConsole("DEBUG: Received message from debug adapter:\n"+JSON.stringify(message,null,2));
305
+
}
307
306
}
308
307
309
308
onError(error: Error){
310
-
logToConsole("ERROR: Error in communication with debug adapter:\n"+JSON.stringify(error,null,2));
309
+
if(probeRsLogLevel==='Debug')
310
+
{
311
+
logToConsole("ERROR: Error in communication with debug adapter:\n"+JSON.stringify(error,null,2));
312
+
}
311
313
}
312
314
313
-
onExit(code: number,signal: string){
315
+
onExit(code: number,_signal: string){
314
316
if(code){
315
-
logToConsole("ERROR: Debug Adapter exited with exit code"+JSON.stringify(code,null,2));
317
+
vscode.window.showErrorMessage("ERROR: `probe-rs-debugger` exited with an unexpected code: ".concat(`${code}`).concat('\tPlease log this as an issue at https://github.com/probe-rs/probe-rs/issues/new'));
0 commit comments