From a1f339376e70e04dc64472c005565e2b02197dff Mon Sep 17 00:00:00 2001 From: Mario de Frutos Date: Fri, 2 Feb 2018 13:17:56 +0100 Subject: [PATCH] By default the polyline comes with 6 decimals so we avoid to use 5 by default --- .../cartodb_services/cartodb_services/tools/polyline.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/server/lib/python/cartodb_services/cartodb_services/tools/polyline.py b/server/lib/python/cartodb_services/cartodb_services/tools/polyline.py index eaca5f2..14bba19 100644 --- a/server/lib/python/cartodb_services/cartodb_services/tools/polyline.py +++ b/server/lib/python/cartodb_services/cartodb_services/tools/polyline.py @@ -51,9 +51,7 @@ def polyline_to_linestring(polyline): """Convert a Mapzen polyline shape to a PostGIS linestring""" coordinates = [] for point in polyline: - # Divide by 10 because mapzen uses one more decimal than the - # google standard (https://mapzen.com/documentation/turn-by-turn/decoding/) - coordinates.append("%s %s" % (point[1]/10, point[0]/10)) + coordinates.append("%s %s" % (point[1], point[0])) wkt_coordinates = ','.join(coordinates) try: