gornostal / Modific

Highlight lines changed since the last commit (supports Git, SVN, Bazaar, Mercurial and TFS) / ST2(3) plugin
614 stars 44 forks source link

ST3 MacOS fix unicode decode error for utf-8 files #48

Closed romantolkachyov closed 11 years ago

romantolkachyov commented 11 years ago

I don't know why but it works only with this. Raises unicode decode error if file contains non-ascii symbols in other case.

gornostal commented 11 years ago

What OS do you use? I will merge it after I test on Linux and Windows.

tiagoamaro commented 11 years ago

I'm using ST3 with Mac OS X 10.8.4, and confirm that @romantolkachyov changes works, but python3 branch at original project doesn't because of unicode error.

Here's the screenshot of the error:

captura de tela 2013-07-30 as 09 51 40

gornostal commented 11 years ago

Although I could not reproduce this issue, I'm merging this patch. Seems like it works fine.

Thanks for contributing to this project.

rvanos commented 11 years ago

I saw this problem on Mac OS today: setting universal_newlines=False (and keeping shell=shell as it is) fixed it for me.

ajimix commented 11 years ago

I'm having the same problem on Mac for some files.

Here is what console reports:

Exception in thread Thread-104:
Traceback (most recent call last):
  File "X/threading.py", line 639, in _bootstrap_inner
  File "Modific in /Users/xxxx/Library/Application Support/Sublime Text 3/Installed Packages/Modific.sublime-package", line 115, in run
  File "X/subprocess.py", line 906, in communicate
  File "X/subprocess.py", line 1531, in _communicate
  File "X/subprocess.py", line 831, in _translate_newlines
UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 1042: ordinal not in range(128)
fuerst commented 11 years ago

Looks like this is related to https://github.com/maltize/sublime-text-2-ruby-tests/issues/116

enagorny commented 10 years ago

It still doesn't work with unicode on mac. Please reopen the ticket.