MCPcopy Index your code
hub / github.com/Marus/cortex-debug / debugSessionStarted

Method debugSessionStarted

src/frontend/extension.ts:402–428  ·  view source on GitHub ↗
(session: vscode.DebugSession)

Source from the content-addressed store, hash-verified

400
401 // Debug Events
402 private debugSessionStarted(session: vscode.DebugSession) {
403 if (session.type !== 'cortex-debug') { return; }
404
405 const newSession = CDebugSession.NewSessionStarted(session);
406
407 this.functionSymbols = null;
408 session.customRequest('get-arguments').then((args) => {
409 newSession.config = args;
410 let svdfile = args.svdFile;
411 if (!svdfile) {
412 svdfile = this.getSVDFile(args.device);
413 }
414
415 Reporting.beginSession(session.id, args as ConfigurationArguments);
416
417 if (newSession.swoSource) {
418 this.initializeSWO(session, args);
419 }
420 if (Object.keys(newSession.rttPortMap).length > 0) {
421 this.initializeRTT(session, args);
422 }
423 this.cleanupRTTTerminals();
424 }, (error) => {
425 vscode.window.showErrorMessage(
426 `Internal Error: Could not get startup arguments. Many debug functions can fail. Please report this problem. Error: ${error}`);
427 });
428 }
429
430 private debugSessionTerminated(session: vscode.DebugSession) {
431 if (session.type !== 'cortex-debug') { return; }

Callers 1

receivedCustomEventMethod · 0.45

Calls 6

getSVDFileMethod · 0.95
initializeSWOMethod · 0.95
initializeRTTMethod · 0.95
cleanupRTTTerminalsMethod · 0.95
NewSessionStartedMethod · 0.80
customRequestMethod · 0.65

Tested by

no test coverage detected