steve8x8 / geotoad

Geocaching query tool written in Ruby
https://buymeacoffee.com/steve8x8
Other
28 stars 8 forks source link

EasyGPS encoding should be UTF-8 #298

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
> geotoad.rb --format=easygps --queryType=wid GC2AD16

What is the expected output? What do you see instead?
- The file is written using UTF-8 encoding, but the XML header specifies 
ISO-8859-1 encoding.
- The cache name in the file is "Adslev skoven - over broen ved Pinds Mølle"
- The expected cache name is "Adslev skoven - over broen ved Pinds Mølle"

What version of the product are you using? On what operating system?
- GeoToad 3.20.0 (Ruby 2.0.0p247/2013-06-27 on universal.x86_64-darwin13)
- Mac OS X 10.9.1

Please provide any additional information below.
- Correcting the encoding in easygps.tm (attached) fixes the problem.

Original issue reported on code.google.com by ulri...@gmail.com on 6 Feb 2014 at 5:59

Attachments:

GoogleCodeExporter commented 9 years ago
Nicely spotted. I'm surprised someone is still using EasyGPS output ;)
I have to trust your expertise when it comes to internals of that format - can 
you point me to some documentation, just for completeness?

Now I've got to check all other (almost orphaned) output formats for similar 
issues...

Scheduled for quick inclusion (into 3.20.1, later this month)

Original comment by Steve8x8 on 7 Feb 2014 at 8:55

GoogleCodeExporter commented 9 years ago
Um, what about this one:
http://forums.groundspeak.com/GC/index.php?showtopic=28320&st=0&p=363310&#entry3
63310
It's almost 12 years old and things may have changed since, but I'd like to see 
some written statement that "the easygps format" supports UTF-8 - and not only 
your app.
Your change (which otherwise looks good) might break others' setup.

I'm tending to another ("easygps8" ?) template, at least until this gets sorted 
out...

Original comment by Steve8x8 on 7 Feb 2014 at 9:09

GoogleCodeExporter commented 9 years ago
Others' setup is probably already broken if they expect easygps files in 
ISO-8859-1 encoding, and the XML header specifies this, but the actual encoding 
is UTF-8.

The UTF-8 encoded .loc files generated by geocaching.com imports well in 
EasyGPS.

Original comment by ulri...@gmail.com on 7 Feb 2014 at 9:53

GoogleCodeExporter commented 9 years ago
(Your comment collided with my having to enter my google password for the sixth 
time this morning.)

Ah okay... I wasn't aware that GS had switched to UTF-8 years ago.
I'm surprised though that GpsBabel doesn't even declare the encoding in "geo" 
output.

After downloading the LOC file from the cache page, I went to mimic that format 
to more extent, adding a few line feeds and a "by $owner" string.

From my POV, with the minor exception of the link (GeoToad uses the newer 
/geocache/ style), the output now looks pretty much the same. My worries about 
incompatibilities are gone - if EasyGPS supports original GS files, it should 
also accept GeoToad's.

Fix submitted.

Original comment by Steve8x8 on 7 Feb 2014 at 9:59

GoogleCodeExporter commented 9 years ago
... and rolled out with 3.20.1.

Original comment by Steve8x8 on 25 Feb 2014 at 11:28