Borys Palka 5 anni fa
parent
commit
f76e3ea437
3 ha cambiato i file con 3 aggiunte e 5 eliminazioni
  1. 0 1
      src/handlers/cell.ts
  2. 2 4
      src/index.ts
  3. 1 0
      src/session.ts

+ 0 - 1
src/handlers/cell.ts

@@ -60,7 +60,6 @@ export class CellManager {
   }
 
   onActiveCellChanged() {
-    console.log({ cell: this.activeCell });
     if (
       this.activeCell &&
       this.activeCell.isAttached &&

+ 2 - 4
src/index.ts

@@ -254,11 +254,9 @@ const tracker: JupyterFrontEndPlugin<IDebugger> = {
           console.log('Debugger ID: ', id);
         }
 
-        const existedWidget = tracker.find(
-          widget => id === widget.content.model.id
-        );
+        const existedWidget = tracker.currentWidget;
+
         if (existedWidget) {
-          app.shell.add(existedWidget, 'main');
           return;
         }
 

+ 1 - 0
src/session.ts

@@ -149,6 +149,7 @@ export class DebugSession implements IDebugger.ISession {
     sender: IClientSession,
     message: KernelMessage.IIOPubMessage
   ): void {
+    // console.log({ sender, message });
     const msgType = message.header.msg_type;
     if (msgType !== 'debug_event') {
       return;