Skip to content
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

Show debug variables as json (instead of strings) #68

Closed
ivangsa opened this issue Oct 10, 2020 · 6 comments
Closed

Show debug variables as json (instead of strings) #68

ivangsa opened this issue Oct 10, 2020 · 6 comments
Labels
external An external issue out of our control

Comments

@ivangsa
Copy link
Contributor

ivangsa commented Oct 10, 2020

Hi,

when debuging, on a breakpoint..

is it posible to show debug variables as expandable json objects?

currently I can only see them a json string with makes it harder to debug...

Thanks

@kirksl
Copy link
Owner

kirksl commented Oct 11, 2020

@ptrthomas wondering if this is something controllable from the DAP implementation when IDE requests variable info for stack frame?

https://microsoft.github.io/debug-adapter-protocol/specification#Types_Variable

@ptrthomas
Copy link
Collaborator

I think so, and I think supportsValueFormattingOptions and VariablePresentationHint which we don't set today has to be switched on. I'm busy with that rewrite which will anyway impact the debug adapter so will get around to it eventually. but any analysis / trial in the meantime would help

@kirksl
Copy link
Owner

kirksl commented Oct 11, 2020

@ptrthomas great. thanks for confirming.
@ivangsa solutioning for this can be tracked at karatelabs/karate#1281

@ptrthomas
Copy link
Collaborator

@ivangsa ok, so we need your help now. you can see commit above that tries to "guess" what the solution should be: karatelabs/karate@43c8a90

didn't seem to work. but by the way, note that when you right click on a variable and say "copy value" to clipboard, you get it pretty-printed

image

so when you say: expandable json objects.

without this, we won't be able to address this. hope you can help !

@ivangsa
Copy link
Contributor Author

ivangsa commented Dec 5, 2020

ok, I will have a look into this because vscode supports this for other debugers, this is what I mean:

image

as you can see all variables can be expanded, as an structured tree... they are not just text..
this is very common in every debugger I have used

@ptrthomas
Copy link
Collaborator

@ivangsa ok. btw if you use slack: https://twitter.com/KarateDSL/status/937271659785961477

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
external An external issue out of our control
Projects
None yet
Development

No branches or pull requests

3 participants