Skip to content

python-ecosys/debugpy: Add VS Code debugging support for MicroPython. #1022

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Prev Previous commit
Next Next commit
debugpy: Improve variable retrievals.
Signed-off-by: Jos Verlinde <jos_verlinde@hotmail.com>
  • Loading branch information
Josverl authored and andrewleech committed Jun 15, 2025
commit 3ed2d89a86add35c099013d9179b45d76d04dc9e
5 changes: 4 additions & 1 deletion python-ecosys/debugpy/debugpy/server/debug_session.py
Original file line number Diff line number Diff line change
Expand Up @@ -328,7 +328,10 @@ def _handle_evaluate(self, seq, args):
expression = args.get("expression", "")
frame_id = args.get("frameId")
context = args.get("context", "watch")

if not expression:
self.channel.send_response(CMD_EVALUATE, seq, success=False,
message="No expression provided")
return
try:
result = self.pdb.evaluate_expression(expression, frame_id)
self.channel.send_response(CMD_EVALUATE, seq, body={
Expand Down
2 changes: 1 addition & 1 deletion python-ecosys/debugpy/debugpy/server/pdb_adapter.py
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ def get_variables(self, variables_ref):
continue

try:
value_str = str(value)
value_str = repr(value)
type_str = type(value).__name__

variables.append({
Expand Down