-
Notifications
You must be signed in to change notification settings - Fork 29.2k
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
"clear console" escape sequence is checked for debug console without the escape character #51245
Comments
I have improved the check on that line such that it now looks in substrings, try it out and let me know how it works. |
I think this is useful when the console is cleared using a control character, since it is unexcpected by the user. |
fyi @weinand |
That sounds good. Especially because chrome devtools doesn't look for this escape code. Thanks. |
One more thing :) This is a literal backslash, you want |
@isidorn it would help if you would verify your code by actually running it once ;-) E.g. by using https://www.npmjs.com/package/clear and running this:
|
@roblourens thanks rob, I pushed a fix |
@isidorn So how should we verify this feature then? Have you tried |
@weinand yes the console log example works that is how I verified |
@isidorn there is no need to investigate inside the debug adapter. Try this and verify that "clear" works with your feature. |
@weinand thanks, after changing |
Is the verification needed here that "Console was cleared" was printed? If so verified. But the original issue is about not checking for escape sequence correctly. Which I verified too I guess. |
Yeah, I guess there were two parts, is the console cleared, and does it print the message. |
the console is cleared even when the escape sequence is in the middle of a log string, and it does print the message, and it does log the remainder of the string after the escape sequence |
From microsoft/vscode-debugadapter-node#185
https://github.com/Microsoft/vscode/blob/78d7d64c5d16b8d89d1dd2b0cc7fcbe966feb48b/src/vs/workbench/parts/debug/electron-browser/debugService.ts#L669
is checking literally
[2J
not\u001b[2J
The text was updated successfully, but these errors were encountered: