-
Notifications
You must be signed in to change notification settings - Fork 29.3k
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
Problem with colors when parameters contain object #172868
Comments
This is actually a VS Code bug, in part at least. ANSI color sequences are supported in top level expressions, but not in variables I think the best way to deal with this is tweak how we show output in VS Code, showing a non-empty fyi @roblourens might try to tack this today/tomorrow |
Previously, if a DAP output event contained a variablesReference, we would entirely ignore the `output` text in favor of shows its variables. However, output can be richer than variable data: namely, it can show ANSI sequences which would be inappropriate to format in a variable `value`. In this PR, if an output event has a single variable in its `variablesReference` and output text, we show the output text instead of the variable value. (Maybe we should also log output as plain text, though this could be a confusing experience. I don't know of any DA's that actually emit >1 variable in their output.) For #172868 For #171732 (will need adoption in js-debug to actually fix those)
Previously, if a DAP output event contained a variablesReference, we would entirely ignore the `output` text in favor of shows its variables. However, output can be richer than variable data: namely, it can show ANSI sequences which would be inappropriate to format in a variable `value`. In this PR, if an output event has a single variable in its `variablesReference` and output text, we show the output text instead of the variable value. (Maybe we should also log output as plain text, though this could be a confusing experience. I don't know of any DA's that actually emit >1 variable in their output.) For #172868 For #171732 (will need adoption in js-debug to actually fix those)
Fixes microsoft/vscode#172868 This now works as of microsoft/vscode#172880
Fixes microsoft/vscode#172868 This now works as of microsoft/vscode#172880
Describe the bug
Logged messages with colors and objects do not display correctly on Debug Console. Messages without objects display correctly.
To Reproduce
Log File
Relevant launch configuration
VS Code Version: 1.74.2
Additional context
EDIT
An easier way to reproduce. Type this directly on the debug console:
The text was updated successfully, but these errors were encountered: