Explorar el Código

Fix Python 3 compatibility

Yentl Van Tendeloo hace 7 años
padre
commit
547702e08d
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      wrappers/modelverse.py

+ 1 - 1
wrappers/modelverse.py

@@ -654,7 +654,7 @@ def service_get(port):
     """Get the values on the specified port."""
 
     data = urlencode({"op": "get_output", "taskname": port}).encode()
-    val = json.loads(urlopen(Request("http://%s" % controller.address, data), timeout=99999).read())
+    val = json.loads(urlopen(Request("http://%s" % controller.address, data), timeout=99999).read().decode('utf-8'))
     return val
 
 def service_set(port, value):