AtlisInc / Nominatim-API

Java library for reverse geocoding for Nominatim
http://nominatim.openstreetmap.org
GNU Lesser General Public License v3.0
14 stars 3 forks source link

Wrong encoding #1

Closed lsoares closed 8 years ago

lsoares commented 8 years ago

Please consider more than English characters. If you try to reverse-geocode something that leads to a city with accents, you have unrecognized characters. Try with:

NominatimAPI geoApi = new NominatimAPI();
geoApi.initNominatimAPI("http://nominatim.openstreetmap.org");
geoApi.getAddressFromMapPoint(new MapPoint().buildMapPoint(41.421, -8.765));

We should be able to set the encoding, or you should use UTF-8 (but you're using system default).

lsoares commented 8 years ago

Here is fine: http://nominatim.openstreetmap.org/reverse.php?osm_type=N&format=json&zoom=18&lon=-8.765&accept-language=en&lat=41.421

lsoares commented 8 years ago

their response seems to be in UTF-8. could you please parse the string that way?

image

lsoares commented 8 years ago

btw... URL_ACCEPT_LANGUAGE_PARAMETER_VALUE = "en" why is this hardcoded?

michaelassraf commented 8 years ago

Yes currently hard coded. Easy fix. On May 10, 2016 3:29 PM, "Luís Soares" notifications@github.com wrote:

btw... URL_ACCEPT_LANGUAGE_PARAMETER_VALUE = "en" why is this hardcoded?

— You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218142687

lsoares commented 8 years ago

but should I fix&push or will you fix and release?


Luís Soares luissoares.com

On Tue, May 10, 2016 at 1:42 PM, Michael Assraf notifications@github.com wrote:

Yes currently hard coded. Easy fix. On May 10, 2016 3:29 PM, "Luís Soares" notifications@github.com wrote:

btw... URL_ACCEPT_LANGUAGE_PARAMETER_VALUE = "en" why is this hardcoded?

— You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub < https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218142687>

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218145382

michaelassraf commented 8 years ago

Push it. On May 10, 2016 3:45 PM, "Luís Soares" notifications@github.com wrote:

but should I fix&push or will you fix and release?


Luís Soares luissoares.com

On Tue, May 10, 2016 at 1:42 PM, Michael Assraf notifications@github.com wrote:

Yes currently hard coded. Easy fix. On May 10, 2016 3:29 PM, "Luís Soares" notifications@github.com wrote:

btw... URL_ACCEPT_LANGUAGE_PARAMETER_VALUE = "en" why is this hardcoded?

— You are receiving this because you are subscribed to this thread. Reply to this email directly or view it on GitHub <

https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218142687>

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub < https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218145382>

— You are receiving this because you commented. Reply to this email directly or view it on GitHub https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218146154

lsoares commented 8 years ago

what about the original error I mentioned?

michaelassraf commented 8 years ago

I'll add the option the set encoding. On May 10, 2016 3:49 PM, "Luís Soares" notifications@github.com wrote:

what about the original error I mentioned?

— You are receiving this because you commented. Reply to this email directly or view it on GitHub https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218147040

lsoares commented 8 years ago

Thanks. By default you could put utf8.

michaelassraf commented 8 years ago

@nirfatlis i don't have write access to this repo since I left :-) so now it on you. (or you can give me write access to this repo)

nirfnir commented 8 years ago

@michaelassraf you have a write access to this repo

michaelassraf commented 8 years ago

https://github.com/AtlisInc/Nominatim-API/commit/a6b96ae55683694caaeb18ec6e0afbe7c23ac5af

lsoares commented 8 years ago

hi @michaelassraf what about the encoding issue? I just fixed the accept-language issue. if you want I can solve the other.

michaelassraf commented 8 years ago

sure.

On 11 May 2016 at 13:28, Luís Soares notifications@github.com wrote:

hi @michaelassraf https://github.com/michaelassraf what about the encoding issue? I just fixed the accept-language issue. if you want I can solve the other.

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218421161

[image: Vicarius]

Michael Assraf / Founder michael@vicarius.io / +972504498855

Vicarius

[image: Twitter] https://htmlsig.com/t/0000001BQKWCJ [image: Facebook] https://htmlsig.com/t/0000001BPQK8F [image: Google +] https://htmlsig.com/t/0000001BRAB4V [image: LinkedIn] https://htmlsig.com/t/0000001BTH55C [image: Instagram] https://htmlsig.com/t/0000001BPK7H7 [image: Skype] https://htmlsig.com/t/0000001BR0D0N [image: Youtube] https://htmlsig.com/t/0000001BPKBPX [image: Github] https://htmlsig.com/t/0000001BQK6EF [image: Stack Overflow] https://htmlsig.com/t/0000001BMMW39

lsoares commented 8 years ago

what is the process for being released at http://mvnrepository.com/artifact/me.atlis/nominatim-api as a new version?

michaelassraf commented 8 years ago

I'm not longer involved with Atlis, so you can move your commits to my fork of this library https://github.com/michaelassraf/Nominatim-API and I will help with the release process to maven central or you can ask Nir to help you release to the existing maven central.

On 11 May 2016 at 16:06, Luís Soares notifications@github.com wrote:

what is the process of being released here? http://mvnrepository.com/

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218453195

[image: Vicarius]

Michael Assraf / Founder michael@vicarius.io / +972504498855

Vicarius

[image: Twitter] https://htmlsig.com/t/0000001BQKWCJ [image: Facebook] https://htmlsig.com/t/0000001BPQK8F [image: Google +] https://htmlsig.com/t/0000001BRAB4V [image: LinkedIn] https://htmlsig.com/t/0000001BTH55C [image: Instagram] https://htmlsig.com/t/0000001BPK7H7 [image: Skype] https://htmlsig.com/t/0000001BR0D0N [image: Youtube] https://htmlsig.com/t/0000001BPKBPX [image: Github] https://htmlsig.com/t/0000001BQK6EF [image: Stack Overflow] https://htmlsig.com/t/0000001BMMW39

lsoares commented 8 years ago

does it make sense to make me a co-author of your project? For simplicity.

michaelassraf commented 8 years ago

Are you referring to my fork or the original repo ? As i said i have no control on the maven central releases to me.atlis repo. On May 11, 2016 6:21 PM, "Luís Soares" notifications@github.com wrote:

does it make sense to make me a co-author of your project? For simplicity.

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218492947

lsoares commented 8 years ago

Yours Em 11/05/2016 16:48, "Michael Assraf" notifications@github.com escreveu:

Are you referring to my fork or the original repo ? As i said i have no control on the maven central releases to me.atlis repo. On May 11, 2016 6:21 PM, "Luís Soares" notifications@github.com wrote:

does it make sense to make me a co-author of your project? For simplicity.

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub < https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218492947>

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218501739

michaelassraf commented 8 years ago

Do you know how to upload to maven central ? On May 11, 2016 6:49 PM, "Luís Soares" notifications@github.com wrote:

Yours Em 11/05/2016 16:48, "Michael Assraf" notifications@github.com escreveu:

Are you referring to my fork or the original repo ? As i said i have no control on the maven central releases to me.atlis repo. On May 11, 2016 6:21 PM, "Luís Soares" notifications@github.com wrote:

does it make sense to make me a co-author of your project? For simplicity.

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub <

https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218492947>

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub < https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218501739>

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218502030

lsoares commented 8 years ago

Nop. Only saw this: https://maven.apache.org/guides/mini/guide-central-repository-upload.html Em 11/05/2016 16:53, "Michael Assraf" notifications@github.com escreveu:

Do you know how to upload to maven central ? On May 11, 2016 6:49 PM, "Luís Soares" notifications@github.com wrote:

Yours Em 11/05/2016 16:48, "Michael Assraf" notifications@github.com escreveu:

Are you referring to my fork or the original repo ? As i said i have no control on the maven central releases to me.atlis repo. On May 11, 2016 6:21 PM, "Luís Soares" notifications@github.com wrote:

does it make sense to make me a co-author of your project? For simplicity.

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub <

https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218492947>

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub <

https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218501739>

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub < https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218502030>

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218503115

michaelassraf commented 8 years ago

​I'll give you write access to my fork, cool ?​

On 12 May 2016 at 10:56, Luís Soares notifications@github.com wrote:

Nop. Only saw this: https://maven.apache.org/guides/mini/guide-central-repository-upload.html Em 11/05/2016 16:53, "Michael Assraf" notifications@github.com escreveu:

Do you know how to upload to maven central ? On May 11, 2016 6:49 PM, "Luís Soares" notifications@github.com wrote:

Yours Em 11/05/2016 16:48, "Michael Assraf" notifications@github.com escreveu:

Are you referring to my fork or the original repo ? As i said i have no control on the maven central releases to me.atlis repo. On May 11, 2016 6:21 PM, "Luís Soares" notifications@github.com wrote:

does it make sense to make me a co-author of your project? For simplicity.

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub <

https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218492947>

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub <

https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218501739>

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub <

https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218502030>

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub < https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218503115>

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218685926

[image: Vicarius]

Michael Assraf / Founder michael@vicarius.io / +972504498855

Vicarius

[image: Twitter] https://htmlsig.com/t/0000001BQKWCJ [image: Facebook] https://htmlsig.com/t/0000001BPQK8F [image: Google +] https://htmlsig.com/t/0000001BRAB4V [image: LinkedIn] https://htmlsig.com/t/0000001BTH55C [image: Instagram] https://htmlsig.com/t/0000001BPK7H7 [image: Skype] https://htmlsig.com/t/0000001BR0D0N [image: Youtube] https://htmlsig.com/t/0000001BPKBPX [image: Github] https://htmlsig.com/t/0000001BQK6EF [image: Stack Overflow] https://htmlsig.com/t/0000001BMMW39

lsoares commented 8 years ago

Great

michaelassraf commented 8 years ago

Done

On 12 May 2016 at 15:57, Luís Soares notifications@github.com wrote:

Great Em 12/05/2016 13:57, "Michael Assraf" notifications@github.com escreveu:

​I'll give you write access to my fork, cool ?​

On 12 May 2016 at 10:56, Luís Soares notifications@github.com wrote:

Nop. Only saw this:

https://maven.apache.org/guides/mini/guide-central-repository-upload.html

Em 11/05/2016 16:53, "Michael Assraf" notifications@github.com escreveu:

Do you know how to upload to maven central ? On May 11, 2016 6:49 PM, "Luís Soares" notifications@github.com wrote:

Yours Em 11/05/2016 16:48, "Michael Assraf" notifications@github.com escreveu:

Are you referring to my fork or the original repo ? As i said i have no control on the maven central releases to me.atlis repo. On May 11, 2016 6:21 PM, "Luís Soares" <notifications@github.com

wrote:

does it make sense to make me a co-author of your project? For simplicity.

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub <

https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218492947>

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub <

https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218501739>

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub <

https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218502030>

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub <

https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218503115>

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub <

https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218685926>

[image: Vicarius]

Michael Assraf / Founder michael@vicarius.io / +972504498855

Vicarius

[image: Twitter] https://htmlsig.com/t/0000001BQKWCJ [image: Facebook] https://htmlsig.com/t/0000001BPQK8F [image: Google +] https://htmlsig.com/t/0000001BRAB4V [image: LinkedIn] https://htmlsig.com/t/0000001BTH55C [image: Instagram] https://htmlsig.com/t/0000001BPK7H7 [image: Skype] https://htmlsig.com/t/0000001BR0D0N [image: Youtube] https://htmlsig.com/t/0000001BPKBPX [image: Github] https://htmlsig.com/t/0000001BQK6EF [image: Stack Overflow] https://htmlsig.com/t/0000001BMMW39

— You are receiving this because you authored the thread. Reply to this email directly or view it on GitHub < https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218748794>

— You are receiving this because you were mentioned. Reply to this email directly or view it on GitHub https://github.com/AtlisInc/Nominatim-API/issues/1#issuecomment-218748907

[image: Vicarius]

Michael Assraf / Founder michael@vicarius.io / +972504498855

Vicarius

[image: Twitter] https://htmlsig.com/t/0000001BQKWCJ [image: Facebook] https://htmlsig.com/t/0000001BPQK8F [image: Google +] https://htmlsig.com/t/0000001BRAB4V [image: LinkedIn] https://htmlsig.com/t/0000001BTH55C [image: Instagram] https://htmlsig.com/t/0000001BPK7H7 [image: Skype] https://htmlsig.com/t/0000001BR0D0N [image: Youtube] https://htmlsig.com/t/0000001BPKBPX [image: Github] https://htmlsig.com/t/0000001BQK6EF [image: Stack Overflow] https://htmlsig.com/t/0000001BMMW39