jmhodges/rchardet

Got ArgumentError: invalid byte sequence in UTF-8 when reading a 'ISO-8859-1' encoded csv file.

orbanbotond opened this issue · 1 comments

+1 The description is the same as the subject. It occurs under ruby 1.9.3

cd = CharDet.detect(content)
ArgumentError: invalid byte sequence in UTF-8
from /Users/boti/.rvm/gems/ruby-1.9.3-p327@search_server/gems/rchardet-1.3.1/lib/rchardet/universaldetector.rb:99:in =~' from /Users/boti/.rvm/gems/ruby-1.9.3-p327@search_server/gems/rchardet-1.3.1/lib/rchardet/universaldetector.rb:99:infeed'
from /Users/boti/.rvm/gems/ruby-1.9.3-p327@search_server/gems/rchardet-1.3.1/lib/rchardet.rb:63:in `detect'

rchardet has not been ported to ruby 1.9.3. Sorry.