Can't read iso-8859-5 encoded files
Not that you should support it; just thought I'd report it.
>>> massedit -e "line" -m 99 nonascii.py
Traceback (most recent call last):
File "/usr/bin/massedit", line 9, in <module>
load_entry_point('massedit', 'console_scripts', 'massedit')()
File "/home/tyler/repos/massedit/massedit.py", line 475, in main
command_line(sys.argv)
File "/home/tyler/repos/massedit/massedit.py", line 462, in command_line
output=arguments.output)
File "/home/tyler/repos/massedit/massedit.py", line 440, in edit_files
diffs = list(editor.edit_file(path))
File "/home/tyler/repos/massedit/massedit.py", line 168, in edit_file
from_lines = from_file.readlines()
File "/usr/lib/python2.7/codecs.py", line 314, in decode
(result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf8' codec can't decode byte 0xb1 in position 81: invalid start byte
Where the offending file is nonascii.py from the IPython project.
Hey tgoodlet, thanks for the example. Kind of struggling with my tests and the unicode transition between 2.7 and 3.3. I've found http://python3porting.com/ but I need to find the time to focus on it a little.
I'll get there eventually...
Hey @tgoodlet, the release v0.68.1 should fix this issue. Let me know if it does not.
Fixed by d8330735aa454b117bfa12d83524f456364883f9
Hey @elmotec I'm still seeing this issue (sorry it's been a while - haven't needed massedit for a bit).
An example would be a utf-8 encoded tags file generated from the VIM editor.
If you need an example I can probably whip another one up.
Mmmmmh. Yeah @tgoodlet, I could use another test case. The one I had was fixed with 0.68.1.
Sorry @goodboy, it's been 2 years. I just realized I pinged the wrong person. If you can provide an example, I could take a look.
Without a test case it's difficult to make sure the issue is resolved. If you could provide an example, that would give us a change to resolve the issue.