about summary refs log tree commit diff stats
path: root/README.md
diff options
context:
space:
mode:
authorBaranovskiy Konstantin <baranovskiykonstantin@gmail.com>2018-10-20 20:01:02 +0300
committerBaranovskiy Konstantin <baranovskiykonstantin@gmail.com>2018-10-26 16:17:15 +0300
commitf9c49f9c2e7ec680f9a06685eba75787e7d2ed7b (patch)
tree4efeb23fe8f8d46d037e077435ef992279d7c535 /README.md
parentf85d3fd6f95646355673445e6305a2781067225b (diff)
downloadranger-f9c49f9c2e7ec680f9a06685eba75787e7d2ed7b.tar.gz
Broken preview of highlighted text with Python3
ranger/core/loader.py:
CommandLoader.generate() gets text for preview panel from scope.sh
as the blocks of byrearray (max 512 bytes). This blocks immediately
decoded to utf-8. But in case when muli-byte unicode characters is
present they may be split and python will can't correctly to decode
it. For example: b'abc\xd0', b'\x9a...'
b'\xd0\x9a' - is cyrillic letter 'K' and it can't be decoded
separately (UnicodeDecodeError occurs).
So, received data blocks (bytearrays) must be collected and
only after that decoded as one whole byrearray.

Fixes #906
Fixes #967
Fixes #1166
Diffstat (limited to 'README.md')
0 files changed, 0 insertions, 0 deletions