Use msg.rstrip() as suggested in review
This commit is contained in:
parent
32a5e80a6d
commit
c04767f946
|
@ -1000,8 +1000,7 @@ def _get_line_with_reprcrash_message(config, rep, termwidth):
|
||||||
# u'😄' will result in a High Surrogate (U+D83D) character, which is
|
# u'😄' will result in a High Surrogate (U+D83D) character, which is
|
||||||
# rendered as u'<27>'; in this case we just strip that character out as it
|
# rendered as u'<27>'; in this case we just strip that character out as it
|
||||||
# serves no purpose being rendered
|
# serves no purpose being rendered
|
||||||
while msg.endswith(u"\uD83D"):
|
msg = msg.rstrip(u"\uD83D")
|
||||||
msg = msg[:-1]
|
|
||||||
msg += ellipsis
|
msg += ellipsis
|
||||||
line += sep + msg
|
line += sep + msg
|
||||||
return line
|
return line
|
||||||
|
|
Loading…
Reference in New Issue