Closed mathjazz closed 3 years ago
Comment Author: @Pike
I tried to reproduce this, and this seems to be an issue with en-CA
. Or one contributor there. https://pontoon.mozilla.org/en-CA/firefox-accounts/settings.ftl/?author=d.nisbetjones%40protonmail.com&string=220482 for Pei.
The only way I could reproduce this was to copy-n-paste the original string with the newline markup into the text area. When clicking the copy button, that doesn't happen.
Comment Author: @mathjazz
Yeah, this looks like something we could prevent in Pontoon. There are also other places (outside Pontoon) users could copy translations from, which are harder to prevent, hence the P4.
Peiying, it'd be great if you could warn the user Axel found out and tell them they should use the Copy button instead of copying and pasting the source string into translation area manually to avoid copying the newline markup.
Comment Author: @peiying2
I am adding this note to the monthly report to the community so I gave the solution a try.
I used the Copy button, though visually it removes the pilcrow in the localized field, once you save it, the pilcrow remains in the Saved version. Pilcrow is a hard/manual line-break. Additionally, this break location varies from language to language. I think it is best/safe to suggest to remove pilcrow manually.
Comment Author: @mathjazz
(In reply to Peiying Mo [:CocoMo] from comment #3)
I used the Copy button, though visually it removes the pilcrow in the localized field, once you save it, the pilcrow remains in the Saved version.
Peiying, are you saying the pilcrow ends up in the translation in VCS? I'd be surprised if that's the case.
We do render pilcrow in original strings and translations, but that's just a visual indication of a new line.
Comment Author: @peiying2
(In reply to Matjaz Horvat [:mathjazz] from comment #4)
(In reply to Peiying Mo [:CocoMo] from comment #3)
I used the Copy button, though visually it removes the pilcrow in the localized field, once you save it, the pilcrow remains in the Saved version.
Peiying, are you saying the pilcrow ends up in the translation in VCS? I'd be surprised if that's the case.
I tried to use the method Axel recommended to change en-CA. It looked good in the box, but once I saved the string, pilcrow is still there. You can give en-GB a try.
Comment Author: @flodolo
I've fixed multiple errors in Firefox, and it works without issues. Last example https://hg.mozilla.org/l10n-central/id/rev/0454a293b9be862d8cf59f46b6bc6ab94b9440ee
Comment Author: @mathjazz
Note to self: check how many translations include the ¶ character and prioritize the bug accordingly.
We should also "mass remove ¶" from translations.
Comment Author: @mathjazz
620 translations across 82 locales from 146 authors are affected.
Seems like this bug is affecting a lot of people, let's bump the priority.
I'll also remove ¶ from all existing translations using something like:
for t in Translation.objects.filter(string__contains="¶"):
t.string = t.string.replace("¶", "")
t.save(update_stats=False)
This issue was created automatically with bugzilla2github.
Bug 1711736
Bug Reporter: @clouserw CC: @Pike, @flodolo, @mathjazz, @peiying2
This was reported at https://github.com/mozilla/fxa/issues/8483 but it seems like a bug in Pontoon that this is getting passed through so I'm filing here. We've run into it a couple of times.