smarkets / flake8-strict

Flake8 plugin that checks Python code against a set of opinionated style rules
MIT License
10 stars 8 forks source link

UnicodeDecodeError if file contains non-ascii symbols #22

Closed sshishov closed 7 years ago

sshishov commented 7 years ago

Traceback (most recent call last): File "/usr/lib/python3.4/multiprocessing/pool.py", line 119, in worker result = (True, func(*args, **kwds)) File "/home/dubizzle/venv/lib/python3.4/site-packages/flake8/checker.py", line 642, in _run_checks return checker.run_checks() File "/home/dubizzle/venv/lib/python3.4/site-packages/flake8/checker.py", line 573, in run_checks self.run_ast_checks() File "/home/dubizzle/venv/lib/python3.4/site-packages/flake8/checker.py", line 487, in run_ast_checks for (line_number, offset, text, check) in runner: File "/home/dubizzle/venv/lib/python3.4/site-packages/flake8_strict.py", line 44, in run errors = _process_file(self._filename) File "/home/dubizzle/venv/lib/python3.4/site-packages/flake8_strict.py", line 60, in _process_file code = f.read() File "/home/dubizzle/venv/lib/python3.4/encodings/ascii.py", line 26, in decode return codecs.ascii_decode(input, self.errors)[0] UnicodeDecodeError: 'ascii' codec can't decode byte 0xd9 in position 222: ordinal not in range(128)

sshishov commented 7 years ago

Hello @JaimeLennox , when we can have a release with this issue fixed?

JaimeLennox commented 7 years ago

We're hoping to have a new release in the next few days - I'll keep you updated. Thanks for your contributions!

JaimeLennox commented 7 years ago

@sshishov Version 0.1.5 has now been released, containing your fixes.

sshishov commented 7 years ago

@JaimeLennox, Thank you for updates. I have updated my sources to use your latest version. Cheers!