-
Notifications
You must be signed in to change notification settings - Fork 8.4k
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
Add an additional debug option to show a \n
when \r
is received
#12312
Comments
\n
when that character is received\n
when \r
is received
I'm tempted to just outright reject this - I actually quite like that every character that's emitted to the debug tap is turned into a printable character. It gets rid of any guesswork as to whatever the line discipline is supposed to be. You can just look at the output and know "yep, there was the CR, there's the NL, the BS SPC BS", etc. @DHowett is the father of the debug tap so I'll give him the final say. If anything, the setting should probably be |
The problem is only of readability, because when you are doing something on CLI/prompt, the debug output is always misaligned, so it's very hard to read where was the last place something was output/input. So being able to add a real newline where there are, either an An additional advantage is that of copy pasting the debug output. If you don't have a visible |
I don't feel strongly about this one way or the other, but if we were going to have this feature, I'd expect it to be trigger by a
This is similar to what you'd see if you've enabled visible whitespace in a text editor. |
Even better! 👍 |
Honestly, I think we should probably just do this all the time and without a setting. Right now, the debug tap is incapable of producing a physical CR/LF, so adding one would be adding valuable clarifying whitespace without adding confusion as to where that whitespace came from. Thanks for the request, and I'm sorry I missed this thread the first time! |
## Summary of the Pull Request When the debug tap converts control characters into visible glyphs, it ends up losing the structure of the output, and that can sometimes make things difficult to read. This PR attempts to alleviate that problem by reinjecting an actual line break in the debug stream whenever an `LF` control is received. ## PR Checklist * [x] Closes #12312 * [x] CLA signed. * [ ] Tests added/passed * [ ] Documentation updated. * [ ] Schema updated. * [x] I've discussed this with core contributors already. Issue number where discussion took place: #12312 ## Validation Steps Performed I've tested the updated debug tab with a number of different shells, and also a couple of different apps. When there aren't many linefeeds in the output, it's obviously not going to make much of a difference, but when there are, I think it definitely improves the readability.
## Summary of the Pull Request When the debug tap converts control characters into visible glyphs, it ends up losing the structure of the output, and that can sometimes make things difficult to read. This PR attempts to alleviate that problem by reinjecting an actual line break in the debug stream whenever an `LF` control is received. ## PR Checklist * [x] Closes #12312 * [x] CLA signed. * [ ] Tests added/passed * [ ] Documentation updated. * [ ] Schema updated. * [x] I've discussed this with core contributors already. Issue number where discussion took place: #12312 ## Validation Steps Performed I've tested the updated debug tab with a number of different shells, and also a couple of different apps. When there aren't many linefeeds in the output, it's obviously not going to make much of a difference, but when there are, I think it definitely improves the readability. (cherry picked from commit 04478d1) Service-Card-Id: 84116394 Service-Version: 1.14
## Summary of the Pull Request When the debug tap converts control characters into visible glyphs, it ends up losing the structure of the output, and that can sometimes make things difficult to read. This PR attempts to alleviate that problem by reinjecting an actual line break in the debug stream whenever an `LF` control is received. ## PR Checklist * [x] Closes #12312 * [x] CLA signed. * [ ] Tests added/passed * [ ] Documentation updated. * [ ] Schema updated. * [x] I've discussed this with core contributors already. Issue number where discussion took place: #12312 ## Validation Steps Performed I've tested the updated debug tab with a number of different shells, and also a couple of different apps. When there aren't many linefeeds in the output, it's obviously not going to make much of a difference, but when there are, I think it definitely improves the readability. (cherry picked from commit 04478d1) Service-Card-Id: 84116395 Service-Version: 1.15
🎉This issue was addressed in #13475, which has now been successfully released as Handy links: |
🎉This issue was addressed in #13475, which has now been successfully released as Handy links: |
Description of the new feature/enhancement
The debug tool is great, but could certainly be improved if you could add an option to actually do a
\n
when the\r
(CR) character is received. This would significantly increase the readability of the infinite debug strings coming out, without affecting the actual output and understanding.So that it would look like:
(Where [C/R] is the special unicode (\x2400 range) character for
\r
.)Proposed technical implementation details (optional)
Add an optional 2nd debug option after the
"debugFeatures": true,
option.Name the option:
"debugFeature_Show_NL": true
.The text was updated successfully, but these errors were encountered: