codeclimate / python-test-reporter

DEPRECATED Uploads Python test coverage data to Code Climate
https://codeclimate.com
Other
19 stars 11 forks source link

add latin 1 format handling (cf issue #37) #38

Closed BuonOmo closed 7 years ago

BuonOmo commented 7 years ago

This tiny change add a method called read_file_content, which tries to read a file as utf-8 first, and if this throws an error, read it as latin-1.

Also considering a PR to skip files with different encoding. However this changes more code : division by zero may occur when all files have a different encoding.

dblandin commented 7 years ago

Hey @BuonOmo,

Thank you for the PR! I just triggered a CircleCI build for this PR. Would you mind checking out the py27 failure?

BuonOmo commented 7 years ago

Done @dblandin!

dblandin commented 7 years ago

@BuonOmo Awesome! Thanks so much!

Will ping back here when I've released a new version.

dblandin commented 7 years ago

Just released v0.2.1: https://pypi.python.org/pypi/codeclimate-test-reporter/0.2.1