Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork9.7k
[Console] [Table] Fix invalid UTF-8 due to text wrapping#61242
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
69eddce to932287fCompareschlndh commentedJul 26, 2025
Fabbot wants me to change a line unrelated to my PR. I'm ignoring it. |
The patch is fromsymfony/symfony#61242 rebasedonto symfony/console 5.4
The patch is fromsymfony/symfony#61242 rebasedonto symfony/console 5.4
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
nicolas-grekas left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
(fabbot's suggestion is a false-positive)
nicolas-grekas commentedJul 30, 2025
Thank you@schlndh. |
1b7d5c8 intosymfony:6.4Uh oh!
There was an error while loading.Please reload this page.
I changed the
OutputFormatterto use string methods fromHelperto avoid splitting multi-byte UTF-8 characters and causing the "Invalid UTF-8" exception as a result. Unfortunately, it turns out thatHelper::lengthandHelper::substrare not mutually compatible for UTF-8, becauselengthreturns the length in graphemes, whilesubstrworked with characters. I decided to fix that, which is technically a BC break (hopefully not too severe). I considered making a private fixed copy of the method, but that just seemed weird.