Skip to content

Commit ab71b94

Browse files
authored
Merge branch 'master' into cleanup-on-start
2 parents 8b1188c + eb9f5e4 commit ab71b94

18 files changed

+565
-157
lines changed

CHANGELOG.md

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,21 @@ Versioning].
1010

1111
## Unreleased
1212

13+
### Added
14+
15+
- fix missing output of variable type for structure ([@henryriley0])
16+
- add static variable support ([@henryriley0])
17+
- fix gdb check error when debug beginning ([@henryriley0])
18+
- fix implicitly type error in log message when build vsix ([@henryriley0])
19+
- check for configured debugger before start to provide a nicer error message
20+
([@GitMensch])
21+
- New `frameFilters` option for GDB that allows using custom frame filters,
22+
enabled by default ([@JacquesLucke])
23+
- Suppress error for hover as the user may just play with the mouse ([@oltolm]).
24+
- solve the problem of failed parsing of containers ([@henryriley0])
25+
- Fixes #421 - Added `registerLimit` option to specify the registers to
26+
display - PR #444 ([@chenzhiy2001])
27+
1328
### Fixed
1429

1530
- close invalid existing sockets from previous usage of this extension during
@@ -22,6 +37,8 @@ Versioning].
2237
- Added registers view ([@nomtats]) #242
2338
- Enabled breakpoints inside `riscv` files ([@William-An]) #404
2439

40+
[0.27.0]: https://github.com/WebFreak001/code-debug/compare/v0.26.1...v0.27.0
41+
2542
## [0.26.1] - 2022-12-31
2643

2744
### Fixed
@@ -233,13 +250,16 @@ Versioning].
233250
[@abussy-aldebaran]: https://github.com/abussy-aldebaran
234251
[@anshulrouthu]: https://github.com/anshulrouthu
235252
[@brownts]: https://github.com/brownts
253+
[@chenzhiy2001]: https://github.com/chenzhiy2001
236254
[@coldencullen]: https://github.com/ColdenCullen
237255
[@eamousing]: https://github.com/eamousing
238256
[@evangrayk]: https://github.com/evangrayk
239257
[@faustinoaq]: https://github.com/faustinoaq
240258
[@gentoo90]: https://github.com/gentoo90
241259
[@gitmensch]: https://github.com/GitMensch
242260
[@haronk]: https://github.com/HaronK
261+
[@henryriley0]: https://github.com/HenryRiley0
262+
[@jacqueslucke]: https://github.com/JacquesLucke
243263
[@jelleroets]: https://github.com/JelleRoets
244264
[@karljs]: https://github.com/karljs
245265
[@kvinwang]: https://github.com/kvinwang
@@ -252,7 +272,7 @@ Versioning].
252272
[@reznikmm]: https://github.com/reznikmm
253273
[@simark]: https://github.com/simark
254274
[@webfreak001]: https://github.com/WebFreak001
255-
[@William-An]: https://github.com/William-An
275+
[@william-an]: https://github.com/William-An
256276
[@yanpas]: https://github.com/Yanpas
257277

258278
<!-- markdownlint-configure-file { "MD024": { "siblings_only": true } } -->

README.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,20 @@ that location prior to continuing execution. Note that stopping at the entry po
8181
attach configuration assumes that the entry point has not yet been entered at the time of
8282
attach, otherwise this will have no affect.
8383

84+
There is a Registers view in the VARIABLES view. As we fetch all registers at once, there can
85+
be cases where a register that cannot be fetched causes the entire register request to fail,
86+
corrupting the entire Registers output. If this happens, you might need to set the
87+
`registerLimit` option to specify which registers you want the debugger to fetch
88+
automatically.
89+
90+
For example, to display only registers `rax` and `rip` in an x64 debug session, send the
91+
command `-data-list-register-names` in the debug console of an active x64 debug session.
92+
You will then receive a response containing an array starting with `["rax","rbx" ...]`.
93+
In this array, the index of `rax` is 0 and `rip` is 16, so set the option as
94+
`"registerLimit": "0 16"`. If you find the response text hard to navigate, you can paste
95+
it into a browser's developer tools console and press enter to get an expandable response
96+
object with array elements' indices explicitly displayed.
97+
8498
### Attaching to existing processes
8599

86100
Attaching to existing processes currently only works by specifying the PID in the
@@ -213,4 +227,10 @@ differently based on whether the remote system is a POSIX or a Windows system.
213227
You may need to experiment to find the correct escaping necessary for the command to be
214228
sent to the debugger as you intended.
215229

230+
### LogMessage
231+
232+
LogMessage will print a message in the debug console when breakpoint is hit. Expressions within {} are interpolated.
233+
234+
![LogMessage](images/logMessage.gif)
235+
216236
## [Issues](https://github.com/WebFreak001/code-debug)

images/logMessage.gif

196 KB
Loading

package-lock.json

Lines changed: 60 additions & 9 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 44 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
"debug"
1111
],
1212
"license": "public domain",
13-
"version": "0.27.0",
13+
"version": "0.27.1",
1414
"publisher": "webfreak",
1515
"icon": "images/icon.png",
1616
"engines": {
@@ -187,13 +187,18 @@
187187
"valuesFormatting": {
188188
"type": "string",
189189
"description": "Set the way of showing variable values. 'disabled' - show value as is, 'parseText' - parse debuggers output text into structure, 'prettyPrinters' - enable debuggers custom pretty-printers if there are any",
190-
"default": "parseText",
190+
"default": "prettyPrinters",
191191
"enum": [
192192
"disabled",
193193
"parseText",
194194
"prettyPrinters"
195195
]
196196
},
197+
"frameFilters": {
198+
"type": "boolean",
199+
"description": "Use frame filters registered in GDB",
200+
"default": true
201+
},
197202
"printCalls": {
198203
"type": "boolean",
199204
"description": "Prints all GDB calls to the console",
@@ -294,6 +299,11 @@
294299
"description": "Content will be executed on the SSH host before the debugger call."
295300
}
296301
}
302+
},
303+
"registerLimit": {
304+
"type": "string",
305+
"description": "List of numbers specifying the registers to display. An empty string indicates that the contents of all the registers must be returned.",
306+
"default": ""
297307
}
298308
}
299309
},
@@ -322,6 +332,11 @@
322332
"prettyPrinters"
323333
]
324334
},
335+
"frameFilters": {
336+
"type": "boolean",
337+
"description": "Use frame filters registered in GDB",
338+
"default": true
339+
},
325340
"printCalls": {
326341
"type": "boolean",
327342
"description": "Prints all GDB calls to the console",
@@ -458,6 +473,11 @@
458473
"description": "Content will be executed on the SSH host before the debugger call."
459474
}
460475
}
476+
},
477+
"registerLimit": {
478+
"type": "string",
479+
"description": "List of numbers specifying the registers to display. An empty string indicates that the contents of all the registers must be returned.",
480+
"default": ""
461481
}
462482
}
463483
}
@@ -756,6 +776,11 @@
756776
"description": "Content will be executed on the SSH host before the debugger call."
757777
}
758778
}
779+
},
780+
"registerLimit": {
781+
"type": "string",
782+
"description": "List of numbers specifying the registers to display. An empty string indicates that the contents of all the registers must be returned.",
783+
"default": ""
759784
}
760785
}
761786
},
@@ -836,6 +861,11 @@
836861
],
837862
"description": "Whether debugger should stop at application entry point",
838863
"default": false
864+
},
865+
"registerLimit": {
866+
"type": "string",
867+
"description": "List of numbers specifying the registers to display. An empty string indicates that the contents of all the registers must be returned.",
868+
"default": ""
839869
}
840870
}
841871
}
@@ -982,6 +1012,11 @@
9821012
"type": "array",
9831013
"description": "mago commands to run when starting to debug",
9841014
"default": []
1015+
},
1016+
"registerLimit": {
1017+
"type": "string",
1018+
"description": "List of numbers specifying the registers to display. An empty string indicates that the contents of all the registers must be returned.",
1019+
"default": ""
9851020
}
9861021
}
9871022
},
@@ -1047,6 +1082,11 @@
10471082
"type": "boolean",
10481083
"description": "Whether debugger should stop after connecting to target",
10491084
"default": false
1085+
},
1086+
"registerLimit": {
1087+
"type": "string",
1088+
"description": "List of numbers specifying the registers to display. An empty string indicates that the contents of all the registers must be returned.",
1089+
"default": ""
10501090
}
10511091
}
10521092
}
@@ -1112,6 +1152,7 @@
11121152
"@istanbuljs/nyc-config-typescript": "^1.0.2",
11131153
"@types/mocha": "^5.2.6",
11141154
"@types/node": "^11.11.3",
1155+
"@types/ssh2": "^1.15.0",
11151156
"@types/vscode": "^1.55.0",
11161157
"@typescript-eslint/eslint-plugin": "^5.22.0",
11171158
"@typescript-eslint/parser": "^5.22.0",
@@ -1125,7 +1166,7 @@
11251166
"nyc": "^15.1.0",
11261167
"prettier": "^2.6.2",
11271168
"ts-node": "^10.8.0",
1128-
"typescript": "^3.9.3"
1169+
"typescript": "^4.3.2"
11291170
},
11301171
"__metadata": {
11311172
"id": "2fd22b8e-b3b8-4e7f-9a28-a5e2d1bdd0d4",

0 commit comments

Comments
 (0)