-
Notifications
You must be signed in to change notification settings - Fork 824
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
FIX handle non breakable spaces #11163
Conversation
Looks like it might be a sensible solution, can you please add a test so we don't get a regression of this in the future? |
We were dealing with something similar recently in Matomo core and we are replacing |
diving into the unit tests, the issue was already known but somehow added back by this commit it also seems that the test was never updated and was doing it's own little cleaning up, which was hiding the issue. I've refactored the cleaning method into a function (and added U+2009 as @michalkleiner suggested) and updated the tests so that they test properly formatted values (meaning, including the narrow non breaking space... i added a comment next to each line, this is really easy to miss if the editor doesn't outline somehow the utf8 character) |
Nice work @lekoala! Also good you tracked it's a regression. Can you rebase and retarget at 4.13, please? |
@michalkleiner if you have an easy way to do that i'm happy to, but changing the target branch always ends up adding tons of commits and most of the time, it's actually faster to create a new PR rather than updating this one. |
I can rebase it for you if you've enabled the option for maintainers to update the code. Usually the easiest way is to squash the commits locally into a single good one, create a temp branch with it, reset the PR branch to the top of 4.13 and then cherry pick the commit. Should be no conflicts or easy to resolve. Then force push the updated branch and change PR target. Delete the temp branch. (You can do it without the temp branch if you force-push twice and use the remote as your temp, there's multiple ways.) |
@michalkleiner ok, if you are up to do it, i'll let you do that :-) you should be able to edit the PR |
@michalkleiner were you going to take a look at retargetting this PR? |
Ah, missed Thomas's comment last week, will do it today. |
CI might try to install from the |
Fixes issue silverstripe#11162
@GuySartorelli re-pushed after the target change and CI still ✅ |
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.
Sweet, LGTM.
Thanks for fixing this @lekoala and thanks for the help @michalkleiner
Fixes issue #11162
and very likely will also deal with #10626
I've targeted this to 5.1 but it probably also apply to 4.x but i don't know if it's worth it to apply the patch there as well
Description
See relevant issue
Manual testing steps
See relevant issue
Issues
Related
also see https://www.php.net/manual/en/class.numberformatter.php#129192
Pull request checklist