diff --git a/ask_for_jobs b/ask_for_jobs index 6135afbb..5d417933 100755 --- a/ask_for_jobs +++ b/ask_for_jobs @@ -20,8 +20,8 @@ IMAGES = { def manage_jobs(service): # Get queued jobs - queued = json.load( - urllib.request.urlopen(VRE_MANAGER + "?service=" + service + "&status=queued") + queued = json.loads( + urllib.request.urlopen(VRE_MANAGER + "?service=" + service + "&status=queued").read().decode('utf-8') ) # Return if no jobs are available @@ -31,7 +31,6 @@ def manage_jobs(service): # Get a list of compute nodes compute_nodes = subprocess.run( ["docker", "ps", "--filter", "ancestor=" + IMAGES[service], "--format", "{{.Names}}"], - encoding="utf-8", stdout=subprocess.PIPE ).stdout.split()