From a66c5bec1d1446dc38b930b2ffb5da2bc9a60c6f Mon Sep 17 00:00:00 2001 From: Zeko9381 Date: Fri, 25 Mar 2022 10:10:52 +0100 Subject: [PATCH] _type isn't read from gpx anymore, but is always 'location' modified: gpx_to_rec.py --- contrib/gpx-to-rec/gpx_to_rec.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/contrib/gpx-to-rec/gpx_to_rec.py b/contrib/gpx-to-rec/gpx_to_rec.py index 66888e4..f012db9 100644 --- a/contrib/gpx-to-rec/gpx_to_rec.py +++ b/contrib/gpx-to-rec/gpx_to_rec.py @@ -25,7 +25,7 @@ for track in gpx.tracks: output = "" for point in segment.points: if point.time.strftime("%Y-%m") == month: - point_json = {'_type' : point.type, 'lat' : point.latitude, 'lon' : point.longitude, 'tst' : int(point.time.timestamp()), '_http' : True, 'alt' : point.elevation} + point_json = {'_type' : 'location', 'lat' : point.latitude, 'lon' : point.longitude, 'tst' : int(point.time.timestamp()), '_http' : True, 'alt' : point.elevation} output += point.time.strftime("%Y-%m-%dT%XZ") + "\t*" + (18 * " ") + "\t" + json.dumps(point_json) + "\n" rec_file = open(month + ".rec", "w") print("Saving file ", month, ".rec...", sep="")