Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

encoding error UTF-8 and ACSII-8BIT #18

Closed
kaluznyo opened this Issue Jul 27, 2011 · 4 comments

Comments

Projects
None yet
2 participants

When my params ( street => "street", locality => "Zürich") I have the following error message : incompatible character encodings: UTF-8 and ASCII-8BIT

if I put locality => Züriche (unexistant city), it's work.

For information, the problem may be in methode create_from_location (geocode.rb line 32). Remplace

create geocoder.locate(location).attributes.merge(:query => location.to_s)

by

create geocoder.locate(location).attributes.merge(:query => location.to_s.parameterize) #Replace accentutate chars by non-accentuate chars and it's works

I don't know if is the best way to fix this.

Owner

bryckbost commented Aug 4, 2011

Thanks for the heads up. Working on a fix.

Owner

bryckbost commented Aug 4, 2011

@kaluznyo: I've pushed some fixes for this and got the gem more up to date to play nice with Ruby 1.9. Are you able to use point your gemfile to master to see if this fixes your issue?

kaluznyo commented Aug 5, 2011

It seems to work fine now. Thanks !

Owner

bryckbost commented Aug 5, 2011

Cool. I'll push out a new release shortly.

@bryckbost bryckbost closed this Aug 5, 2011

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment