Message8315
Hi Tobias:
Thanks for noting this, it is finally fixed.
I reworked the patch a little bit. The reason Chinese didn't work is that
there is no colon space in the string. Instead
https://www.compart.com/en/unicode/U+003A
is used.
So the result looks like:
commands = ['']
for command in self.commands.values():
h = _(command.__doc__).split('\n')[0]
# ascii colon and space, U+003A as ascii repr (for
# Chinese variants), 'fallback'
for seq in [': ', '\uff1a', 'fallback']:
if seq == 'fallback':
# command hasn't been printed yet so ...
commands.append(' ' + h.lstrip())
break
if seq in h:
commands.append(' ' + h.split(seq, 1)[1].lstrip())
break
I also added a code marker to the file to indicate it's utf-8 so I can embed
the actual character in a comment. This way I don't have to change the test
suite to stop testing the admin module under python2.
It doesn't fix the Chinese listing under python2, but python2 is not supported
anymore so I am ok with that.
changeset: 8296:4d3b371ed543 |
|
Date |
User |
Action |
Args |
2025-01-20 20:22:48 | rouilj | set | messageid: <1737404568.45.0.104267844349.issue1895197@roundup-tracker.org> |
2025-01-20 20:22:48 | rouilj | set | recipients:
+ rouilj, richard, tobias-herp |
2025-01-20 20:22:48 | rouilj | link | issue1895197 messages |
2025-01-20 20:22:48 | rouilj | create | |
|