@jupyterlab/debugger 3.3.0-alpha.16 → 3.3.0-alpha.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/debugger.d.ts +8 -1
- package/lib/debugger.js +9 -1
- package/lib/debugger.js.map +1 -1
- package/lib/handler.d.ts +31 -1
- package/lib/handler.js +7 -0
- package/lib/handler.js.map +1 -1
- package/lib/index.d.ts +1 -1
- package/lib/index.js +1 -1
- package/lib/index.js.map +1 -1
- package/lib/model.d.ts +8 -1
- package/lib/model.js +10 -0
- package/lib/model.js.map +1 -1
- package/lib/panels/callstack/model.d.ts +3 -3
- package/lib/panels/callstack/model.js +3 -1
- package/lib/panels/callstack/model.js.map +1 -1
- package/lib/panels/sources/model.d.ts +2 -2
- package/lib/panels/variables/grid.js +58 -3
- package/lib/panels/variables/grid.js.map +1 -1
- package/lib/panels/variables/index.js +6 -1
- package/lib/panels/variables/index.js.map +1 -1
- package/lib/panels/variables/mimerenderer.d.ts +44 -0
- package/lib/panels/variables/mimerenderer.js +75 -0
- package/lib/panels/variables/mimerenderer.js.map +1 -0
- package/lib/panels/variables/model.d.ts +3 -0
- package/lib/panels/variables/model.js +7 -0
- package/lib/panels/variables/model.js.map +1 -1
- package/lib/panels/variables/tree.d.ts +13 -0
- package/lib/panels/variables/tree.js +45 -8
- package/lib/panels/variables/tree.js.map +1 -1
- package/lib/service.d.ts +8 -0
- package/lib/service.js +31 -3
- package/lib/service.js.map +1 -1
- package/lib/tokens.d.ts +90 -7
- package/lib/tokens.js +4 -0
- package/lib/tokens.js.map +1 -1
- package/package.json +17 -17
- package/style/variables.css +46 -0
package/lib/tokens.d.ts
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import { CodeEditor, CodeEditorWrapper } from '@jupyterlab/codeeditor';
|
|
2
2
|
import { KernelMessage, Session } from '@jupyterlab/services';
|
|
3
|
-
import { Token } from '@lumino/coreutils';
|
|
3
|
+
import { ReadonlyJSONObject, Token } from '@lumino/coreutils';
|
|
4
4
|
import { IObservableDisposable } from '@lumino/disposable';
|
|
5
5
|
import { ISignal, Signal } from '@lumino/signaling';
|
|
6
6
|
import { Widget } from '@lumino/widgets';
|
|
7
7
|
import { DebugProtocol } from 'vscode-debugprotocol';
|
|
8
|
+
import { DebuggerHandler } from './handler';
|
|
8
9
|
/**
|
|
9
10
|
* An interface describing an application's visual debugger.
|
|
10
11
|
*/
|
|
@@ -61,6 +62,14 @@ export interface IDebugger {
|
|
|
61
62
|
* @param variablesReference The variable reference to request.
|
|
62
63
|
*/
|
|
63
64
|
inspectVariable(variablesReference: number): Promise<DebugProtocol.Variable[]>;
|
|
65
|
+
/**
|
|
66
|
+
* Request rich representation of a variable.
|
|
67
|
+
*
|
|
68
|
+
* @param variableName The variable name to request
|
|
69
|
+
* @param frameId The current frame id in which to request the variable
|
|
70
|
+
* @returns The mime renderer data model
|
|
71
|
+
*/
|
|
72
|
+
inspectRichVariable(variableName: string, frameId?: number): Promise<IDebugger.IRichVariable>;
|
|
64
73
|
/**
|
|
65
74
|
* Requests all the defined variables and display them in the
|
|
66
75
|
* table view.
|
|
@@ -194,6 +203,11 @@ export declare namespace IDebugger {
|
|
|
194
203
|
*/
|
|
195
204
|
getTmpFileParams(kernel: string): IConfig.FileParams;
|
|
196
205
|
}
|
|
206
|
+
/**
|
|
207
|
+
* An interface for debugger handler.
|
|
208
|
+
*/
|
|
209
|
+
interface IHandler extends DebuggerHandler.IHandler {
|
|
210
|
+
}
|
|
197
211
|
/**
|
|
198
212
|
* An interface for a scope.
|
|
199
213
|
*/
|
|
@@ -264,6 +278,19 @@ export declare namespace IDebugger {
|
|
|
264
278
|
*/
|
|
265
279
|
interface IStackFrame extends DebugProtocol.StackFrame {
|
|
266
280
|
}
|
|
281
|
+
/**
|
|
282
|
+
* A reply to an rich inspection request.
|
|
283
|
+
*/
|
|
284
|
+
interface IRichVariable {
|
|
285
|
+
/**
|
|
286
|
+
* The MIME bundle data returned from an rich inspection request.
|
|
287
|
+
*/
|
|
288
|
+
data: ReadonlyJSONObject;
|
|
289
|
+
/**
|
|
290
|
+
* Any metadata that accompanies the MIME bundle returning from a rich inspection request.
|
|
291
|
+
*/
|
|
292
|
+
metadata: ReadonlyJSONObject;
|
|
293
|
+
}
|
|
267
294
|
/**
|
|
268
295
|
* An interface for a variable.
|
|
269
296
|
*/
|
|
@@ -342,6 +369,7 @@ export declare namespace IDebugger {
|
|
|
342
369
|
restart: DebugProtocol.RestartArguments;
|
|
343
370
|
restartFrame: DebugProtocol.RestartFrameArguments;
|
|
344
371
|
reverseContinue: DebugProtocol.ReverseContinueArguments;
|
|
372
|
+
richInspectVariables: IRichVariablesArguments;
|
|
345
373
|
scopes: DebugProtocol.ScopesArguments;
|
|
346
374
|
setBreakpoints: DebugProtocol.SetBreakpointsArguments;
|
|
347
375
|
setExceptionBreakpoints: DebugProtocol.SetExceptionBreakpointsArguments;
|
|
@@ -384,6 +412,7 @@ export declare namespace IDebugger {
|
|
|
384
412
|
restart: DebugProtocol.RestartResponse;
|
|
385
413
|
restartFrame: DebugProtocol.RestartFrameResponse;
|
|
386
414
|
reverseContinue: DebugProtocol.ReverseContinueResponse;
|
|
415
|
+
richInspectVariables: IRichVariablesResponse;
|
|
387
416
|
scopes: DebugProtocol.ScopesResponse;
|
|
388
417
|
setBreakpoints: DebugProtocol.SetBreakpointsResponse;
|
|
389
418
|
setExceptionBreakpoints: DebugProtocol.SetExceptionBreakpointsResponse;
|
|
@@ -415,13 +444,17 @@ export declare namespace IDebugger {
|
|
|
415
444
|
*/
|
|
416
445
|
interface IDebugInfoResponse extends DebugProtocol.Response {
|
|
417
446
|
body: {
|
|
418
|
-
|
|
447
|
+
breakpoints: IDebugInfoBreakpoints[];
|
|
419
448
|
hashMethod: string;
|
|
420
449
|
hashSeed: number;
|
|
421
|
-
|
|
450
|
+
isStarted: boolean;
|
|
451
|
+
/**
|
|
452
|
+
* Whether the kernel supports variable rich rendering or not.
|
|
453
|
+
*/
|
|
454
|
+
richRendering?: boolean;
|
|
455
|
+
stoppedThreads: number[];
|
|
422
456
|
tmpFilePrefix: string;
|
|
423
457
|
tmpFileSuffix: string;
|
|
424
|
-
stoppedThreads: number[];
|
|
425
458
|
};
|
|
426
459
|
}
|
|
427
460
|
/**
|
|
@@ -447,6 +480,34 @@ export declare namespace IDebugger {
|
|
|
447
480
|
variables: DebugProtocol.Variable[];
|
|
448
481
|
};
|
|
449
482
|
}
|
|
483
|
+
/**
|
|
484
|
+
* Arguments for 'richVariables' request
|
|
485
|
+
*
|
|
486
|
+
* This is an addition to the Debug Adapter Protocol to support
|
|
487
|
+
* render rich variable representation.
|
|
488
|
+
*/
|
|
489
|
+
interface IRichVariablesArguments {
|
|
490
|
+
/**
|
|
491
|
+
* Variable name
|
|
492
|
+
*/
|
|
493
|
+
variableName: string;
|
|
494
|
+
/**
|
|
495
|
+
* Frame Id
|
|
496
|
+
*/
|
|
497
|
+
frameId?: number;
|
|
498
|
+
}
|
|
499
|
+
/**
|
|
500
|
+
* Arguments for 'richVariables' request
|
|
501
|
+
*
|
|
502
|
+
* This is an addition to the Debug Adapter Protocol to support
|
|
503
|
+
* rich rendering of variables.
|
|
504
|
+
*/
|
|
505
|
+
interface IRichVariablesResponse extends DebugProtocol.Response {
|
|
506
|
+
/**
|
|
507
|
+
* Variable mime type data
|
|
508
|
+
*/
|
|
509
|
+
body: IRichVariable;
|
|
510
|
+
}
|
|
450
511
|
/**
|
|
451
512
|
* Response to the 'kernel_info_request' request.
|
|
452
513
|
* This interface extends the IInfoReply by adding the `debugger` key
|
|
@@ -457,6 +518,16 @@ export declare namespace IDebugger {
|
|
|
457
518
|
debugger: boolean;
|
|
458
519
|
}
|
|
459
520
|
}
|
|
521
|
+
/**
|
|
522
|
+
* Select variable in the variables explorer.
|
|
523
|
+
*
|
|
524
|
+
* @hidden
|
|
525
|
+
*
|
|
526
|
+
* #### Notes
|
|
527
|
+
* This is experimental API
|
|
528
|
+
*/
|
|
529
|
+
interface IVariableSelection extends Pick<DebugProtocol.Variable, 'name' | 'type' | 'variablesReference' | 'value'> {
|
|
530
|
+
}
|
|
460
531
|
/**
|
|
461
532
|
* Debugger sidebar interface.
|
|
462
533
|
*/
|
|
@@ -568,11 +639,11 @@ export declare namespace IDebugger {
|
|
|
568
639
|
/**
|
|
569
640
|
* Signal emitted when the current frame has changed.
|
|
570
641
|
*/
|
|
571
|
-
readonly currentFrameChanged: ISignal<this, IDebugger.IStackFrame>;
|
|
642
|
+
readonly currentFrameChanged: ISignal<this, IDebugger.IStackFrame | null>;
|
|
572
643
|
/**
|
|
573
644
|
* The current frame.
|
|
574
645
|
*/
|
|
575
|
-
frame: IDebugger.IStackFrame;
|
|
646
|
+
frame: IDebugger.IStackFrame | null;
|
|
576
647
|
/**
|
|
577
648
|
* The frames for the callstack.
|
|
578
649
|
*/
|
|
@@ -594,6 +665,10 @@ export declare namespace IDebugger {
|
|
|
594
665
|
* The callstack UI model.
|
|
595
666
|
*/
|
|
596
667
|
readonly callstack: ICallstack;
|
|
668
|
+
/**
|
|
669
|
+
* Whether the kernel support rich variable rendering based on mime type.
|
|
670
|
+
*/
|
|
671
|
+
hasRichVariableRendering: boolean;
|
|
597
672
|
/**
|
|
598
673
|
* The variables UI model.
|
|
599
674
|
*/
|
|
@@ -626,7 +701,7 @@ export declare namespace IDebugger {
|
|
|
626
701
|
/**
|
|
627
702
|
* Signal emitted when the current frame changes.
|
|
628
703
|
*/
|
|
629
|
-
readonly currentFrameChanged: ISignal<IDebugger.Model.ICallstack, IDebugger.IStackFrame>;
|
|
704
|
+
readonly currentFrameChanged: ISignal<IDebugger.Model.ICallstack, IDebugger.IStackFrame | null>;
|
|
630
705
|
/**
|
|
631
706
|
* Return the current source.
|
|
632
707
|
*/
|
|
@@ -660,6 +735,10 @@ export declare namespace IDebugger {
|
|
|
660
735
|
* Signal emitted when the current variable has been expanded.
|
|
661
736
|
*/
|
|
662
737
|
readonly variableExpanded: ISignal<this, IDebugger.IVariable>;
|
|
738
|
+
/**
|
|
739
|
+
* Selected variable in the variables explorer.
|
|
740
|
+
*/
|
|
741
|
+
selectedVariable: IVariableSelection | null;
|
|
663
742
|
/**
|
|
664
743
|
* Expand a variable.
|
|
665
744
|
*
|
|
@@ -685,3 +764,7 @@ export declare const IDebuggerSources: Token<IDebugger.ISources>;
|
|
|
685
764
|
* The debugger configuration token.
|
|
686
765
|
*/
|
|
687
766
|
export declare const IDebuggerSidebar: Token<IDebugger.ISidebar>;
|
|
767
|
+
/**
|
|
768
|
+
* The debugger handler token.
|
|
769
|
+
*/
|
|
770
|
+
export declare const IDebuggerHandler: Token<IDebugger.IHandler>;
|
package/lib/tokens.js
CHANGED
|
@@ -17,4 +17,8 @@ export const IDebuggerSources = new Token('@jupyterlab/debugger:IDebuggerSources
|
|
|
17
17
|
* The debugger configuration token.
|
|
18
18
|
*/
|
|
19
19
|
export const IDebuggerSidebar = new Token('@jupyterlab/debugger:IDebuggerSidebar');
|
|
20
|
+
/**
|
|
21
|
+
* The debugger handler token.
|
|
22
|
+
*/
|
|
23
|
+
export const IDebuggerHandler = new Token('@jupyterlab/debugger:IDebuggerHandler');
|
|
20
24
|
//# sourceMappingURL=tokens.js.map
|
package/lib/tokens.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tokens.js","sourceRoot":"","sources":["../src/tokens.ts"],"names":[],"mappings":"AAAA,0CAA0C;AAC1C,2DAA2D;AAM3D,OAAO,
|
|
1
|
+
{"version":3,"file":"tokens.js","sourceRoot":"","sources":["../src/tokens.ts"],"names":[],"mappings":"AAAA,0CAA0C;AAC1C,2DAA2D;AAM3D,OAAO,EAAsB,KAAK,EAAE,MAAM,mBAAmB,CAAC;AA43B9D;;GAEG;AACH,MAAM,CAAC,MAAM,SAAS,GAAG,IAAI,KAAK,CAAY,gCAAgC,CAAC,CAAC;AAEhF;;GAEG;AACH,MAAM,CAAC,MAAM,eAAe,GAAG,IAAI,KAAK,CACtC,sCAAsC,CACvC,CAAC;AAEF;;GAEG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,IAAI,KAAK,CACvC,uCAAuC,CACxC,CAAC;AAEF;;GAEG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,IAAI,KAAK,CACvC,uCAAuC,CACxC,CAAC;AAEF;;GAEG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG,IAAI,KAAK,CACvC,uCAAuC,CACxC,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jupyterlab/debugger",
|
|
3
|
-
"version": "3.3.0-alpha.
|
|
3
|
+
"version": "3.3.0-alpha.17",
|
|
4
4
|
"description": "JupyterLab - Debugger Extension",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"jupyter",
|
|
@@ -48,21 +48,21 @@
|
|
|
48
48
|
"watch": "tsc -b --watch"
|
|
49
49
|
},
|
|
50
50
|
"dependencies": {
|
|
51
|
-
"@jupyterlab/application": "^3.3.0-alpha.
|
|
52
|
-
"@jupyterlab/apputils": "^3.3.0-alpha.
|
|
53
|
-
"@jupyterlab/cells": "^3.3.0-alpha.
|
|
54
|
-
"@jupyterlab/codeeditor": "^3.3.0-alpha.
|
|
55
|
-
"@jupyterlab/codemirror": "^3.3.0-alpha.
|
|
56
|
-
"@jupyterlab/console": "^3.3.0-alpha.
|
|
57
|
-
"@jupyterlab/coreutils": "^5.3.0-alpha.
|
|
58
|
-
"@jupyterlab/docregistry": "^3.3.0-alpha.
|
|
59
|
-
"@jupyterlab/fileeditor": "^3.3.0-alpha.
|
|
60
|
-
"@jupyterlab/notebook": "^3.3.0-alpha.
|
|
61
|
-
"@jupyterlab/observables": "^4.3.0-alpha.
|
|
62
|
-
"@jupyterlab/rendermime": "^3.3.0-alpha.
|
|
63
|
-
"@jupyterlab/services": "^6.3.0-alpha.
|
|
64
|
-
"@jupyterlab/translation": "^3.3.0-alpha.
|
|
65
|
-
"@jupyterlab/ui-components": "^3.3.0-alpha.
|
|
51
|
+
"@jupyterlab/application": "^3.3.0-alpha.17",
|
|
52
|
+
"@jupyterlab/apputils": "^3.3.0-alpha.17",
|
|
53
|
+
"@jupyterlab/cells": "^3.3.0-alpha.17",
|
|
54
|
+
"@jupyterlab/codeeditor": "^3.3.0-alpha.17",
|
|
55
|
+
"@jupyterlab/codemirror": "^3.3.0-alpha.17",
|
|
56
|
+
"@jupyterlab/console": "^3.3.0-alpha.17",
|
|
57
|
+
"@jupyterlab/coreutils": "^5.3.0-alpha.17",
|
|
58
|
+
"@jupyterlab/docregistry": "^3.3.0-alpha.17",
|
|
59
|
+
"@jupyterlab/fileeditor": "^3.3.0-alpha.17",
|
|
60
|
+
"@jupyterlab/notebook": "^3.3.0-alpha.17",
|
|
61
|
+
"@jupyterlab/observables": "^4.3.0-alpha.17",
|
|
62
|
+
"@jupyterlab/rendermime": "^3.3.0-alpha.17",
|
|
63
|
+
"@jupyterlab/services": "^6.3.0-alpha.17",
|
|
64
|
+
"@jupyterlab/translation": "^3.3.0-alpha.17",
|
|
65
|
+
"@jupyterlab/ui-components": "^3.3.0-alpha.16",
|
|
66
66
|
"@lumino/algorithm": "^1.3.3",
|
|
67
67
|
"@lumino/commands": "^1.12.0",
|
|
68
68
|
"@lumino/coreutils": "^1.5.3",
|
|
@@ -78,7 +78,7 @@
|
|
|
78
78
|
"devDependencies": {
|
|
79
79
|
"@babel/core": "^7.10.2",
|
|
80
80
|
"@babel/preset-env": "^7.10.2",
|
|
81
|
-
"@jupyterlab/testutils": "^3.3.0-alpha.
|
|
81
|
+
"@jupyterlab/testutils": "^3.3.0-alpha.17",
|
|
82
82
|
"@types/codemirror": "^0.0.109",
|
|
83
83
|
"@types/jest": "^26.0.10",
|
|
84
84
|
"@types/react-dom": "^17.0.0",
|
package/style/variables.css
CHANGED
|
@@ -30,6 +30,38 @@
|
|
|
30
30
|
padding: 5px 0 0 0;
|
|
31
31
|
cursor: pointer;
|
|
32
32
|
color: var(--jp-content-font-color1);
|
|
33
|
+
display: flex;
|
|
34
|
+
align-items: center;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.jp-DebuggerVariables-body ul li:hover .jp-DebuggerVariables-renderVariable {
|
|
38
|
+
display: block;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.jp-DebuggerVariables-body .jp-DebuggerVariables-hspacer {
|
|
42
|
+
flex: 1 1 auto;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.jp-DebuggerVariables-body .jp-DebuggerVariables-renderVariable {
|
|
46
|
+
flex: 0 0 auto;
|
|
47
|
+
border: none;
|
|
48
|
+
background: none;
|
|
49
|
+
cursor: pointer;
|
|
50
|
+
display: none;
|
|
51
|
+
padding: 0px 8px;
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
.jp-DebuggerVariables-body .jp-DebuggerVariables-renderVariable:active {
|
|
55
|
+
transform: scale(1.272) translateX(-4px);
|
|
56
|
+
overflow: hidden;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.jp-DebuggerVariables-body .jp-DebuggerVariables-renderVariable:hover {
|
|
60
|
+
background-color: var(--jp-layout-color2);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.jp-DebuggerVariables-body .jp-DebuggerVariables-renderVariable:disabled {
|
|
64
|
+
cursor: default;
|
|
33
65
|
}
|
|
34
66
|
|
|
35
67
|
.jp-DebuggerVariables-body ul li > ul {
|
|
@@ -84,3 +116,17 @@
|
|
|
84
116
|
.jp-DebuggerVariables-colorPalette .jp-mod-text {
|
|
85
117
|
color: var(--jp-content-font-color0);
|
|
86
118
|
}
|
|
119
|
+
|
|
120
|
+
.jp-VariableRenderer-TrustButton[aria-pressed='true'] {
|
|
121
|
+
box-shadow: inset 0 var(--jp-border-width) 4px
|
|
122
|
+
rgba(
|
|
123
|
+
var(--jp-shadow-base-lightness),
|
|
124
|
+
var(--jp-shadow-base-lightness),
|
|
125
|
+
var(--jp-shadow-base-lightness),
|
|
126
|
+
0.6
|
|
127
|
+
);
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.jp-DebuggerRichVariable div[data-mime-type='text/plain'] > pre {
|
|
131
|
+
white-space: normal;
|
|
132
|
+
}
|