aboutsummaryrefslogtreecommitdiff
path: root/tools/test-trips.py
diff options
context:
space:
mode:
Diffstat (limited to 'tools/test-trips.py')
-rwxr-xr-xtools/test-trips.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/test-trips.py b/tools/test-trips.py
index 267752fbb..3c994fd83 100755
--- a/tools/test-trips.py
+++ b/tools/test-trips.py
@@ -1,7 +1,7 @@
#!/usr/bin/env python3
import urllib
-import httplib
+import http.client as httplib
import time
import datetime
@@ -25,7 +25,7 @@ points = [
def send(conn, time, lat, lon, speed):
params = (('id', id), ('timestamp', int(time)), ('lat', lat), ('lon', lon), ('speed', speed))
- conn.request('POST', '?' + urllib.urlencode(params))
+ conn.request('POST', '?' + urllib.parse.urlencode(params))
conn.getresponse().read()
conn = httplib.HTTPConnection(server)