osmandapp / OsmAnd

OsmAnd
https://osmand.net
Other
4.36k stars 985 forks source link

Gzip fields in gpx #19965

Open mariush444 opened 1 month ago

mariush444 commented 1 month ago

Description

When one creates waypoint in gpx track based on POI OSM then Osmand copies OSM tags into gpx.

See example in zip.

Icon, color, background are OK to exists in extentions:osmand but copy of OSM data tags to gpx is usless/redundand/duplicated.

Please notice that and contains kB of unicode data. It is even dificult to attatch them to this issue.

Steps to reproduce

Tap on a POI that is shown in example in zip

Actual result

planty of usless/duplicated data. To big gpx. Problem with rendering gpx:slow, crashes ...

Expected result

No redundand data especialy blobs or bloks of unicode data

Your Environment (required)

wpt.zip

yuriiurshuliak commented 1 month ago

The bug was not reproduced. The GPX file from the zip folder you attached is damaged and cannot be opened in the app. Please try attaching the file again or send it to us via email at support@osmand.net.

mariush444 commented 1 month ago

It is not damaged. It is what gpx contains in real live. I just sent one wpt but it is taken out from osmand gpx.

Try other POI. I just click on it at 18:40 2024-05-28

<wpt lat="37.6315328" lon="22.7192652">
    <time>2024-05-04T19:11:41Z</time>
    <name>Archaeological Site of Argos</name>

and look into tag

Map of Greece is from may.
yuriiurshuliak commented 1 month ago

Could you please explain what you mean by POI OSM? Also, could you provide the steps we need to follow to reproduce this bug?

mariush444 commented 1 month ago

I assume that you have gpx files in tracks folder and you have standard map of Greece from May. Please,

  1. open (show on map) gpx file from menu favorities -> tab tracks
  2. Go to 37.6315328 22.7192652
  3. Tap on Archaeological Site of Argos"
  4. Use function "add track waypoint"
  5. Choose your gpx track
  6. Save the point in this track
  7. Close the track and osmand to be sure that cashed activity is saved into file.
  8. Open the gpx file in text editor and find just added waypoint.
  9. Find "rubbish" in osmand:osm_tag_description

PS If I find (remember) POI with osmand:osm_tagcontent-_* you will how many "damaged" text strings are stored in osmand tags.

yuriiurshuliak commented 4 weeks ago

The bug has been reproduced. To reproduce this issue, create a track and add a waypoint at coordinates 37.6315328, 22.7192652. Then, completely close the app, reopen it, export the track, and view it in a text editor. You will see that the lines in osmand:osm_tagcontent-_ are damaged.

Here is an example of my track: Thu 30 May 2024.zip

OsmAnd~ 4.8.0#2416m, released: 2024-05-30

photo_2024-05-30_17-36-37

vshcherb commented 3 weeks ago

That's a gzipped version of description which probably not necessary as anyone could zip gpx itself.

To do: do not write gzip properties in gpx

mariush444 commented 3 weeks ago

The question is why we have to copy any data from off line vector maps to gpx?

vshcherb commented 3 weeks ago

By design to have all data inside GPX to easy share

mariush444 commented 3 weeks ago

I woud like to ask to reconsider the idea. It is possivle to share this data between osmand users only (because of tag extensions). But osmand users use the same offline maps data. So it seems that it is nothing to share. Due to the redundand data gpx is heavy and rendering is slower and slower. It seemed that idea was that gpx (waypoints) were lighter than in favorities.

vshcherb commented 3 weeks ago

Something to think of though rendering of speed shouldn't be affected as it's description tags not number of points.